robcarver17 / pysystemtrade

Systematic Trading in python
GNU General Public License v3.0
2.5k stars 799 forks source link

Error validating request.-'bq' : cause - Invalid account code #1036

Closed pwholzel closed 1 year ago

pwholzel commented 1 year ago

Hi All, I am trying to seed pricing data for the first time, but it seems it is not connecting properly to IB. It claims it has an incorrect account code, although I have set a legitimate account id in my private/private_config.yaml file. When I initially started running this code I was using the "incorrect" paper trading account code shown in the error, and it seems to have gotten stuck there. I have had no trouble manually connecting to IB through ib_sync, so it really seems like that incorrect account code is somehow hardcoded somewhere. Any help is appreciated. Thanks. image

robcarver17 commented 1 year ago

If I change my psystemtrade private directory I need to reinstall for things to work again - maybe the same thing?

pwholzel commented 1 year ago

Good idea, Robert. I tried that, but it did not work. I will continue to troubleshoot. I am a newbie to programming, so that is likely the root cause.

pwholzel commented 1 year ago

After fiddling around, I am no longer getting the accountID error, but I am still getting an error indicating No market data permissions for CME FUT (AUD/20230515). Not sure if others are having this issue. If I use the ib_insync cookbook on my papertrading account, I am able to get futures market data. Thanks.

robcarver17 commented 1 year ago

Can you get futures market data using your live account ID (not paper trading ID) through ib_insync cookbook?

If not then I would suggest the problem is that you have no market data permissions for CME FUT....

pwholzel commented 1 year ago

That was it Robert. I didn't realize I needed to have at least 2K in my IB account for market data to work (I hadn't funded it until now). Thanks for your help. Feel free to close this.

robcarver17 commented 1 year ago

You can actually close it yourself, but I will do it this time.