Conversation

AbhiPrasad

It seems like this change introduced a problem where accessing event.detail causes a DOMException to be thrown (only on firefox?). This is causing the SDK to crash if someone has tracing enabled. Until we figure out a reproduction and a more formal fix (with some e2e tests) let's revert the problematic PR and move forward.

Reverts #16240

ref #16347

@AbhiPrasadAbhiPrasad requested a review from a team May 20, 2025 18:47
@AbhiPrasadAbhiPrasad self-assigned this May 20, 2025
@AbhiPrasadAbhiPrasad requested review from stephanie-anderson and s1gr1d and removed request for a team May 20, 2025 18:47
@github-actionsGitHub Actions

size-limit report 📦

PathSize% ChangeChange
@sentry/browser23.95 kB--
@sentry/browser - with treeshaking flags23.71 kB--
@sentry/browser (incl. Tracing)38.27 kB-0.25%-95 B 🔽
@sentry/browser (incl. Tracing, Replay)76.38 kB-0.12%-86 B 🔽
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags69.49 kB-0.14%-92 B 🔽
@sentry/browser (incl. Tracing, Replay with Canvas)81.16 kB-0.12%-90 B 🔽
@sentry/browser (incl. Tracing, Replay, Feedback)93.25 kB-0.11%-100 B 🔽
@sentry/browser (incl. Feedback)40.72 kB--
@sentry/browser (incl. sendFeedback)28.67 kB--
@sentry/browser (incl. FeedbackAsync)33.56 kB--
@sentry/react25.73 kB--
@sentry/react (incl. Tracing)40.24 kB-0.23%-92 B 🔽
@sentry/vue28.34 kB--
@sentry/vue (incl. Tracing)40.09 kB-0.26%-102 B 🔽
@sentry/svelte23.97 kB--
CDN Bundle25.23 kB--
CDN Bundle (incl. Tracing)38.37 kB-0.38%-146 B 🔽
CDN Bundle (incl. Tracing, Replay)74.23 kB-0.09%-63 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback)79.66 kB-0.12%-88 B 🔽
CDN Bundle - uncompressed73.63 kB--
CDN Bundle (incl. Tracing) - uncompressed113.66 kB-0.33%-367 B 🔽
CDN Bundle (incl. Tracing, Replay) - uncompressed227.63 kB-0.17%-367 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed240.45 kB-0.16%-367 B 🔽
@sentry/nextjs (client)41.9 kB-0.22%-90 B 🔽
@sentry/sveltekit (client)38.74 kB-0.25%-95 B 🔽
@sentry/node149.47 kB--
@sentry/node - without tracing98.1 kB--
@sentry/aws-serverless123.43 kB--

View base workflow run

@AbhiPrasadAbhiPrasad enabled auto-merge (squash) May 20, 2025 18:59
@AbhiPrasadAbhiPrasad merged commit acc6fe1 into develop May 20, 2025
126 checks passed
@AbhiPrasadAbhiPrasad deleted the revert-16240-abhi-performance-measure-detail branch May 20, 2025 18:59
AbhiPrasad added a commit that referenced this pull request Jun 13, 2025
…16557)

resolves #16237

In #16348 we had to revert the PR that added `detail` to `measure` spans
as attributes.

measure API:
https://developer.mozilla.org/en-US/docs/Web/API/Performance/measure
detail:
https://developer.mozilla.org/en-US/docs/Web/API/PerformanceMeasure/detail

This was
[reverted](#16347)
because it was causing issues in firefox, specifically this error was
being thrown

```
Error: Permission denied to access object
  at _addMeasureSpans(../../node_modules/@sentry-internal/browser-utils/build/esm/metrics/browserMetrics.js:255:41)
  at X2e/<(../../node_modules/@sentry-internal/browser-utils/build/esm/metrics/browserMetrics.js:194:9)
  at addPerformanceEntries(../../node_modules/@sentry-internal/browser-utils/build/esm/metrics/browserMetrics.js:174:48)
  at idleSpan.beforeSpanEnd(../../node_modules/@sentry/browser/build/npm/esm/tracing/browserTracingIntegration.js:90:9)
  at span.endapply(../../node_modules/@sentry/browser/node_modules/@sentry/core/build/esm/tracing/idleSpan.js:52:9)
  at Coe/<(../../node_modules/@sentry/browser/node_modules/@sentry/core/build/esm/tracing/idleSpan.js:196:12)
  at sentryWrapped(../../node_modules/@sentry/browser/build/npm/esm/helpers.js:38:17)
```

From debugging, this seems to be coming from a `DOMException` being
thrown @https://developer.mozilla.org/en-US/docs/Web/API/DOMException

This was re-implemented, and then we added tests to validate that this
wouldn't break on firefox.

---------

Co-authored-by: Cursor Agent <[email protected]>
Sign up for free to join this conversation on . Already have an account? Sign in to comment
None yet
None yet

Successfully merging this pull request may close these issues.