Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added unhandledRejection error handling to koa app #14318

Closed
wants to merge 1 commit into from

Conversation

deanhannigan
Copy link
Contributor

Description

Uncaught promise rejections in the Google Sheets integration would eventually be caught in the uncaughtException handler in the koa app. This would then terminate the server.

This fix adds general handling for uncaught rejections in the koa app and logs any events to bb-alert

Addresses

Launchcontrol

Add handling for uncaughtRejection in the koa app.

@deanhannigan deanhannigan requested a review from a team as a code owner August 5, 2024 11:17
@deanhannigan deanhannigan requested review from adrinr and removed request for a team August 5, 2024 11:17
@mike12345567
Copy link
Collaborator

Hey @deanhannigan - we actually intentionally don't handle stuff like this, as an unhandled promise like is coming from the googlesheets library is a severe issue we want the process to crash and make us aware something very bad has happened.

We had build protections in place for our backend services to avoid unhandled promises via static analysis but for libraries we don't have this luxury - however when it does happen its best we're made aware as directly as possible.

@github-actions github-actions bot locked and limited conversation to collaborators Aug 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants