2018kguo / RobinhoodBot

Trading bot for Robinhood accounts
MIT License
209 stars 105 forks source link

positions_data error #1

Closed djhemp closed 4 years ago

djhemp commented 5 years ago

the robin-stocks author pushed an update on github that says it's working for him with 2FA turned on. I got it going, but I get these errors now.

Traceback (most recent call last): File "C:\RobinhoodBot\robinhoodbot\main.py", line 258, in scan_stocks() File "C:\RobinhoodBot\robinhoodbot\main.py", line 242, in scan_stocks sell_holdings(symbol, holdings_data) File "C:\RobinhoodBot\robinhoodbot\main.py", line 186, in sell_holdings shares_owned = int(float(positions_data[symbol].get("quantity"))) NameError: name 'positions_data' is not defined

djhemp commented 5 years ago

Figured this out. It was a stock I was holding that filed for bankruptcy! Somehow it was messing with robin-stocks.