Skip to content

feat(cloudflare)!: Auto-instrument the Worker by default in the Vite plugin - #23273

Merged
JPeer264 merged 1 commit into
developfrom
jp/flip-auto-instrument-vite-plugin
Aug 11, 2026
Merged

feat(cloudflare)!: Auto-instrument the Worker by default in the Vite plugin#23273
JPeer264 merged 1 commit into
developfrom
jp/flip-auto-instrument-vite-plugin

Conversation

@JPeer264

Copy link
Copy Markdown
Member

This flips the autoInstrumentation flag to be default true and moves it from _experimental to top-level. The autoInstrumentation flag shouldn't do any harm on already instrumented Workers, so people who already instrument their stuff manually, they have this flag on, but are not affected.


Clanker description:

sentryCloudflareVitePlugin() now wraps the Worker entry and the Durable Object, Workflow and WorkerEntrypoint classes from the wrangler config at build time. The opt-in moves from _experimental.autoInstrumentation to a top-level autoInstrumentation option defaulting to true; the experimental option is removed rather than deprecated.

…plugin

`sentryCloudflareVitePlugin()` now wraps the Worker entry and the Durable
Object, Workflow and WorkerEntrypoint classes from the wrangler config at
build time. The opt-in moves from `_experimental.autoInstrumentation` to a
top-level `autoInstrumentation` option defaulting to `true`; the experimental
option is removed rather than deprecated.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@JPeer264 JPeer264 self-assigned this Aug 11, 2026
@JPeer264
JPeer264 requested a review from a team as a code owner August 11, 2026 10:00
@JPeer264
JPeer264 requested review from chargome, isaacs, mydea and nicohrubec and removed request for a team, isaacs and mydea August 11, 2026 10:00
Comment thread packages/cloudflare/src/vite/index.ts

@chargome chargome left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good!

@github-actions

Copy link
Copy Markdown
Contributor

size-limit report 📦

⚠️ Warning: Base artifact is not the latest one, because the latest workflow run is not done yet. This may lead to incorrect results. Try to re-run all tests to get up to date results.

Path Size % Change Change
@sentry/browser 30.26 kB - -
@sentry/browser - with treeshaking flags 28.44 kB - -
@sentry/browser - with treeshaking flags tracing without tracing 26.78 kB - -
@sentry/browser (incl. Tracing) 48.5 kB - -
@sentry/browser (incl. Tracing + Span Streaming) 48.52 kB - -
@sentry/browser (incl. Tracing, Profiling) 51.4 kB - -
@sentry/browser (incl. Tracing, Replay) 87.94 kB - -
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 77.3 kB - -
@sentry/browser (incl. Tracing, Replay with Canvas) 92.65 kB - -
@sentry/browser (incl. Tracing, Replay, Feedback) 105.32 kB - -
@sentry/browser (incl. Feedback) 47.58 kB - -
@sentry/browser (incl. sendFeedback) 35.08 kB - -
@sentry/browser (incl. FeedbackAsync) 40.23 kB - -
@sentry/browser (incl. Metrics) 31.29 kB - -
@sentry/browser (incl. Logs) 31.55 kB - -
@sentry/browser (incl. Metrics & Logs) 32.24 kB - -
@sentry/react 32.06 kB - -
@sentry/react (incl. Tracing) 50.69 kB - -
@sentry/vue 35.32 kB - -
@sentry/vue (incl. Tracing) 50.45 kB - -
@sentry/svelte 30.28 kB - -
CDN Bundle 31.52 kB - -
CDN Bundle (incl. Tracing) 48.78 kB - -
CDN Bundle (incl. Logs, Metrics) 33.75 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) 50.76 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) 74.3 kB - -
CDN Bundle (incl. Tracing, Replay) 86.38 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) 88.29 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) 92.08 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) 94.1 kB - -
CDN Bundle - uncompressed 93.59 kB - -
CDN Bundle (incl. Tracing) - uncompressed 146.5 kB - -
CDN Bundle (incl. Logs, Metrics) - uncompressed 100.06 kB - -
CDN Bundle (incl. Tracing, Logs, Metrics) - uncompressed 152.36 kB - -
CDN Bundle (incl. Replay, Logs, Metrics) - uncompressed 228.98 kB - -
CDN Bundle (incl. Tracing, Replay) - uncompressed 265.75 kB - -
CDN Bundle (incl. Tracing, Replay, Logs, Metrics) - uncompressed 271.6 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback) - uncompressed 279.45 kB - -
CDN Bundle (incl. Tracing, Replay, Feedback, Logs, Metrics) - uncompressed 285.28 kB - -
@sentry/nextjs (client) 53.24 kB - -
@sentry/sveltekit (client) 48.91 kB - -
@sentry/core/server 65.45 kB - -
@sentry/core/browser 51.79 kB - -
@sentry/node 117.89 kB - -
@sentry/node/import (ESM hook with diagnostics-channel injection) 0 B added added
@sentry/node - without tracing 82.05 kB -0.01% -1 B 🔽
@sentry/aws-serverless 91.42 kB - -
@sentry/cloudflare (withSentry) - minified 214.07 kB - -
@sentry/cloudflare (withSentry) 528.94 kB - -

View base workflow run

@JPeer264
JPeer264 merged commit 0b43807 into develop Aug 11, 2026
83 checks passed
@JPeer264
JPeer264 deleted the jp/flip-auto-instrument-vite-plugin branch August 11, 2026 14:05
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.

2 participants