ring icon indicating copy to clipboard operation
ring copied to clipboard

Api server down or client bug?

Open terriblefox opened this issue 6 years ago • 8 comments

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

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

terriblefox avatar Mar 08 '20 07:03 terriblefox

Same here.

ronaldvans avatar Mar 08 '20 08:03 ronaldvans

OK seems the server is down.

terriblefox avatar Mar 08 '20 08:03 terriblefox

Its up again!

terriblefox avatar Mar 08 '20 08:03 terriblefox

It seems ok at the moment, Sun 3/8 at 8:50am EDT

david-olshefski avatar Mar 08 '20 12:03 david-olshefski

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!

tsightler avatar Mar 08 '20 14:03 tsightler

(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?

alexmanzer avatar Mar 10 '20 09:03 alexmanzer

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.

dgreif avatar Mar 10 '20 17:03 dgreif

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!

tsightler avatar Mar 10 '20 18:03 tsightler