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

feat: exceptions handlers #2855

Merged
merged 4 commits into from
Dec 8, 2023
Merged

feat: exceptions handlers #2855

merged 4 commits into from
Dec 8, 2023

Conversation

magrinj
Copy link
Member

@magrinj magrinj commented Dec 6, 2023

This PR create a new integration called exception-capturer, this one only contains two driver for now Console and Sentry.

The goal of this integration is to send exception to a bug tracker like Sentry.

To capture exception, new exceptions filters has been created:

  • One that is capturing HttpException and transforming them into GraphQLError
  • One that is capturing TypeORMError and transforming them into GraphQLError
  • And the last one that is capturing all the other exceptions and sending them to the exception-capturer.

@magrinj magrinj force-pushed the feat/exception-handlers branch 2 times, most recently from dc479d9 to 61640dc Compare December 7, 2023 16:30
@magrinj magrinj changed the title feat: wip exception handlers feat: exceptions handlers Dec 7, 2023
@magrinj magrinj marked this pull request as ready for review December 7, 2023 16:34
Copy link
Member

@charlesBochet charlesBochet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice! I'm aligned with all changes

My only feedback is about the naming exception capturer. Exception Handler seems a better and more conventional naming

server/.env.example Outdated Show resolved Hide resolved
server/src/filters/global-exception.filter.ts Outdated Show resolved Hide resolved
@magrinj magrinj merged commit cf334ad into main Dec 8, 2023
5 of 6 checks passed
@magrinj magrinj deleted the feat/exception-handlers branch December 8, 2023 09:18
@charlesBochet charlesBochet mentioned this pull request Dec 8, 2023
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.

[Timebox] Investigate Sentry on Backend fix: TypeORM errors should be caught by Nest.js exception filter
2 participants