Skip to content

fix(profiling): Populate Hermes runtime version on JS profiles - #6817

Merged
antonis merged 1 commit into
mainfrom
fix/profiling-hermes-version
Oct 1, 2026
Merged

antonis merged 1 commit into
mainfrom
fix/profiling-hermes-version

Conversation

@antonis

@antonis antonis commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

📢 Type of change

  • Bugfix
  • New feature
  • Enhancement
  • Refactoring

📜 Description

Hermes JS profiles have always been sent with an empty runtime.version placeholder (version: '', // TODO: get hermes version). This wires that field up to the existing getHermesVersion() helper, so profiles now carry the real Hermes version that OSS Hermes reports (e.g. for RN 0.76.0).

When Hermes doesn't report a version, we fall back to '' — identical to today's behavior — so there is no regression.

💡 Motivation and Context

The TODO dates back to the original experimental Hermes profiling PR (#3057, 2023). The getHermesVersion() helper already existed at that time (#3050) and is the same source already used to populate react_native_context.hermes_version; it was simply never wired into the profiling payload. This fills a field that has been shipping empty ever since, so the Hermes runtime version now shows up on profiles in Sentry.

No related issue existed; found during a repo-wide TODO cleanup pass.

💚 How did you test it?

Added unit tests in test/profiling/utils.test.ts covering both the populated case (for RN 0.76.0) and the fallback-to-empty case. yarn lint and yarn test for the profiling suite pass.

📝 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.
  • Public API changes reviewed by another Mobile SDK team member or implemented according to the develop docs spec.
  • No breaking changes.

🔮 Next steps

🤖 Generated with Claude Code

The Hermes JS profile payload has always sent an empty `runtime.version`
placeholder. Wire it up to the existing `getHermesVersion()` helper so
profiles carry the real Hermes version (falling back to `''` when Hermes
does not report one, matching the previous behavior).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

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).


  • fix(profiling): Populate Hermes runtime version on JS profiles by antonis in #6817

🤖 This preview updates automatically when you update the PR.

@antonis antonis added the ready-to-merge Triggers the full CI test suite label Oct 1, 2026
@sentry

sentry Bot commented Oct 1, 2026

Copy link
Copy Markdown

📲 Install Builds

Android

🔗 App Name App ID Version Configuration
Sentry RN io.sentry.reactnative.sample 8.29.0 (109) Release

⚙️ sentry-react-native Build Distribution Settings

@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.

✅ Bugbot reviewed your changes and found no new issues!

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

Reviewed by Cursor Bugbot for commit 0d2bc41. Configure here.

@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Android (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 417.65 ms 433.64 ms 15.99 ms
Size 50.56 MiB 56.59 MiB 6.03 MiB

@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

iOS (legacy) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 3862.57 ms 1229.00 ms -2633.57 ms
Size 5.15 MiB 6.94 MiB 1.79 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
64630e5+dirty 3842.70 ms 1218.11 ms -2624.60 ms
b0d3373+dirty 3831.75 ms 1227.29 ms -2604.46 ms
b04af96+dirty 3818.92 ms 1219.76 ms -2599.16 ms
3d31fcf+dirty 3838.09 ms 1223.46 ms -2614.63 ms
a0a3177+dirty 3844.73 ms 1225.23 ms -2619.51 ms
af33f3b+dirty 3849.98 ms 1236.45 ms -2613.53 ms
09a902f+dirty 3835.67 ms 1217.11 ms -2618.57 ms
5a316ea+dirty 3820.11 ms 1211.28 ms -2608.83 ms
acd838e+dirty 3849.78 ms 1230.00 ms -2619.78 ms
c2e182c+dirty 3848.40 ms 1211.79 ms -2636.61 ms

App size

Revision Plain With Sentry Diff
64630e5+dirty 4.98 MiB 6.46 MiB 1.49 MiB
b0d3373+dirty 5.15 MiB 6.68 MiB 1.53 MiB
b04af96+dirty 4.98 MiB 6.54 MiB 1.56 MiB
3d31fcf+dirty 4.98 MiB 6.56 MiB 1.58 MiB
a0a3177+dirty 4.98 MiB 6.55 MiB 1.58 MiB
af33f3b+dirty 4.98 MiB 6.51 MiB 1.54 MiB
09a902f+dirty 4.98 MiB 6.46 MiB 1.49 MiB
5a316ea+dirty 4.98 MiB 6.51 MiB 1.53 MiB
acd838e+dirty 5.15 MiB 6.70 MiB 1.55 MiB
c2e182c+dirty 4.98 MiB 6.50 MiB 1.52 MiB

@antonis
antonis marked this pull request as ready for review October 1, 2026 12:43
@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Android (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 426.30 ms 431.78 ms 5.48 ms
Size 50.56 MiB 56.59 MiB 6.03 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
bf168a4+dirty 430.60 ms 459.31 ms 28.71 ms
0bd8916+dirty 400.15 ms 442.72 ms 42.57 ms
a2585ce+dirty 414.04 ms 456.83 ms 42.79 ms
9c84b9a+dirty 429.26 ms 448.90 ms 19.64 ms
bc0d8cf+dirty 407.66 ms 461.35 ms 53.69 ms
a736b76+dirty 405.78 ms 458.74 ms 52.96 ms
1122a96+dirty 510.16 ms 542.00 ms 31.84 ms
267d3ed+dirty 424.69 ms 483.70 ms 59.01 ms
6177334+dirty 404.80 ms 456.74 ms 51.94 ms
7887847+dirty 420.47 ms 460.55 ms 40.08 ms

App size

Revision Plain With Sentry Diff
bf168a4+dirty 49.74 MiB 55.09 MiB 5.35 MiB
0bd8916+dirty 48.30 MiB 53.57 MiB 5.26 MiB
a2585ce+dirty 49.74 MiB 55.36 MiB 5.61 MiB
9c84b9a+dirty 49.74 MiB 55.36 MiB 5.62 MiB
bc0d8cf+dirty 48.30 MiB 53.48 MiB 5.18 MiB
a736b76+dirty 48.30 MiB 53.48 MiB 5.18 MiB
1122a96+dirty 48.30 MiB 53.54 MiB 5.24 MiB
267d3ed+dirty 48.30 MiB 53.58 MiB 5.28 MiB
6177334+dirty 48.30 MiB 53.54 MiB 5.23 MiB
7887847+dirty 49.74 MiB 54.81 MiB 5.07 MiB

@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

iOS (new) Performance metrics 🚀

  Plain With Sentry Diff
Startup time 3854.00 ms 1229.30 ms -2624.70 ms
Size 5.15 MiB 6.94 MiB 1.79 MiB

Baseline results on branch: main

Startup times

Revision Plain With Sentry Diff
6176a94+dirty 3854.15 ms 1221.77 ms -2632.38 ms
a636fa4+dirty 3846.16 ms 1210.10 ms -2636.05 ms
4966363+dirty 3863.07 ms 1227.19 ms -2635.88 ms
68672fc+dirty 3832.22 ms 1228.29 ms -2603.93 ms
6acdf1d+dirty 3835.35 ms 1218.30 ms -2617.06 ms
2c735cc+dirty 1223.33 ms 1224.38 ms 1.04 ms
d771cd5+dirty 3841.09 ms 1224.64 ms -2616.44 ms
ae37560+dirty 3840.10 ms 1217.89 ms -2622.21 ms
a858ac3+dirty 3850.72 ms 1226.35 ms -2624.37 ms
57e0069+dirty 3842.23 ms 1210.00 ms -2632.23 ms

App size

Revision Plain With Sentry Diff
6176a94+dirty 5.15 MiB 6.68 MiB 1.53 MiB
a636fa4+dirty 4.98 MiB 6.55 MiB 1.57 MiB
4966363+dirty 5.15 MiB 6.68 MiB 1.53 MiB
68672fc+dirty 5.15 MiB 6.71 MiB 1.55 MiB
6acdf1d+dirty 4.98 MiB 6.51 MiB 1.53 MiB
2c735cc+dirty 3.38 MiB 4.74 MiB 1.35 MiB
d771cd5+dirty 4.98 MiB 6.55 MiB 1.57 MiB
ae37560+dirty 5.15 MiB 6.70 MiB 1.54 MiB
a858ac3+dirty 4.98 MiB 6.51 MiB 1.53 MiB
57e0069+dirty 4.98 MiB 6.50 MiB 1.52 MiB

@alwx alwx left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

looks good!

@antonis
antonis merged commit 7b7b4fa into main Oct 1, 2026
131 of 137 checks passed
@antonis
antonis deleted the fix/profiling-hermes-version branch October 1, 2026 12:58
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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants