Api server down or client bug?
Seems the server is down? Anyone encountering similar issues?
[3/8/2020, 8:40:17 AM] [Ring] Request to https://app.ring.com/rhq/v1/devices/v1/locations failed with status 504. Response body:
504 Gateway Time-out
[3/8/2020, 8:40:17 AM] [Ring] Error connecting to API [3/8/2020, 8:40:17 AM] [Ring] Error: Request failed with status code 504
Same here.
OK seems the server is down.
Its up again!
It seems ok at the moment, Sun 3/8 at 8:50am EDT
I received the same issue last night with my ring-mqtt script using the API and the websocket seemed to stop attempting to reconnect but polling evens for cameras did continue. I received the following unhandled promise rejection but wasn't really sure if this was something I could trap on my side:
(node:26326) UnhandledPromiseRejectionWarning: Error: Request failed with status code 504
at createError (/opt/ring-mqtt/node_modules/axios/lib/core/createError.js:16:15)
at settle (/opt/ring-mqtt/node_modules/axios/lib/core/settle.js:17:12)
at IncomingMessage.handleStreamEnd (/opt/ring-mqtt/node_modules/axios/lib/adapters/http.js:236:11)
at IncomingMessage.emit (events.js:203:15)
at endReadableNT (_stream_readable.js:1145:12)
at process._tickCallback (internal/process/next_tick.js:63:19)
(node:26326) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 438)
Mainly just posting here in case it's useful or in case I can accidentally learn something!
(node:19286) UnhandledPromiseRejectionWarning: Error: Request failed with status code 504
at createError (/usr/local/lib/node_modules/homebridge-ring/node_modules/axios/lib/core/createError.js:16:15)
at settle (/usr/local/lib/node_modules/homebridge-ring/node_modules/axios/lib/core/settle.js:17:12)
at IncomingMessage.handleStreamEnd (/usr/local/lib/node_modules/homebridge-ring/node_modules/axios/lib/adapters/http.js:236:11)
at IncomingMessage.emit (events.js:215:7)
at endReadableNT (_stream_readable.js:1183:12)
at processTicksAndRejections (internal/process/task_queues.js:80:21)
(node:19286) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 409)
[3/8/2020, 08:07:33] [Ring] Request to https://app.ring.com/api/v1/mode/location/xxxxxxxxxxxxxxxxxxxxxx failed with status 504. Response body: <html>
<head><title>504 Gateway Time-out</title></head>
<body bgcolor="white">
<center><h1>504 Gateway Time-out</h1></center>
</body>
</html>
I get the 504 errors still today. Am I the only one?
Ring definitely had some issues over the last two days. If you see a 504, just assume that it's an issue from Ring's side, and try loading the Ring app to see if it errors as well. Sorry, but nothing I can do from the plugin side.
I guess I was hoping it might be possible to trap the error and attempt to reestablish the connection, more similar to what happens if the internet connection is down where the API automatically reconnects. So far as I've been able to tell once the 504 appears the only way to recover is to restart with a new API connection although, as I mentioned, polling still works. I guess I can try to catch it on my side and retry the API connection after the websocket has been disconnected X minutes. Thanks!