It tries to get the status of the exception by calling exception.status. However, if we follow the nestjs docs and throw exceptions, the status should be read with exception.getStatus().
Expected Result
Http errors where status is >=400 and <500 should not be reported to sentry
Actual Result
Http errors where status is >=400 and <500 are reported to sentry
Hey, this feature was only recently introduced and was not yet part of the 8.13.0 SDK release. We just released 8.14.0, which now includes the filtering. So updating to 8.14.0 should fix your issue.
Is there an existing issue for this?
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/node
SDK Version
8.13.0
Framework Version
No response
Link to Sentry event
No response
SDK Setup/Reproduction Example
No response
Steps to Reproduce
The issue is with this line: https://github.com/getsentry/sentry-javascript/blob/13ff71f8adfbdfe3de0f9e50ff59f5ebbfa131f9/packages/node/src/integrations/tracing/nest.ts#L103
It tries to get the status of the exception by calling
exception.status
. However, if we follow the nestjs docs and throw exceptions, the status should be read withexception.getStatus()
.Expected Result
Http errors where status is >=400 and <500 should not be reported to sentry
Actual Result
Http errors where status is >=400 and <500 are reported to sentry