You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this case I am subscribing to 'alpacadatav1/AM.TSLA' and then 'alpacadatav1/AM.SPY.
Appereantly you await conn.unsubscribe(previous_channels) when adding additional subscriptions and then re-subscribe.
This process doesnt work and fails in the trade api part, because the self._ws part is None
2021-02-01 01:27:10,493 root Alpaca Proxy Agent v0.5.5
2021-02-01 01:27:10,493 root Using the Alpaca Websocket
< {'action': 'authenticate', 'data': {'key_id': 'PKMIAA7DFADUGOKNIGUR', 'secret_key': '98xk2nDUq6QswX9fAuN3Mj4ZLLUI7ptFrVCzTCtc'}}
< {'action': 'listen', 'data': {'streams': ['alpacadatav1/AM.TSLA']}}
previous channels []
new_channels ['alpacadatav1/AM.TSLA']
< {'action': 'authenticate', 'data': {'key_id': 'PKMIAA7DFADUGOKNIGUR', 'secret_key': '98xk2nDUq6QswX9fAuN3Mj4ZLLUI7ptFrVCzTCtc'}}
< {'action': 'listen', 'data': {'streams': ['alpacadatav1/AM.SPY']}}
previous channels ['alpacadatav1/AM.TSLA']
new_channels ['alpacadatav1/AM.SPY']
Traceback (most recent call last):
File "main.py", line 169, in serve
await conn.unsubscribe(previous_channels)
File "/usr/local/lib/python3.6/site-packages/alpaca_trade_api/stream2.py", line 278, in unsubscribe
await self.data_ws.unsubscribe(data_channels)
File "/usr/local/lib/python3.6/site-packages/alpaca_trade_api/stream2.py", line 121, in unsubscribe
await self._ws.send(json.dumps({
AttributeError: 'NoneType' object has no attribute 'send'
Done
2021-02-01 01:28:18,987 root connected to: wss://data.alpaca.markets/stream
The text was updated successfully, but these errors were encountered:
KlausGlueckert
changed the title
subscription works, but no data received sometimes
subscription for more than 2 data objects can fail - conn object is None
Feb 1, 2021
KlausGlueckert
changed the title
subscription for more than 2 data objects can fail - conn object is None
subscription for more than 1 data object can fail - conn object is None
Feb 1, 2021
KlausGlueckert
changed the title
subscription for more than 1 data object can fail - conn object is None
subscription for more than 1 data channel can fail - conn object is None
Feb 1, 2021
KlausGlueckert
changed the title
subscription for more than 1 data channel can fail - conn object is None
subscription for more than 1 data channel can fail
Feb 1, 2021
In this case I am subscribing to 'alpacadatav1/AM.TSLA' and then 'alpacadatav1/AM.SPY.
Appereantly you
await conn.unsubscribe(previous_channels)
when adding additional subscriptions and then re-subscribe.This process doesnt work and fails in the trade api part, because the self._ws part is None
The text was updated successfully, but these errors were encountered: