autotrader-demo
autotrader-demo copied to clipboard
' Broker' object has no attribute '_allow_dancing_bears '
I got error when deploying in livetrade mode (auto trade in paper environment)
Error log
2024-03-27 03:08:29,557 | ERROR | autobot | Error when updating strategy: 'Broker' object has no attribute '_allow_dancing_bears' (autobot.py:238) 2024-03-27 03:08:29,558 | INFO | autobot | Traceback (most recent call last): File "/home/adminuser/venv/lib/python3.11/site-packages/autotrader/autobot.py", line 236, in _update strategy_orders = self._strategy.generate_signal(timestamp) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/mount/src/autotrader-forex/strategies/ema_crossover.py", line 55, in generate_signal data = self.broker.get_candles(self.instrument, granularity="1h", count=300) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/adminuser/venv/lib/python3.11/site-packages/autotrader/brokers/oanda.py", line 269, in get_candles data = self._response_to_df(response) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/adminuser/venv/lib/python3.11/site-packages/autotrader/brokers/oanda.py", line 438, in _response_to_df if self._allow_dancing_bears: ^^^^^^^^^^^^^^^^^^^^^^^^^ AttributeError: 'Broker' object has no attribute '_allow_dancing_bears' (autobot.py:239)
I got the same error when trying to use oanda for paper trading... :(