OpenApi-5p / py5paisa

Official Python SDK for 5paisa APIs natively written in VB .NET
https://5paisa.github.io
89 stars 68 forks source link

live streamming is not working #295

Closed ATULRAHUL closed 4 months ago

ATULRAHUL commented 4 months ago

req_list = list() When I try to subscribe to a token feed using,

for i in range(len(master_contract_fut["ScripCode"])): req_list.append({"Exch": "N", "ExchType": "D", "ScripCode": (int(master_contract_fut["ScripCode"].values[i]))})

req_data = client.Request_Feed('mf', 's', req_list)

def on_message(ws, message): ticks = message print(ticks)

ticks = json.loads(ticks)

#insert_ticks(ticks)

client.connect(req_data)

client.receive_data(on_message)

error is : it just provided the data once and was not in the loop.

vikithakrar commented 4 months ago

has this started working? still gives rates (bid/off) of 0.