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
Run the following example:
from alpaca.data.live import StockDataStream
wss_client = StockDataStream('api-key', 'secret-key')
# async handler
async def quote_data_handler(data):
# quote data will arrive here
print(data)
wss_client.subscribe_quotes(quote_data_handler, "SPY")
wss_client.run()
### Filled out the Steps to Reproduce section?
- [X] I have entered valid steps to reproduce my issue or have attached a minimally reproducible case in code that shows my issue happening; and understand that without this my issue will be flagged as invalid and closed after 30 days.
### Anything else?
Latest websockets versions https://github.com/python-websockets/websockets/pull/1332 do not handle extra_headers, instead additional_headers is the expected parameter:
https://github.com/python-websockets/websockets/blob/59d4dcf779fe7d2b0302083b072d8b03adce2f61/src/websockets/asyncio/client.py#L278C1-L279C1
This issue must be related to this closed issue https://github.com/alpacahq/alpaca-py/issues/527
The text was updated successfully, but these errors were encountered:
@hiohiohio we either pin the websockets version (to version < 13) or update alpaca-py codes and restrict websockets >= 13. I can do the fix, please let me know what you think.
Is there an existing issue for this?
Current Behavior
While reproducing the API-doc example:
The following appears:
Expected Behavior
No response
SDK Version I encountered this issue in
alpaca-py version: 0.33.0
websockets version: 14.1
Steps To Reproduce
Run the following example: from alpaca.data.live import StockDataStream wss_client = StockDataStream('api-key', 'secret-key') # async handler async def quote_data_handler(data): # quote data will arrive here print(data) wss_client.subscribe_quotes(quote_data_handler, "SPY") wss_client.run()
The text was updated successfully, but these errors were encountered: