Skip to content

Feat: Use bugsnag error logging in api in place of console.error - #1956

Open
stevecassidy wants to merge 4 commits into
mainfrom
chore/bugsnag-logging-in-api
Open

Feat: Use bugsnag error logging in api in place of console.error#1956
stevecassidy wants to merge 4 commits into
mainfrom
chore/bugsnag-logging-in-api

Conversation

@stevecassidy

Copy link
Copy Markdown
Contributor

Use bugsnag error logging in api in place of console.error

JIRA Ticket

None

Description

Replaces most uses of console.error with a call to logError which uses Bugsnag if configured so that we get error reports via bugsnag in production.

Checklist

  • I have confirmed all commits have been signed.
  • I have added JSDoc style comments to any new functions or classes.
  • Relevant documentation such as READMEs, guides, and class comments are updated.

Signed-off-by: Steve Cassidy <steve@fieldnote.au>
Signed-off-by: Steve Cassidy <steve@fieldnote.au>
@stevecassidy

Copy link
Copy Markdown
Contributor Author

Also note in passing that since we use thown errors to report things back to the user via API responses we are logging some errors that don't need logging like expired tokens - maybe selectively use explicit return values for these rather than errors so that we minimise logging to actual problems.

Signed-off-by: Steve Cassidy <steve@fieldnote.au>
Signed-off-by: Steve Cassidy <steve@fieldnote.au>
@stevecassidy stevecassidy changed the title Use bugsnag error logging in api in place of console.error Feat: Use bugsnag error logging in api in place of console.error Apr 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant