I have taken the BasicTemplate in python and am working on creating a spread trading algo. As far as I can tell, it appears to be working properly -- at the very least, it was running without errors. Then I added a function for OnEndOfDay. Initially, my spread pair was SPY and QQQ. This worked okay. Then I changed to GLD and DGL. Now I get a "Runtime error in SPY.EndOfDay event: TypeError: OnEndOfDay() takes exactly 1 argument (2 given)" 

I'm wondering why this has an error associated with SPY as I'm not doing anything with that ticker.

In addition, please add any comments, suggestions, on style or substance.