hjespers / teslams

Tesla node.js apps and javascript libraries using Tesla's HTTP interfaces
BSD 3-Clause "New" or "Revised" License
417 stars 106 forks source link

Streaming API #137

Open jkropp opened 5 years ago

jkropp commented 5 years ago

Streaming API not working, html bad request error.

bendinwire commented 5 years ago

Seeing the same thing.

TheSpaceCowboy commented 5 years ago

I'm not sure if this is what you are getting, but this began about 6 days ago or so. The 502 contines without end. Cut & paste from streaming startup: timestamp: 1552955768856 } 18 Mar 20:37:07 - getting charge state Aux data 18 Mar 20:37:07 - getting climate state Aux data 18 Mar 20:38:07 - getting charge state Aux data 18 Mar 20:38:07 - getting climate state Aux data 18 Mar 20:38:13 - Polling again because poll returned HTTP error:Error: ESOCKETTIMEDOUT 18 Mar 20:38:23 - Bad timestamp () 18 Mar 20:38:23 - Unexpected problem with request: Response status code = 502 Error code = null Polling again in 10 seconds...

wumpus commented 5 years ago

There's probably an error message in the thing that starts with "\<html>\n" ... which, btw, is visible in the github email and not above because you didn't quote the \<html>

TheSpaceCowboy commented 5 years ago

True, there was an html in the bad timestamp message, but it disappeared in the cut and paste. The error message was the 502 error.

wumpus commented 5 years ago

Well, if the error message wasn't informative, then perhaps it's worth watching with the Tesla app at the same time you're making this call. If the app continues working, then perhaps you've triggered some kind of defense, or, the Tesla app isn't using that interface the same way these days.

MichaelSinz commented 5 years ago

I had this start on March 7th. I have not yet discovered the real cause but I have been streaming my telemetry for well over a year (including needing updates a few times) but this time I can't seem to find the problem. I still can control the car (including turning on the climate system in the morning)

MichaelSinz commented 5 years ago

PS - the error returned is:

<head><title>502 Bad Gateway</title></head>
<body bgcolor="white">
<center><h1>502 Bad Gateway</h1></center>
<hr><center>nginx</center>
</body>
</html>