Open Rahulsoni0302 opened 7 months ago
@Kotak-Neo
inst_token1 = [{"instrument_token": "26009", "exchange_segment": "nse_cm"}] t1 = threading.Thread(target= client.subscribe , args=(inst_token1,)) t1.start()
and after some time subscribed to another one
inst_token2 = [{"instrument_token": "58274", "exchange_segment": "nse_fo"}]
client.subscribe(instrument_tokens=inst_token2)
now when i tried to unsubscribe the second script using
Shared.client.un_subscribe(instrument_tokens=inst_token2)
i'm getting the response like this :
The Data has been Un-Subscribed [Res]: Un-Subscribed Successfully!
but ideally i should be getting the response for the token no. 26009
help me .
i use client.quote in a while loop : )
@aswinm227 bro i tried your solution but still websocket connection is getting disconnected. Thanks for you help : )
@Kotak-Neo
I have subscribed to some tokens
inst_token1 = [{"instrument_token": "26009", "exchange_segment": "nse_cm"}] t1 = threading.Thread(target= client.subscribe , args=(inst_token1,)) t1.start()
and after some time subscribed to another one
inst_token2 = [{"instrument_token": "58274", "exchange_segment": "nse_fo"}]
Get live feed data
client.subscribe(instrument_tokens=inst_token2)
now when i tried to unsubscribe the second script using
Shared.client.un_subscribe(instrument_tokens=inst_token2)
i'm getting the response like this :
The Data has been Un-Subscribed [Res]: Un-Subscribed Successfully!
but ideally i should be getting the response for the token no. 26009
help me .