[DO NOT MERGE]: chore(deps): bump @sentry/* to 11.0.0-beta.0 - #6665
[DO NOT MERGE]: chore(deps): bump @sentry/* to 11.0.0-beta.0#6665antonis wants to merge 10 commits into
Conversation
Spike to surface JS v11 compatibility issues via CI. Bumps first-party @sentry/* dependencies (browser, core, react, bundler-plugins, eslint-plugin-sdk, typescript) to 11.0.0-alpha.2 across core and the sample/e2e apps, and adapts the SDK source to the v11 breaking changes: - spanToJSON() now returns the streamed shape; switched the internals that need the classic SpanJSON to spanToStaticSpanJSON(). - inboundFiltersIntegration -> eventFiltersIntegration (re-exported under the RN public name). - AI instrumentation (OpenAI/Anthropic/GenAI/LangChain/LangGraph) moved to server-only @sentry/server-utils; dropped those re-exports. - SEMANTIC_ATTRIBUTE_SENTRY_SOURCE -> SENTRY_SEGMENT_NAME_SOURCE alias. - ExtendedError / User index signatures tightened to unknown; narrowed the affected call sites. - enableLogs and sendDefaultPii are now RN-owned options (core removed them / RN Omits dataCollection); cast getOptions() accordingly. - Test harness migrated off the removed Scope.clear() via a clearAllScopes() helper in test/testutils.ts. Local: yarn build compiles clean. Known remaining test failures are tracked as follow-ups (old span shape in assertions, obsolete AI export test, measurements investigation). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- Remove orphaned getCurrentScope/getGlobalScope/getIsolationScope imports left by the Scope.clear() -> clearAllScopes() test migration (10 files). - Regenerate the API report to reflect the removed AI instrumentation re-exports and the inboundFilters -> eventFilters rename. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Format the 16 source/test files touched by the v11 migration. The earlier Lint run never reached the oxfmt step because oxlint failed first on the orphaned scope imports; with those fixed, oxfmt --check surfaced the drift. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Bumps the JS SDK spike from 11.0.0-alpha.2 to 11.0.0-beta.0 across core, samples and e2e-tests. beta.0 splits the `@sentry/core` main entry into shared/browser/server subpaths, removing `startIdleSpan` and `XhrBreadcrumbHint` from the root export. Import both from the `@sentry/core/browser` subpath (the root-level shim stubs keep classic `moduleResolution: node` resolution working): - tracing/span.ts: `startIdleSpan` -> `@sentry/core/browser` - replay/xhrUtils.ts: `XhrBreadcrumbHint` type -> `@sentry/core/browser` Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Semver Impact of This PR⚪ None (no version bump detected) 📋 Changelog PreviewThis is how your changes will appear in the changelog.
🤖 This preview updates automatically when you update the PR. |
Android (legacy) Performance metrics 🚀
|
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| 0b5120f+dirty | 503.22 ms | 538.60 ms | 35.38 ms |
| ad66da3+dirty | 468.46 ms | 533.56 ms | 65.10 ms |
| 8448c07+dirty | 422.88 ms | 471.22 ms | 48.34 ms |
| 9474ead+dirty | 411.45 ms | 446.80 ms | 35.35 ms |
| f6ce4ff+dirty | 464.62 ms | 481.48 ms | 16.86 ms |
| 890d145+dirty | 504.54 ms | 491.55 ms | -12.99 ms |
| 68ae91b+dirty | 416.44 ms | 477.56 ms | 61.12 ms |
| 3ce5254+dirty | 410.57 ms | 448.48 ms | 37.91 ms |
| acd838e+dirty | 422.63 ms | 462.39 ms | 39.76 ms |
| 2e64504+dirty | 450.52 ms | 482.70 ms | 32.18 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| 0b5120f+dirty | 48.30 MiB | 53.58 MiB | 5.28 MiB |
| ad66da3+dirty | 48.30 MiB | 53.49 MiB | 5.19 MiB |
| 8448c07+dirty | 49.74 MiB | 55.37 MiB | 5.63 MiB |
| 9474ead+dirty | 48.30 MiB | 53.61 MiB | 5.30 MiB |
| f6ce4ff+dirty | 49.74 MiB | 55.45 MiB | 5.71 MiB |
| 890d145+dirty | 43.75 MiB | 48.14 MiB | 4.39 MiB |
| 68ae91b+dirty | 49.74 MiB | 54.79 MiB | 5.05 MiB |
| 3ce5254+dirty | 43.75 MiB | 48.12 MiB | 4.37 MiB |
| acd838e+dirty | 48.30 MiB | 53.60 MiB | 5.30 MiB |
| 2e64504+dirty | 49.74 MiB | 55.45 MiB | 5.71 MiB |
📲 Install BuildsAndroid
|
iOS (legacy) Performance metrics 🚀
|
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| ecf47a2+dirty | 3835.20 ms | 1222.43 ms | -2612.77 ms |
| 3817909+dirty | 1183.90 ms | 1187.50 ms | 3.60 ms |
| 5ee78d6+dirty | 3847.52 ms | 1224.27 ms | -2623.25 ms |
| 890d145+dirty | 1223.59 ms | 1231.37 ms | 7.78 ms |
| e763471+dirty | 3841.16 ms | 1218.06 ms | -2623.09 ms |
| 3d31fcf+dirty | 3838.09 ms | 1223.46 ms | -2614.63 ms |
| 9210ae6+dirty | 3815.93 ms | 1214.14 ms | -2601.79 ms |
| 26843eb+dirty | 3861.60 ms | 1238.77 ms | -2622.82 ms |
| 7a89652+dirty | 3861.46 ms | 1229.61 ms | -2631.85 ms |
| 9ad4522+dirty | 3850.40 ms | 1222.40 ms | -2628.00 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| ecf47a2+dirty | 4.98 MiB | 6.46 MiB | 1.49 MiB |
| 3817909+dirty | 3.38 MiB | 4.73 MiB | 1.35 MiB |
| 5ee78d6+dirty | 5.15 MiB | 6.69 MiB | 1.53 MiB |
| 890d145+dirty | 3.38 MiB | 4.77 MiB | 1.38 MiB |
| e763471+dirty | 4.98 MiB | 6.51 MiB | 1.53 MiB |
| 3d31fcf+dirty | 4.98 MiB | 6.56 MiB | 1.58 MiB |
| 9210ae6+dirty | 5.15 MiB | 6.68 MiB | 1.53 MiB |
| 26843eb+dirty | 4.98 MiB | 6.53 MiB | 1.55 MiB |
| 7a89652+dirty | 5.15 MiB | 6.70 MiB | 1.55 MiB |
| 9ad4522+dirty | 4.98 MiB | 6.56 MiB | 1.58 MiB |
Previous results on branch: chore/js-11-beta-0-compat
Startup times
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| b19757e+dirty | 3863.06 ms | 1235.43 ms | -2627.64 ms |
| 6576cfd+dirty | 3851.04 ms | 1231.85 ms | -2619.19 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| b19757e+dirty | 5.15 MiB | 6.87 MiB | 1.72 MiB |
| 6576cfd+dirty | 5.15 MiB | 6.87 MiB | 1.72 MiB |
iOS (new) Performance metrics 🚀
|
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| 71abba0+dirty | 3852.70 ms | 1224.53 ms | -2628.16 ms |
| bc0d8cf+dirty | 3834.64 ms | 1223.91 ms | -2610.73 ms |
| 68ae91b+dirty | 3836.36 ms | 1222.04 ms | -2614.32 ms |
| 267d3ed+dirty | 3860.14 ms | 1223.39 ms | -2636.76 ms |
| f170ec3+dirty | 3844.74 ms | 1222.67 ms | -2622.07 ms |
| b9bebee+dirty | 3858.02 ms | 1231.92 ms | -2626.11 ms |
| d038a14+dirty | 3831.11 ms | 1216.30 ms | -2614.81 ms |
| 853723c+dirty | 3849.33 ms | 1221.07 ms | -2628.26 ms |
| e763471+dirty | 3826.10 ms | 1221.52 ms | -2604.58 ms |
| 3d31fcf+dirty | 3857.46 ms | 1237.17 ms | -2620.29 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| 71abba0+dirty | 5.15 MiB | 6.67 MiB | 1.52 MiB |
| bc0d8cf+dirty | 5.15 MiB | 6.67 MiB | 1.51 MiB |
| 68ae91b+dirty | 4.98 MiB | 6.46 MiB | 1.48 MiB |
| 267d3ed+dirty | 5.15 MiB | 6.69 MiB | 1.54 MiB |
| f170ec3+dirty | 5.15 MiB | 6.69 MiB | 1.53 MiB |
| b9bebee+dirty | 5.15 MiB | 6.68 MiB | 1.53 MiB |
| d038a14+dirty | 5.15 MiB | 6.67 MiB | 1.51 MiB |
| 853723c+dirty | 5.15 MiB | 6.69 MiB | 1.53 MiB |
| e763471+dirty | 4.98 MiB | 6.51 MiB | 1.53 MiB |
| 3d31fcf+dirty | 4.98 MiB | 6.56 MiB | 1.58 MiB |
Previous results on branch: chore/js-11-beta-0-compat
Startup times
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| b19757e+dirty | 3853.54 ms | 1240.77 ms | -2612.77 ms |
| 6576cfd+dirty | 3860.96 ms | 1236.00 ms | -2624.96 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| b19757e+dirty | 5.15 MiB | 6.87 MiB | 1.72 MiB |
| 6576cfd+dirty | 5.15 MiB | 6.87 MiB | 1.72 MiB |
Android (new) Performance metrics 🚀
|
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| 5a010b7+dirty | 475.15 ms | 519.02 ms | 43.88 ms |
| f9c1ed4+dirty | 520.57 ms | 594.84 ms | 74.27 ms |
| c2e182c+dirty | 468.50 ms | 545.44 ms | 76.94 ms |
| 2c735cc+dirty | 435.20 ms | 459.48 ms | 24.28 ms |
| af33f3b+dirty | 417.68 ms | 448.04 ms | 30.37 ms |
| 7d8c8bd+dirty | 406.06 ms | 460.88 ms | 54.81 ms |
| 890d145+dirty | 486.42 ms | 514.85 ms | 28.43 ms |
| ef27341+dirty | 519.02 ms | 553.42 ms | 34.40 ms |
| bf168a4+dirty | 430.60 ms | 459.31 ms | 28.71 ms |
| 41d6254+dirty | 406.20 ms | 445.52 ms | 39.32 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| 5a010b7+dirty | 48.30 MiB | 53.58 MiB | 5.28 MiB |
| f9c1ed4+dirty | 49.74 MiB | 54.86 MiB | 5.12 MiB |
| c2e182c+dirty | 49.74 MiB | 54.85 MiB | 5.11 MiB |
| 2c735cc+dirty | 43.94 MiB | 48.94 MiB | 5.00 MiB |
| af33f3b+dirty | 49.74 MiB | 55.09 MiB | 5.35 MiB |
| 7d8c8bd+dirty | 48.30 MiB | 53.54 MiB | 5.23 MiB |
| 890d145+dirty | 43.94 MiB | 49.00 MiB | 5.06 MiB |
| ef27341+dirty | 48.30 MiB | 53.54 MiB | 5.24 MiB |
| bf168a4+dirty | 49.74 MiB | 55.09 MiB | 5.35 MiB |
| 41d6254+dirty | 48.30 MiB | 53.60 MiB | 5.30 MiB |
Previous results on branch: chore/js-11-beta-0-compat
Startup times
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| b19757e+dirty | 460.30 ms | 497.48 ms | 37.18 ms |
| 6576cfd+dirty | 447.00 ms | 481.54 ms | 34.54 ms |
App size
| Revision | Plain | With Sentry | Diff |
|---|---|---|---|
| b19757e+dirty | 50.56 MiB | 56.45 MiB | 5.89 MiB |
| 6576cfd+dirty | 50.56 MiB | 56.45 MiB | 5.89 MiB |
| @@ -24,10 +20,8 @@ import { captureFeedback } from '@sentry/core'; | |||
| import { captureMessage } from '@sentry/core'; | |||
| import { Client } from '@sentry/core'; | |||
| import type { ClientOptions } from '@sentry/core'; | |||
| import { CompiledGraph } from '@sentry/core'; | |||
| import { consoleLoggingIntegration } from '@sentry/browser'; | |||
| import { consoleSandbox } from '@sentry/core'; | |||
| import { createLangChainCallbackHandler } from '@sentry/core'; | |||
| import { createReduxEnhancer } from '@sentry/react'; | |||
| import { dedupeIntegration } from '@sentry/react'; | |||
| import type { Envelope } from '@sentry/core'; | |||
| @@ -47,33 +41,17 @@ import { getCurrentScope } from '@sentry/core'; | |||
| import { getGlobalScope } from '@sentry/core'; | |||
| import { getIsolationScope } from '@sentry/core'; | |||
| import { getRootSpan } from '@sentry/core'; | |||
| import { GoogleGenAIChat } from '@sentry/core'; | |||
| import { GoogleGenAIClient } from '@sentry/core'; | |||
| import { GoogleGenAIOptions } from '@sentry/core'; | |||
| import type { HostComponent } from 'react-native'; | |||
| import { httpClientIntegration } from '@sentry/react'; | |||
| import { httpContextIntegration } from '@sentry/react'; | |||
| import type { ImageStyle } from 'react-native'; | |||
| import { inboundFiltersIntegration } from '@sentry/react'; | |||
| import { instrumentAnthropicAiClient } from '@sentry/core'; | |||
| import { InstrumentedMethod } from '@sentry/core'; | |||
| import { instrumentGoogleGenAIClient } from '@sentry/core'; | |||
| import { instrumentLangGraph } from '@sentry/core'; | |||
| import { instrumentOpenAiClient } from '@sentry/core'; | |||
| import { instrumentStateGraph } from '@sentry/core'; | |||
| import { instrumentStateGraphCompile } from '@sentry/core'; | |||
| import { eventFiltersIntegration as inboundFiltersIntegration } from '@sentry/react'; | |||
| import { Integration } from '@sentry/core'; | |||
| import { LangChainIntegration } from '@sentry/core'; | |||
| import { LangChainOptions } from '@sentry/core'; | |||
| import { LangGraphIntegration } from '@sentry/core'; | |||
| import { LangGraphOptions } from '@sentry/core'; | |||
| import { lastEventId } from '@sentry/core'; | |||
| import { logger } from '@sentry/browser'; | |||
| import type { makeFetchTransport } from '@sentry/browser'; | |||
| import { Metric } from '@sentry/core'; | |||
| import { metrics } from '@sentry/browser'; | |||
| import { OpenAiClient } from '@sentry/core'; | |||
| import { OpenAiOptions } from '@sentry/core'; | |||
| import type { Options } from '@sentry/core'; | |||
| import { Profiler } from '@sentry/react'; | |||
| import * as React_2 from 'react'; | |||
There was a problem hiding this comment.
Removing AI instrumentation exports breaks the existing React Native API and test suite
@sentry/react-native previously re-exported the AI manual-instrumentation helpers, but packages/core/src/js/index.ts now removes them because JavaScript SDK v11 moved them to the server-only @sentry/server-utils package. Since React Native does not depend on that package, existing applications lose both the TypeScript and runtime exports while the package version remains 8.24.0. The existing aiExports.test.ts also still asserts these exports and will fail. Preserve a supported React Native-compatible export, or update the test and document the breaking migration before shipping the dependency bump.
Evidence
packages/core/src/js/index.tsno longer re-exports the OpenAI, Anthropic, Google GenAI, LangChain, or LangGraph helpers and explicitly states that React Native does not depend on@sentry/server-utils.packages/core/test/aiExports.test.tsimports the package entry point and expects all seven removed helpers to be functions, so the configured Jest suite will fail.packages/core/package.jsonstill declares version8.24.0, making the removal a breaking change in the React Native package rather than an announced major release.- Consumers importing these helpers from
@sentry/react-nativehave no supported in-package migration because the suggested server-only package is not a React Native dependency.
Also found at 5 additional locations
packages/core/etc/sentry-react-native.api.md:106-109packages/core/etc/sentry-react-native.api.md:490-495packages/core/etc/sentry-react-native.api.md:149-161packages/core/etc/sentry-react-native.api.md:399-418packages/core/package.json:76-81
Identified by Warden · code-review · W4Y-3U8
There was a problem hiding this comment.
Intentional for this spike — this PR is a DO NOT MERGE compatibility probe for @sentry/* v11.0.0-beta.0, not a shipping change, so the package version deliberately stays on the 8.x line. Three clarifications on th
e finding:
- Test suite is green.
aiExports.test.tswas removed in this branch (7c61999d) together with the export removal, so the Jest suite passes — the "the configured Jest suite will fail" part is stale against the cur
rent tip. - The removal is documented as breaking. It is listed in the PR's "Breaking changes for Sentry React Native SDK users" table: the AI helpers (
instrumentOpenAiClient,instrumentAnthropicAiClient,instrumentGoogl eGenAIClient, LangChain/LangGraph, …) moved upstream to the server-only@sentry/server-utilsin v11. These are Node/server helpers with little RN applicability, which is why RN does not take that dependency. - The user-facing migration lands with the v11 bump (RN-586). That major release is what will announce this — and the other v11 breaking changes catalogued in this PR — to users; this branch only validates the surfa
ce ahead of it.
Production fixes: - clearActiveSpanFromScope: v11 stores the active span in a WeakRef under scope.refs.span, not the removed scope._sentrySpan property. Deleting the old field was a no-op, leaving the previous navigation/interaction span active so it became the parent of the next root span. Clear via the official _INTERNAL_setSpanForScope helper instead. - sdk.tsx: pin traceLifecycle: 'static' so mobile keeps the classic transaction-envelope behavior instead of v11's new streaming default. Test updates for v11 behavior changes: - spanToJSON -> spanToStaticSpanJSON where the classic span shape is asserted. - startIdleSpan now imported from @sentry/core/browser (entry-point split). - Scope.clear() removed -> resetScope helper mirrors the old reset. - Non-canonical status messages normalize to 'internal_error'. - Child spans no longer carry a default sentry.source: 'custom'. - app.start snapshot: sentry.segment.name.source key and status 'ok'. - Drop obsolete enableMetrics suppression test and aiExports test. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@sentry/core v11.0.0-beta.0 drops its down-levelled TS 3.8 types (no `build/types-ts3.8`, `typesVersions` removed), raising the floor to TypeScript 5.0.4. The old "Type Check Typescript 3.8" guard failed with parse errors it can't skip (skipLibCheck only skips type-checking, not parsing) when TS 3.8 hits v11's modern `.d.ts` syntax. Retarget the guard to TypeScript 5.0.4 (the new minimum): rename the ts3.8-test project to ts5.0-test and bump its TypeScript devDependency. Verified locally that @sentry/react-native -> @sentry/core@11.0.0-beta.0 type-checks cleanly under 5.0.4. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…me.source JS v11 removed the `sentry.source` semantic attribute; the transaction name source now lives under `sentry.segment.name.source` on the segment span. The navigation transaction's serialized `contexts.trace.data` therefore carries the new key (matching the app-start unit snapshot already updated in this branch). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…mpat # Conflicts: # dev-packages/e2e-tests/package.json # samples/expo/package.json # samples/react-native-macos/package.json # samples/react-native/package.json # yarn.lock
… v11 JS v11's `spanToJSON` returns the streamed span shape, which no longer carries the classic `.data` attribute bag. The TurboModule Playground screen read `spanToJSON(span).data`, so under v11 it collected no `turbo_module.*` attributes and rendered nothing — failing the `turboModuleSpanAttributes` e2e flow on both iOS and Android at the on-screen `scrollUntilVisible` step. Switch to `spanToStaticSpanJSON`, the classic-shape helper the SDK already uses internally. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
| @@ -11,7 +11,7 @@ | |||
| "devDependencies": { | |||
| "@types/react": "17.0.83", | |||
| "@types/react-native": "0.65.30", | |||
| "typescript": "3.8.3" | |||
| "typescript": "5.0.4" | |||
| }, | |||
| "dependencies": { | |||
| "@sentry/expo-upload-sourcemaps": "file:.yalc/@sentry/expo-upload-sourcemaps", | |||
There was a problem hiding this comment.
TS type-check no longer validates published ts3.8 types
This suite now type-checks only with TypeScript 5.0.4, so it no longer exercises the still-published typesVersions/ts3.8 downlevel path for TS < 4.9; keep a TS < 4.9 check or drop that support path together.
Evidence
- Hunk renames the package to
sentry-react-native-ts-5-0-testand pinstypescriptto5.0.4(was3.8.3). dev-packages/type-check/run-type-check.shonly entersts5.0-testand runsyarn type-checkthere.packages/core/package.jsonstill shipstypesVersions["<4.9"] -> ts3.8/*and adownlevel-dts ... --to=3.8build.- With TS 5.0.4, resolution uses main
disttypings, so the downleveledts3.8types are never compiled in CI.
Identified by Warden · code-review · 8CF-9M7
📢 Type of change
📜 Description
Bumps
@sentry/*from11.0.0-alpha.2to11.0.0-beta.0acrosspackages/core, the samples anddev-packages/e2e-tests, and adapts the SDK to compile, pass its full test suite, and preserve v8 runtime behavior for end users.The suite is fully green (
1913SDK +340tools tests) and build, lint, format, circular-dep and API report all pass.Source changes (runtime)
tracing/span.ts— real bug fix. v11 no longer stores the active span on ascope._sentrySpanproperty; it keeps aWeakRefunderscope.refs.span. RN'sclearActiveSpanFromScopewas deleting the old (now non-existent) field, so the previous navigation/interaction span was never detached and became the parent of the next root span — corrupting the trace hierarchy for every navigation and UI-interaction transaction. Now clears via the official_INTERNAL_setSpanForScopehelper. This is a latent bug that would ship broken under v11 regardless of the pre-release testing, and the internal field move is not documented in the migration guide.sdk.tsx—traceLifecycle: 'static'pin. v11 defaults span handling to'stream'. Mobile opts into'static'so transactions keep being sent as transaction envelopes (the classic v8 shape the native SDKs ingest), rather than streamed spans. This keeps end-user behavior unchanged.tracing/span.ts/replay/xhrUtils.ts— entry-point split. New in beta.0: the@sentry/coremain entry was split into shared / browser / server subpaths.startIdleSpanand theXhrBreadcrumbHinttype moved to@sentry/core/browser. Core ships root-level shim stubs (browser.d.ts/browser.js) so RN's classicmoduleResolution: nodestill resolves the subpath; jest resolves it viaRNTestEnvironment.js. Not in the beta.0 migration guide.When the SDK bundles
@sentry/* v11, the following are user-visible breaking changes. Anything RN could absorb has been absorbed (see the last sub-list) so this set is the residue users still need to know about.Confirmed breaking:
Scope.clear()removedScopeis re-exported from@sentry/react-native;getCurrentScope().clear()(or.clear()on any scope) no longer exists.withScope/withIsolationScope, or re-init the SDK.spanToJSON()shape changed@sentry/react-native. Now returns the streamed shape (name,attributes,status: 'ok' | 'error',end_timestamp,is_segment, …) instead of the classicdescription/op/data/timestamp/origin/measurements. Code reading classic fields (e.g. inbeforeSendTransaction) breaks.event.spansdirectly, or the classic-shape helper (RN re-exportingspanToStaticSpanJSONis a follow-up — see Next steps).span.setStatus({ code: SPAN_STATUS_ERROR, message: 'my text' })— only canonical status strings survive; any non-canonical message now surfaces asinternal_error, so custom status text is lost.InboundFilters→EventFiltersinboundFiltersIntegrationstill works (aliased), but the integration'snameis now"EventFilters". Looking up / removing the integration by the string"InboundFilters"breaks."EventFilters".instrumentOpenAiClient,instrumentAnthropicAiClient,instrumentGoogleGenAIClient,createLangChainCallbackHandler, the LangGraph helpers, etc. are no longer re-exported from@sentry/react-native(moved to the server-only@sentry/server-utils, which RN does not depend on).@sentry/typesno longer published@sentry/core. Direct imports from@sentry/typesbreak.@sentry/react-native(or@sentry/core).any→unknown)In progress — will be handled before the bump (tracked, not decided in this spike):
sendDefaultPii→dataCollection. Dedicated Linear project; theinfer_ipPII gap is scoped to logs + metrics envelopes only (events / sessions / spans are already safe). Intent is for users to keep working without a forced rename.@sentry/corev11 no longer ships TS 3.8 types — it droppedbuild/types-ts3.8and itstypesVersionsmapping — so TS 3.8 falls back to the modern.d.tsand fails to parse them (skipLibCheckcan't help: it skips type-checking, not parsing). This raises the floor to TS 5.0.4. Done in this branch: the CI type-compat guard was retargeted from TS 3.8 to 5.0.4 (ts3.8-test→ts5.0-test); verified@sentry/react-native→@sentry/core@11.0.0-beta.0type-checks cleanly under 5.0.4. Still open: RN currently still down-levels and ships its own TS 3.8 types; whether to drop that (and formally raise the documented minimum) is the remaining decision. Tracked as RN-754 / Raise minimum TypeScript to 5.0.4 and drop TS 3.8 support (v9) #6657.Explicitly NOT breaking for RN users (RN preserves v8 behavior):
traceLifecycle: 'static'; transactions still send as envelopes.enableLogs— RN re-declares the option.attachStacktracedefault — RN already defaults it totrue.enableMetricsremoval — was never a public RN option, so nothing to migrate.💡 Motivation and Context
Continuous validation of the JS v11 pre-releases ahead of the RN major (RN-586). Confirms whether each pre-release introduces new breakages, catalogues the user-facing breaking surface, and re-verifies the known gaps still need covering. The beta.0-specific findings (all now handled in this branch):
scope.refs.spanWeakRefclearActiveSpanFromScope(runtime bug).@sentry/coreentry-point split (browser subpath)startIdleSpan/XhrBreadcrumbHintimports moved to@sentry/core/browser.@sentry/server-utilstraceLifecycle: 'static'.spanToJSONshape changedspanToStaticSpanJSONinternally; RN sample's TurboModule screen switched tospanToStaticSpanJSON(see e2e note below); user-facing re-export flagged.internal_errorsentry.source: 'custom'Scope.clear()removedresetScopetest helper.InboundFilters→EventFiltersrenameeventFiltersIntegrationaliased asinboundFiltersIntegration.ts3.8-test→ts5.0-test).💚 How did you test it?
yarn build— clean.yarn lint, format,yarn circularDepCheck— pass.yarn api-report:check— passes.TS-compat guard — retargeted from TypeScript 3.8 to 5.0.4 (v11's new floor) and verified locally:
@sentry/react-native→@sentry/core@11.0.0-beta.0type-checks with exit 0.yarn test— all green (1913SDK +340tools + 1). The v11 adaptations:spanToJSON→spanToStaticSpanJSONwhere the classic shape is asserted;startIdleSpanimported from@sentry/core/browser;Scope.clear()→resetScopehelper; non-canonical status assertions →internal_error; child-spansentry.sourcedropped;app.startsnapshot re-locked (sentry.segment.name.source+status: 'ok'); obsoleteenableMetricsand AI-exports tests removed.e2e (REV2, iOS + Android) — the
turboModuleSpanAttributesflow failed identically on both platforms: the RN sample'sTurboModuleScreenrendered the aggregatedturbo_module.*attributes by readingspanToJSON(span).data, which v11 empties (streamed shape has no.data), so the on-screenscrollUntilVisiblefound nothing. Fixed the sample to read viaspanToStaticSpanJSON— the same classic-shape helper the SDK uses internally. (e2e-v2 only re-runs with theready-to-mergelabel, so this isn't auto-verified on push.)📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps
sendDefaultPii→dataCollectionmigration (logs/metrics PII), re-exportingspanToStaticSpanJSONso users keep a classic-shape helper, and the down-levelled-types shipping decision — whether RN stops shipping its own TS 3.8 types and formally raises the documented minimum to 5.0.4 (RN-754). The CI type-compat guard is already retargeted to 5.0.4 in this branch.