samco-sdk / Python-SDK

Official Python SDK for accessing Stocknote API
MIT License
15 stars 11 forks source link

set_streaming_data() gives argument error #19

Open starzar opened 1 year ago

starzar commented 1 year ago

CODE:

instrumentCode = "SBIN"
listingId = json.loads(samco.get_quote(instrumentCode))["listingId"]
print(listingId)
value=[{"symbol":{listingId}}]
samco.set_streaming_data(value)
samco.start_streaming()

ERROR:

Websocket connected
error from callback <bound method StocknoteAPIPythonBridge.on_open of <snapi_py_client.snapi_bridge.StocknoteAPIPythonBridge object at 0x000001B1B1543D00>>: on_open() takes 1 positional argument but 2 were given
error from callback <bound method StocknoteAPIPythonBridge.on_error of <snapi_py_client.snapi_bridge.StocknoteAPIPythonBridge object at 0x000001B1B1543D00>>: 
on_error() takes 2 positional arguments but 3 were given
cknmca commented 11 months ago

To ensure smooth performance with the websocket, it is essential to use the specific version 0.57.0 of the websocket-client. Please follow the steps below:

Uninstall the current websocket-client: pip uninstall websocket-client

Install the required version (0.57.0) of websocket-client: pip install websocket-client==0.57.0

After completing the above steps, you can check the websocket-client version using the "pip list" command. If you encounter any issues, kindly let us know, and we'll be happy to assist.

jagatsingh commented 11 months ago

pip install websocket-client==0.57.0

Hello @cknmca what is the hesistation in Smaco to update this to latest version?

I have noticed many people have requested it to be updated but your team it seems has abandoned all developmment on the Python SDK. It gives us less confidence should we rely on Samco for building higher level products of move towards other API providers.

Please bring it to attention of your mamangement and request them to put some resources for managing this SDK. It was last updated 3 years ago.