How do you use Sentry?
Sentry Saas (sentry.io)
Version
2.9.0
Steps to Reproduce
From Discord:
Using Sentry with FastAPI, I'm initializing Sentry as follows:
failed_request_status_codes = [range(400, 600)]
sentry_sdk.init(
integrations=[
StarletteIntegration(failed_request_status_codes=failed_request_status_codes),
FastApiIntegration(failed_request_status_codes=failed_request_status_codes),
],
before_send=filter_transactions,
)
HTTPException raised directly or unexpected 500 errors are well reported to Sentry. However, 422 errors, where the request doesn't match the expected type, are not being sent to Sentry. How can I resolve this?
Expected Result
422s should be reported.
Actual Result
422s are not reported.