Skip to content

feat(browser)!: Extract interaction spans into new interactionsIntegration - #23295

Draft
msonnb wants to merge 3 commits into
developfrom
ms/interactions-integration
Draft

feat(browser)!: Extract interaction spans into new interactionsIntegration#23295
msonnb wants to merge 3 commits into
developfrom
ms/interactions-integration

Conversation

@msonnb

@msonnb msonnb commented Aug 11, 2026

Copy link
Copy Markdown
Member

What

This extracts interaction spans into a new opt-in (standalone) interactionsIntegration.

// before
Sentry.browserTracingIntegration({ _experiments: { enableInteractions: true } });

// after
[Sentry.browserTracingIntegration(), Sentry.interactionsIntegration()];

Why

Interaction idle spans have been experimental since v7. We don't expect to promote them to stable, but they still cost bundle size for every user of browserTracingIntegration.

closes #22353

…ration`

Interaction spans (`ui.action.click` idle spans and `ui.interaction.click`
event-timing spans) are no longer part of `browserTracingIntegration`. They move
into a standalone, opt-in `interactionsIntegration`.

The experimental `_experiments.enableInteractions` option is removed. As it was
the only experimental option, `browserTracingIntegration` no longer accepts an
`_experiments` object at all. The `idleTimeout`, `finalTimeout` and
`childSpanTimeout` options for interaction spans are configured on the new
integration instead of being inherited, using the same defaults.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@msonnb

msonnb commented Aug 11, 2026

Copy link
Copy Markdown
Member Author

bugbot run

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit e5e9450. Configure here.

},
},
idleSpanOptions,
);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing origin on idle spans

Medium Severity

startIdleSpan for ui.action.click does not set SENTRY_ORIGIN / sentry.origin. Spans then default to manual, so auto-instrumented interaction idle spans are mis-attributed. Child ui.interaction.click spans already set origin correctly. This violates the PR review rule that every startSpan API call must set a proper span origin (see https://develop.sentry.dev/sdk/telemetry/traces/trace-origin/).

Fix in Cursor Fix in Web

Triggered by project rule: PR Review Guidelines for Cursor Bot

Reviewed by Cursor Bugbot for commit e5e9450. Configure here.

@github-actions

github-actions Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

size-limit report 📦

Path Size % Change Change
@sentry/browser 30.29 kB - -
@sentry/browser - with treeshaking flags 28.47 kB - -
@sentry/browser - with treeshaking flags tracing without tracing 26.8 kB - -
@sentry/browser (incl. Tracing) 48.24 kB -0.62% -300 B 🔽
@sentry/browser (incl. Tracing + Span Streaming) 48.26 kB -0.63% -305 B 🔽
@sentry/browser (incl. Tracing, Profiling) 51.18 kB -0.51% -259 B 🔽
@sentry/browser (incl. Tracing, Replay) 87.66 kB -0.33% -288 B 🔽
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 77.13 kB -0.29% -224 B 🔽
@sentry/browser (incl. Tracing, Replay with Canvas) 92.37 kB -0.32% -292 B 🔽
@sentry/browser (incl. Tracing, Replay, Feedback) 105.06 kB -0.29% -298 B 🔽
@sentry/browser (incl. Feedback) 47.61 kB - -
@sentry/browser (incl. sendFeedback) 35.11 kB - -
@sentry/browser (incl. FeedbackAsync) 40.27 kB +0.02% +6 B 🔺
@sentry/browser (incl. Metrics) 31.28 kB - -
@sentry/browser (incl. Logs) 31.53 kB - -
@sentry/browser (incl. Metrics & Logs) 32.2 kB - -
@sentry/react 32.09 kB - -
@sentry/react (incl. Tracing) 50.43 kB -0.6% -302 B 🔽
@sentry/vue 35.34 kB - -
@sentry/vue (incl. Tracing) 50.21 kB -0.58% -291 B 🔽
@sentry/svelte 30.31 kB - -
CDN Bundle 31.6 kB +0.03% +8 B 🔺
CDN Bundle (incl. Tracing) 48.74 kB -0.28% -132 B 🔽
CDN Bundle (incl. Logs, Metrics) 33.81 kB +0.03% +8 B 🔺
CDN Bundle (incl. Tracing, Logs, Metrics) 50.7 kB -0.25% -127 B 🔽
CDN Bundle (incl. Replay, Logs, Metrics) 74.34 kB +0.01% +2 B 🔺
CDN Bundle (incl. Tracing, Replay) 86.21 kB -0.3% -254 B 🔽
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) 88.11 kB -0.25% -220 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback) 91.95 kB -0.24% -220 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) 93.93 kB -0.23% -216 B 🔽
CDN Bundle - uncompressed 93.79 kB +0.03% +20 B 🔺
CDN Bundle (incl. Tracing) - uncompressed 145.87 kB -0.55% -793 B 🔽
CDN Bundle (incl. Logs, Metrics) - uncompressed 100.19 kB +0.02% +20 B 🔺
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed 151.67 kB -0.53% -793 B 🔽
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed 229.12 kB +0.01% +20 B 🔺
CDN Bundle (incl. Tracing, Replay) - uncompressed 265.13 kB -0.3% -788 B 🔽
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed 270.91 kB -0.3% -788 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 278.82 kB -0.29% -788 B 🔽
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed 284.6 kB -0.28% -788 B 🔽
@sentry/nextjs (client) 52.98 kB -0.59% -313 B 🔽
@sentry/sveltekit (client) 48.67 kB -0.59% -287 B 🔽
@sentry/core/server 65.44 kB - -
@sentry/core/browser 51.8 kB - -
@sentry/node 117.98 kB -0.01% -1 B 🔽
@sentry/node/import (ESM hook with diagnostics-channel injection) 0 B added added
@sentry/node - without tracing 82.09 kB - -
@sentry/aws-serverless 91.5 kB - -
@sentry/cloudflare (withSentry) - minified 214.1 kB - -
@sentry/cloudflare (withSentry) 528.64 kB - -

View base workflow run

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.

Move experimental interaction spans to dedicated integration

1 participant