Automated trading using IBridgePy - scripts outdated?

Hi,



I'm wondering in the scripts in IBridgePy are outdated? I'm using Anaconda 3.7 (Windows). I'm able to log to TWS as well as IB Gateway. However, whenever I tried one of the scripts in strategies, I have code error analysis like : "undefined name 'symbol' (pyflakes E)" or "undefined name 'order' (pyflakes E)"



Thanks in advance!

Hello Philippe,



Can you please share the file name in which you are facing the error along with the asset symbol?

Hello Akshaw,



Of course!



Actually, all of the scripts I tested so far in the folder " strategies" : \IBridgePy_Win_Anaconda37_64\Strategies , I get a message error. I basically took the file as is and got the message, for example, in the file "demo_close_price_reversion". The symbol by default is SPY, but got the same error for 'APPL".



 

Hello Philippe,



It seems that you are running your strategy file directly from the strategies folder. If yes, that is the incorrect way. You have to run the RUN_ME.py to run any strategy, wherein you need to provide your account code and the strategy file name (one within strategies folder). If that is not the case and you are running the RUN_ME.py file only and still facing the error, let me know. Ideally, it should work.

@Akshay Nautiyal thank you, I'll try that!