You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The GET /update status endpoint returns a JSON response containing status and log. Parsing the log for a human friendly message is not ideal and error prone.
I propose adding a message property in the JSON response that contains a descriptive message. This is important when a failed status is received. There are several cases where an update would fail such as already up to date, failed to decrypt update package, incorrect checksum of update package, etc. Each case should produce a unique error message to indicate the cause of failure.
Alternatively a code, statusCode or errorCode property could be added which would indicate a failure reason. The consumer of the API can write their own messages from the status code.
In either case, responding to an upgrade failure will become easier.
The text was updated successfully, but these errors were encountered:
That's not a bad idea. This occasionally trips me up as well when I'm forced to parse the log just to know what happened.
I prefer the status code approach since it's more flexible, and helps with occasionally cryptic error messages from various programs (ex, openssl's bad magic number).
The
GET /update
status endpoint returns a JSON response containingstatus
andlog
. Parsing the log for a human friendly message is not ideal and error prone.I propose adding a
message
property in the JSON response that contains a descriptive message. This is important when afailed
status is received. There are several cases where an update would fail such as already up to date, failed to decrypt update package, incorrect checksum of update package, etc. Each case should produce a unique error message to indicate the cause of failure.Alternatively a
code
,statusCode
orerrorCode
property could be added which would indicate a failure reason. The consumer of the API can write their own messages from the status code.In either case, responding to an upgrade failure will become easier.
The text was updated successfully, but these errors were encountered: