ERROR:kiteconnect.ticker:Connection error: 0 - error parsing tokens.

Rupali
I am getting error: ERROR:kiteconnect.ticker:Connection error: 0 - error parsing tokens.
Here is the code...

def on_ticks(ws, ticks):
# Callback to receive ticks.
logging.debug("Ticks: {}".format(ticks))

def on_connect(ws, response):
ws.subscribe([5097])
ws.set_mode(ws.MODE_FULL, [5097])

def on_close(ws, code, reason):
# On connection close stop the event loop.
# Reconnection will not happen after executing `ws.stop()`
ws.stop()

# Assign the callbacks.
kws.on_ticks = on_ticks
kws.on_connect = on_connect
kws.on_close = on_close

# Infinite loop on the main thread. Nothing after this will run.
# You have to use the pre-defined callbacks to manage subscriptions.
kws.connect()
Tagged:
This discussion has been closed.