-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed as not planned
Closed as not planned
Copy link
Description
Environment
- @sentry/react 7.91.0
- React 18 (CRA)
- No DSN provided intentionally (for local development)
Problem
When DSN
is undefined, and beforeSend
attempts to mutate the event object (e.g. strip sensitive fields), the mutation is ignored entirely and the function seems to be skipped.
Steps to Reproduce
- Initialize Sentry without a DSN.
- Add
beforeSend
that mutatesevent.extra
orevent.request
. - Log error via
Sentry.captureMessage("test")
.
Expected Result
beforeSend
still runs and mutates event before it's discarded.
Actual Result
beforeSend
is silently skipped; event object remains unprocessed.
Suggestion
Perhaps invoke beforeSend
even when DSN is undefined β for dev-mode debugging/logging flows.
Metadata
Metadata
Assignees
Projects
Status
Waiting for: Product Owner