Nag
 · Trader, Algo enthusiast

Found an issue with websocket Fyers API V3

Hello, I have found a weird behavior with websocket.

I have subscribed to a symbol while starting the websocket (NSE:BANKNIFTY24JANFUT), later based on my logic I have subscribed to another symbol (NSE:BANKNIFTY2410348200CE). After few minutes I have lost my connection "Error: Connection to remote host was lost." When it reconnects again, I see websocket is subscribed to only the first symbol (NSE:BANKNIFTY24JANFUT) not the second symbol.

websocket logs:

[2023-12-27 09:14:52,250] {st_websock.py:64} INFO - subscribed:: ['NSE:BANKNIFTY24JANFUT']

[2023-12-27 09:17:00,637] {st_websock.py:69} INFO - subscribed: ['NSE:BANKNIFTY2410348200CE']

[2023-12-27 09:19:58,345] {st_websock.py:54} INFO - Error: Connection to remote host was lost.

[2023-12-27 09:20:05,568] {st_websock.py:64} INFO - subscribed:: ['NSE:BANKNIFTY24JANFUT']

Is this the known issue? any work around for this?

4 replies