Skip to content

fix(sentry): filter opaque Safari [object Event] noise#2624

Merged
koala73 merged 1 commit intomainfrom
fix/sentry-object-event-noise
Apr 2, 2026
Merged

fix(sentry): filter opaque Safari [object Event] noise#2624
koala73 merged 1 commit intomainfrom
fix/sentry-object-event-noise

Conversation

@koala73
Copy link
Copy Markdown
Owner

@koala73 koala73 commented Apr 2, 2026

Summary

  • Add ignoreErrors pattern for Safari 18.6 opaque Error: [object Event] with no stack trace
  • Also resolved 2 CSP report noise issues in Sentry (img-src cdn.css-tricks.com from browser extensions, frame-src about from Samsung Tizen)
  • All 3 issues marked resolved (inNextRelease) in Sentry

Test plan

  • TypeScript type check passes
  • Biome lint passes
  • All 2748 unit/data tests pass
  • Edge function bundle + isolation tests pass (146/146)
  • Markdown lint passes
  • Version sync passes

Safari 18.6 fires non-actionable Error with value "[object Event]"
and no stack trace. Adds ignoreErrors pattern to suppress it.
@vercel
Copy link
Copy Markdown

vercel bot commented Apr 2, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
worldmonitor Ignored Ignored Apr 2, 2026 4:37pm

Request Review

@greptile-apps
Copy link
Copy Markdown

greptile-apps bot commented Apr 2, 2026

Greptile Summary

This PR adds a single-line Sentry ignoreErrors filter (/^\[object Event\]$/) to suppress the opaque Safari 18.6 noise error [object Event], which carries no meaningful stack trace and cannot be actioned. The two accompanying CSP noise issues (cdn.css-tricks.com img-src and Samsung Tizen about frame-src) were resolved directly in Sentry's UI and do not require code changes.

The change fits cleanly into the existing pattern of browser-quirk noise suppression already established in src/main.ts (cf. /^Uncaught \[object ErrorEvent\]$/, /WKErrorDomain/, etc.)

  • The added regex /^\[object Event\]$/ is correctly anchored (^/$) and targets only the exact string produced when a DOM Event object is coerced to a string — it is very unlikely to mask any real application error.
  • Placement is consistent with adjacent browser-quirk patterns and follows the established code style.

Confidence Score: 5/5

  • Safe to merge — the change is an additive, low-risk noise filter with no functional impact.
  • Single regex added to an ignoreErrors array; the pattern is well-anchored, targets only the exact string [object Event] (a known browser-coercion artifact), and is consistent with a dozen similar patterns already in the file. No logic, no new dependencies, no risk of masking real errors.
  • No files require special attention.

Important Files Changed

Filename Overview
src/main.ts Adds /^\[object Event\]$/ to Sentry's ignoreErrors list to suppress Safari 18.6 opaque noise events; no logic changes and no functional risk.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Browser throws error] --> B{Sentry SDK intercepts}
    B --> C{Match ignoreErrors list?}
    C -- "Yes — e.g. /^\[object Event\]$/ (new)\nor /^Uncaught \[object ErrorEvent\]$/\nor /WKErrorDomain/ etc." --> D[Drop event — not sent to Sentry]
    C -- No --> E{beforeSend hook}
    E -- "msg.length <= 3 &\nalphanumeric-only" --> D
    E -- "MapLibre stack\nfilter match" --> D
    E -- Passes all filters --> F[Send event to Sentry]
Loading

Reviews (1): Last reviewed commit: "fix(sentry): filter opaque Safari [objec..." | Re-trigger Greptile

@koala73 koala73 merged commit 3569da0 into main Apr 2, 2026
8 checks passed
@koala73 koala73 deleted the fix/sentry-object-event-noise branch April 2, 2026 16:42
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.

1 participant