Repository navigation
fix(cloudflare): Use the release that a Sentry bundler plugin injected - #26914
Merged
Merged
Conversation
Contributor
size-limit report 📦Compared: ede0dee (PR test merge using develop at e07c24f) Against: a159856 (develop) · base run #68059
|
Contributor
Optional E2E testsAll optional checks were successful. 52 successful. See the run. Successful checks
|
A Sentry bundler plugin, for example the one of `sentryTanstackStart` or `sentryCloudflareVitePlugin`, writes the release of the build to `globalThis.SENTRY_RELEASE`. The Node and Vercel Edge SDKs read it, but the Cloudflare SDK did not, so server events of a Worker had no release unless the `release` option or the `SENTRY_RELEASE` env var was set. The injected release now comes after the `SENTRY_RELEASE` env var and before `CF_VERSION_METADATA.id`, as it is the release the user configured for the build. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
JPeer264
force-pushed
the
jp/tanstackstart-serverfn-middleware-id
branch
from
November 26, 2026 08:13
7ed1b89 to
97656bb
Compare
JPeer264
force-pushed
the
jp/cloudflare-injected-release
branch
from
November 26, 2026 08:13
dc5c5dc to
6ca971e
Compare
JPeer264
changed the base branch from
jp/tanstackstart-serverfn-middleware-id
to
develop
November 26, 2026 09:54
JPeer264
marked this pull request as ready for review
November 26, 2026 10:01
JPeer264
requested review from
nicohrubec
and removed request for
RulaKhaled and
isaacs
November 26, 2026 10:05
nicohrubec
approved these changes
Nov 26, 2026
51 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This makes
@sentry/cloudflareuse the release that a Sentry bundler plugin injected into the build (globalThis.SENTRY_RELEASE), for example the plugin ofsentryTanstackStartorsentryCloudflareVitePlugin.Why
The Node and Vercel Edge SDKs read the injected release, but the Cloudflare SDK did not. Server events of a Worker had no release unless the
releaseoption or theSENTRY_RELEASEenv var was set.Release priority decisions
The order is now:
releaseoption,SENTRY_RELEASEenv var, injected release,CF_VERSION_METADATA.id. The injected release is before the version metadata, because it is the release that the user configured for the build. The alternative is to put it last.