Executing the streaming example consistently return errors for all endpoint
See original GitHub issueCode run:
USDC_asset = Asset("USDC", "GBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5")
server = Server("https://horizon-testnet.stellar.org")
for response in server.orderbook(Asset.native(), USDC_asset).cursor("now").stream():
print(response)
The error message I get:
Traceback (most recent call last): File “C:/Users/nasse/Syncthing/Code/Python/Stellar_test/main_order_book.py”, line 22, in <module> for response in server.orderbook(Asset.native(), USDC_asset).cursor(“now”).stream(): File “C:\Users\nasse\Syncthing\Code\Python\Stellar_test\venv_xeon\lib\site-packages\typeguard_init_.py”, line 897, in next return self.send(None) File “C:\Users\nasse\Syncthing\Code\Python\Stellar_test\venv_xeon\lib\site-packages\typeguard_init_.py”, line 915, in send value = self.__wrapped.send(obj) File “C:\Users\nasse\Syncthing\Code\Python\Stellar_test\venv_xeon\lib\site-packages\stellar_sdk\client\requests_client.py”, line 174, in stream params=query_params, File “C:\Users\nasse\Syncthing\Code\Python\Stellar_test\venv_xeon\lib\site-packages\stellar_sdk\client\requests_client.py”, line 222, in init url, last_id, retry, session, chunk_size, connect_retry, **kwargs TypeError: init() got an unexpected keyword argument ‘params’
Process finished with exit code 1
Thank you for your help.
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (3 by maintainers)
Top GitHub Comments
Wow, it now works very well. It streams the orderbook in a endless loop, like expected. Thank you for your help. As you suggested I removed the conflicting dependencies (sseclient and requests) rebuilt my virtual environment and boom all working now. I have been working on this issue for a while so thx again for putting a stop to this.
Hello, are you using a virtual environment? If not, I suggest you use it.
I think the conflict is caused by
sseclient
andsseclient-py
, why are they introduced? If they are not necessary, I think removing them from the dependent files and rebuilding the virtual environment should solve this problem.