tdorssers / TeslaPy

A Python module to use the Tesla Motors Owner API
MIT License
374 stars 83 forks source link

WebSocket does not terminate in streaming #114

Open amirhmk opened 1 year ago

amirhmk commented 1 year ago

Hi there,

I have been playing around with the streaming functionality, but I'm getting some weird behaviour. I have set retry=3 so if wsapp terminates, it tries to reconnect up to 3 times. However, after the disconnect, it seems like it connects to the server again, but does not receive any messages anymore and it gets stuck in that state (web socket still running).

I have left ping_interval=10 to its default, and tried adding ping_timeout=5 to see if it fixes it, but have not been successful. Have you faced this issue before?

I'm wondering if this perhaps could be due to the vehicle becoming unavailable? i.e. no data connectivity?

tdorssers commented 1 year ago

I am not using streaming at all, it only seems useful for real time location plotting while driving. For almost all other cases you simply poll the API.