Skip to content

chore(core): Bump sample app to React Native 0.84.1#5941

Merged
antonis merged 19 commits intomainfrom
antonis/bump-sample-rn-0.84.1
Apr 2, 2026
Merged

chore(core): Bump sample app to React Native 0.84.1#5941
antonis merged 19 commits intomainfrom
antonis/bump-sample-rn-0.84.1

Conversation

@antonis
Copy link
Copy Markdown
Contributor

@antonis antonis commented Mar 31, 2026

📢 Type of change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring

📜 Description

Bumps the React Native sample app from 0.80.2 to 0.84.1 (Hermes V1 by default).

All changes are generic RN 0.84.1 upgrade boilerplate — the Sentry SDK itself required zero code changes for Hermes V1 support. The NEW_HERMES_RUNTIME ifdef was already in place for RN >= 0.81.

Version bumps:

  • react-native 0.80.2 → 0.84.1, react 19.1.0 → 19.2.3
  • react-native-reanimated 3.19.1 → 4.3.0 (+ react-native-worklets 0.8.1) — v3 uses legacy arch APIs removed in RN 0.84
  • react-native-launch-arguments 4.1.0 → 4.1.1 (has Gradle 9 destinationDirectory fix)
  • @react-native/* and @react-native-community/cli devDependencies
  • Android SDK 35 → 36, Gradle 8.14.1 → 9.0.0

Code changes (all sample app):

  • Simplified MainApplication.kt to new getDefaultReactHost(context, packageList) pattern (RN 0.82+ template)
  • Replaced deprecated rncore.hFBReactNativeSpec.h in OnLoad.cpp
  • Removed react-native-build-config dependency (unmaintained, uses jcenter() removed in Gradle 9) — replaced with react-native-launch-arguments for both platforms
  • Set REACT_NATIVE_NODE_MODULES_DIR in Podfile and pod-install script so the SDK podspec detects the app's RN version in the monorepo
  • Changed tsconfig.json extends to bare specifier (@react-native/typescript-config) for Node 22 exports field compatibility
  • Added proguard -dontwarn for NotThreadSafeBridgeIdleDebugListener — Detox references this bridge class removed in RN 0.84

CI:

  • Bumped Node 18 → 22 in buildandtest.yml (Bundle job) and sample-application.yml — Metro from RN 0.84 requires Node 20+ (Array.toReversed())
  • Removed legacy arch from sample app CI matrix — RN 0.84 and Reanimated 4 require New Architecture
  • Removed dynamic-frameworks iOS variant — has a known RN linker issue with new arch, was already excluded for new arch on main

💡 Motivation and Context

RN 0.84.1 ships Hermes V1 as the default JS engine. This PR confirms that no SDK changes are needed for Hermes V1 support and updates the sample app for local testing.

Verified on Android with Hermes V1:

  • ✅ Error capture (promise rejection tracking via HermesInternal)
  • ✅ Profiling (HermesSamplingProfiler API, profile created and attached to transactions)
  • ✅ Tracing (navigation spans, app start spans)
  • Source map symbolication mechanism is version-agnostic (lineno === 1 + funcVirtAddr + offset formula), but not end-to-end testable in dev builds

Closes #5945
Relates to #5489

💚 How did you test it?

  • Android build compiles successfully (JDK 17 required for Gradle 9)
  • iOS build compiles successfully (after pod install with REACT_NATIVE_NODE_MODULES_DIR)
  • Error capture works with Hermes V1 (verified via device logs)
  • Profiling works with Hermes V1 (verified via device logs)
  • Source map symbolication verified in Sentry UI (needs production build with source map upload)

📝 Checklist

  • I added tests to verify changes
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled
  • I updated the docs if needed.
  • I updated the wizard if needed.
  • All tests passing
  • No breaking changes

🔮 Next steps

antonis and others added 5 commits March 31, 2026 15:40
React Native 0.84.1 ships Hermes V1 as the default JS engine.

Changes:
- react-native 0.80.2 -> 0.84.1, react 19.1.0 -> 19.2.3
- Android SDK 35 -> 36, Gradle 8.14.1 -> 9.0.0
- Simplified MainApplication.kt to use new getDefaultReactHost(context, packageList) pattern
  replacing the legacy DefaultReactNativeHost/ReactNativeHost boilerplate
- Updated @react-native/* and @react-native-community/cli devDependencies

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Gradle 9 removed jcenter() and deprecated lintOptions.
Apply yarn patch to remove the obsolete buildscript block and
replace lintOptions with lint.

Also includes Xcode project changes from RN 0.84 (RCT_REMOVE_LEGACY_ARCH flag).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…lity

Gradle 9 removed the `destinationDir` property from JavaCompile tasks.
Use `destinationDirectory` instead.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Reanimated 3.x uses legacy arch APIs (LayoutAnimationController,
UIManagerModuleListener) that were removed in RN 0.84.
Reanimated 4.x supports RN 0.81-0.85.

Also adds react-native-worklets 0.8.1 as required peer dependency.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
rncore.h is deprecated in RN 0.84 and triggers -Werror.
Replace with FBReactNativeSpec.h and FBReactNativeSpec_ModuleProvider.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@antonis antonis added the ready-to-merge Triggers the full CI test suite label Mar 31, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Mar 31, 2026

Semver Impact of This PR

None (no version bump detected)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


  • chore(core): Bump sample app to React Native 0.84.1 by antonis in #5941
  • chore(deps): bump lodash from 4.17.23 to 4.18.1 by dependabot in #5953
  • chore(deps): bump yauzl to ^3.2.1 by antonis in #5950
  • chore(deps): bump brace-expansion to ^2.0.3 by antonis in #5951
  • chore(deps): bump @xmldom/xmldom to fix XML injection by antonis in #5952

🤖 This preview updates automatically when you update the PR.

@antonis antonis removed the ready-to-merge Triggers the full CI test suite label Mar 31, 2026
antonis and others added 5 commits March 31, 2026 17:10
RN 0.84 requires Node >= 22.11. Metro from RN 0.84 uses
Array.toReversed() which is not available in Node 18.

Bump Node version for the Bundle job in buildandtest.yml and
all jobs in sample-application.yml that run Metro bundling.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…les_dependencies

`s.compiler_flags` was silently overridden by `install_modules_dependencies()`,
so `-DSENTRY_PROFILING_SUPPORTED`, `-DNEW_HERMES_RUNTIME`, and
`-DRCT_NEW_ARCH_ENABLED` were never applied. Add flags to
`pod_target_xcconfig['OTHER_CFLAGS']` which takes effect correctly.

Also set `REACT_NATIVE_NODE_MODULES_DIR` in the sample app's Podfile
and pod-install script so the podspec detects the app's RN version
instead of the SDK's devDependency version in the monorepo.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The compiler flags (SENTRY_PROFILING_SUPPORTED, NEW_HERMES_RUNTIME, etc.)
are already applied per-file via s.compiler_flags, which
install_modules_dependencies preserves. Adding them to pod_target_xcconfig
was redundant.

The actual fix for the iOS build was the REACT_NATIVE_NODE_MODULES_DIR
env var in the Podfile, which ensures the podspec detects the app's
RN version instead of the SDK's devDependency version in the monorepo.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
… removal

- Remove react-native-build-config dependency entirely. It was
  unmaintained (uses jcenter, Gradle 1.3) and only used to read
  one Android BuildConfig field. Use react-native-launch-arguments
  for both platforms instead.
- Bump react-native-launch-arguments to 4.1.1 which has the
  Gradle 9 fix (destinationDirectory) built-in.
- Remove both yarn patch files and resolutions.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@antonis antonis added skip-changelog ready-to-merge Triggers the full CI test suite labels Apr 1, 2026
@antonis antonis force-pushed the antonis/bump-sample-rn-0.84.1 branch from ce0e355 to 64a6352 Compare April 1, 2026 09:54
RN 0.84 and Reanimated 4 require the New Architecture.
Legacy arch builds fail with: "Reanimated requires the New Architecture
to be enabled".

Also remove dynamic-frameworks variant since it was previously excluded
for new arch.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@antonis antonis force-pushed the antonis/bump-sample-rn-0.84.1 branch from 64a6352 to 1f23e0f Compare April 1, 2026 10:05
@antonis antonis mentioned this pull request Apr 1, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 1, 2026

Android (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 404.40 ms 422.20 ms 17.80 ms
Size 43.75 MiB 48.08 MiB 4.33 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
4953e94+dirty 442.02 ms 456.52 ms 14.50 ms
df5d108+dirty 527.06 ms 603.58 ms 76.52 ms
a50b33d+dirty 500.81 ms 532.11 ms 31.30 ms

App size

Revision Plain With Sentry Diff
4953e94+dirty 43.75 MiB 48.08 MiB 4.33 MiB
df5d108+dirty 43.75 MiB 48.08 MiB 4.33 MiB
a50b33d+dirty 43.75 MiB 48.08 MiB 4.33 MiB

Previous results on branch: antonis/bump-sample-rn-0.84.1

Startup times

Revision Plain With Sentry Diff
5a497ec+dirty 405.00 ms 447.78 ms 42.78 ms
8f0c79a+dirty 524.78 ms 584.80 ms 60.02 ms

App size

Revision Plain With Sentry Diff
5a497ec+dirty 43.75 MiB 48.08 MiB 4.33 MiB
8f0c79a+dirty 43.75 MiB 48.08 MiB 4.33 MiB

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 1, 2026

iOS (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1211.41 ms 1214.52 ms 3.11 ms
Size 3.38 MiB 4.73 MiB 1.35 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
df5d108+dirty 1225.90 ms 1220.14 ms -5.76 ms
4953e94+dirty 1212.06 ms 1214.83 ms 2.77 ms
a50b33d+dirty 1197.74 ms 1197.17 ms -0.57 ms

App size

Revision Plain With Sentry Diff
df5d108+dirty 3.38 MiB 4.73 MiB 1.35 MiB
4953e94+dirty 3.38 MiB 4.73 MiB 1.35 MiB
a50b33d+dirty 3.38 MiB 4.73 MiB 1.35 MiB

Previous results on branch: antonis/bump-sample-rn-0.84.1

Startup times

Revision Plain With Sentry Diff
8f0c79a+dirty 1249.71 ms 1243.28 ms -6.43 ms
5a497ec+dirty 1214.81 ms 1221.13 ms 6.32 ms

App size

Revision Plain With Sentry Diff
8f0c79a+dirty 3.38 MiB 4.73 MiB 1.35 MiB
5a497ec+dirty 3.38 MiB 4.73 MiB 1.35 MiB

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 1, 2026

iOS (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 1209.84 ms 1218.19 ms 8.35 ms
Size 3.38 MiB 4.73 MiB 1.35 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
df5d108+dirty 1207.34 ms 1210.50 ms 3.16 ms
4953e94+dirty 1217.41 ms 1223.53 ms 6.12 ms
a50b33d+dirty 1207.11 ms 1212.10 ms 5.00 ms

App size

Revision Plain With Sentry Diff
df5d108+dirty 3.38 MiB 4.73 MiB 1.35 MiB
4953e94+dirty 3.38 MiB 4.73 MiB 1.35 MiB
a50b33d+dirty 3.38 MiB 4.73 MiB 1.35 MiB

Previous results on branch: antonis/bump-sample-rn-0.84.1

Startup times

Revision Plain With Sentry Diff
8f0c79a+dirty 1205.92 ms 1207.51 ms 1.59 ms
5a497ec+dirty 1220.76 ms 1222.10 ms 1.34 ms

App size

Revision Plain With Sentry Diff
8f0c79a+dirty 3.38 MiB 4.73 MiB 1.35 MiB
5a497ec+dirty 3.38 MiB 4.73 MiB 1.35 MiB

- Use bare specifier in tsconfig extends (`@react-native/typescript-config`
  instead of `@react-native/typescript-config/tsconfig.json`). Node 22
  strictly enforces the package's `exports` field, and ts-jest couldn't
  resolve the direct file path.

- Add proguard `-dontwarn` for `NotThreadSafeBridgeIdleDebugListener`
  which Detox references but was removed in RN 0.84.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@antonis antonis force-pushed the antonis/bump-sample-rn-0.84.1 branch from 74e966a to dadeb89 Compare April 1, 2026 10:55
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 1, 2026

Android (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 369.90 ms 400.92 ms 31.02 ms
Size 43.94 MiB 48.94 MiB 5.00 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
4953e94+dirty 398.80 ms 431.81 ms 33.01 ms
df5d108+dirty 434.82 ms 447.39 ms 12.57 ms
a50b33d+dirty 353.21 ms 398.48 ms 45.27 ms

App size

Revision Plain With Sentry Diff
4953e94+dirty 43.94 MiB 48.94 MiB 5.00 MiB
df5d108+dirty 43.94 MiB 48.94 MiB 5.00 MiB
a50b33d+dirty 43.94 MiB 48.94 MiB 5.00 MiB

Previous results on branch: antonis/bump-sample-rn-0.84.1

Startup times

Revision Plain With Sentry Diff
5a497ec+dirty 413.94 ms 448.92 ms 34.98 ms
8f0c79a+dirty 418.86 ms 452.12 ms 33.27 ms

App size

Revision Plain With Sentry Diff
5a497ec+dirty 43.94 MiB 48.94 MiB 5.00 MiB
8f0c79a+dirty 43.94 MiB 48.94 MiB 5.00 MiB

@antonis antonis marked this pull request as ready for review April 1, 2026 11:59
@antonis antonis requested a review from alwx as a code owner April 1, 2026 11:59
@antonis antonis requested a review from lucas-zimerman as a code owner April 1, 2026 11:59
@antonis antonis marked this pull request as draft April 1, 2026 12:39
Copy link
Copy Markdown
Contributor Author

@antonis antonis left a comment

Choose a reason for hiding this comment

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

Converting back to draft to fix the bot review issues

antonis and others added 2 commits April 1, 2026 14:50
- Re-add react-native-build-config with yarn patch for Gradle 9 compat.
  The Android BuildConfig.SENTRY_DISABLE_NATIVE_START is a build-time
  flag that can't be replaced by runtime launch arguments.
- Restore original platform-specific shouldUseAutoStart() logic.
- Update engines.node to >=22.11.0 and volta node to 22.22.2
  to match RN 0.84 requirements.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@antonis
Copy link
Copy Markdown
Contributor Author

antonis commented Apr 1, 2026

@sentry review

@antonis
Copy link
Copy Markdown
Contributor Author

antonis commented Apr 1, 2026

@cursor review

Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

@antonis antonis marked this pull request as ready for review April 1, 2026 13:45
Copy link
Copy Markdown
Collaborator

@lucas-zimerman lucas-zimerman left a comment

Choose a reason for hiding this comment

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

LGTM!

@antonis antonis removed the ready-to-merge Triggers the full CI test suite label Apr 2, 2026
@antonis antonis added the ready-to-merge Triggers the full CI test suite label Apr 2, 2026
@antonis antonis merged commit ad68d6c into main Apr 2, 2026
108 of 114 checks passed
@antonis antonis deleted the antonis/bump-sample-rn-0.84.1 branch April 2, 2026 13:13
antonis added a commit that referenced this pull request Apr 2, 2026
RN 0.84 ships metro-config 0.82.2 which uses Array.toReversed(),
requiring Node 20+. These two workflows build the sample app but
were missed in the RN 0.84.1 bump PR (#5941).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
antonis added a commit that referenced this pull request Apr 2, 2026
…5954)

RN 0.84 ships metro-config 0.82.2 which uses Array.toReversed(),
requiring Node 20+. These two workflows build the sample app but
were missed in the RN 0.84.1 bump PR (#5941).

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge Triggers the full CI test suite skip-changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bump sample app to React Native 0.84

2 participants