alpacahq / alpacahq/alpaca-backtrader-api

the readme example throws an Exception

Abierto
#172 6 comentarios 5 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
Python
Estrellas
702
Forks
160
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

I copied the example from the README exactly, I did not change anything except for modifying the API key , secret key and having the following setting:

IS_BACKTEST = True
IS_LIVE = False
symbol = "AAPL"
...

I am getting the following Exception:

```

Starting Portfolio Value: 100000.0
***** DATA NOTIF: DELAYED
xception in thread Thread-1:
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/threading.py", line 932, in _bootstrap_inner
self.run()
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/alpaca_backtrader_api/alpacastore.py", line 414, in _t_candles
cdl = cdl.loc[
File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/pandas/core/frame.py", line 5162, in dropna
raise KeyError(list(np.compress(check, subset)))
KeyError: ['high']

```

it seems that the data that is coming back from the Alpaca broker is not properly formatted
please assist in resolving this

Guía de contribución

No hay ninguna guía de contribución indexada para este repositorio

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.