def on_tick(tick, ws):
# Callback for successful connection.
kws.on_tick = on_tick
kws.on_connect = on_connect
kws.connect(disable_ssl_verification=True) #im using UBUNTU
You need to call stop_retry and then close connection.
As you suggested ,I tried with below code .
def on_ticks(ws, ticks):
# Callback to receive ticks.
but thread is not closing even after that ,but I can see its not trying to connect again and again.
From above example, please guide me how i can close the connection properly after receiving 1 tick? some example please..
You need to call close() method. You can check out python documentation.
Inside on_close() you need to call stop as mentioned by @vivek.
builtins.AttributeError: 'KiteTicker' object has no attribute 'stop'