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 JSON exitcode attribute from a /v1/checker?command=foo response is a bit nasty to deserialize in statically typed languages, because its type varies in uncommon way:
if a command can be executed, the real exit code is propagated like {"excitcode": 0}, i.e. integer
if a command is not available for execution, we get {"excitcode": {}}, i.e. empty object
Integer has no empty form. A better representation would IMO be integer or null. This could be deserialized out of the box to e.g. Optional<int>.
The text was updated successfully, but these errors were encountered:
Thank you for the issue. Honestly the exit code should be 3 in case something fails, to always be able to return UNKNOWN.
I believe there is some error with handling errors properly.
The JSON
exitcode
attribute from a/v1/checker?command=foo
response is a bit nasty to deserialize in statically typed languages, because its type varies in uncommon way:{"excitcode": 0}
, i.e. integer{"excitcode": {}}
, i.e. empty objectInteger has no empty form. A better representation would IMO be
integer or null
. This could be deserialized out of the box to e.g.Optional<int>
.The text was updated successfully, but these errors were encountered: