Skip to content

Commit

Permalink
feat: additional debug info in case of error (#612)
Browse files Browse the repository at this point in the history
  • Loading branch information
philipparndt authored May 18, 2024
1 parent c1aeedf commit 2606908
Show file tree
Hide file tree
Showing 3 changed files with 613 additions and 1,462 deletions.
12 changes: 10 additions & 2 deletions app/lib/api/v2/hue-api-v2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,11 @@ const putLightLocked = async (resource: HueIdentifiable, message: PutLight) => {
return result.data
}
catch (e) {
log.error("Put light failed with error", message, e)
log.error("Put light failed with error", {
topic,
message,
e
})
}
}

Expand Down Expand Up @@ -117,7 +121,11 @@ export const putLight = async (light: HueIdentifiable, message: PutLight) => {
resolveResult()
}, (err) => {
if (err) {
log.error("Put light failed with error", message, err)
log.error("Put light failed with error [lock acquire]", {
light,
message,
err
})
}
})

Expand Down
Loading

0 comments on commit 2606908

Please sign in to comment.