Repository navigation
feat: show a build id in Settings → About on the Web Client and the mobile app - #1923
Conversation
Metro inlines the bundling commit and branch as EXPO_PUBLIC_BUILD_*, so a test build can be told apart on the phone. Tapping the row copies it. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 25 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
Ported from claude/project-thread-6adldg so web and mobile ship in one PR. Mobile now also shows the build time next to the commit. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Batch QA — head 555fe34 on
|
| Check | Result |
|---|---|
Web Client (QA Host rebuilt + restarted on the batch): Settings → About → 构建 / Build shows 6b11c934a · 2026-10-16 03:33 (light + dark) |
✅ pass |
iOS Simulator "PR1800 glass" (iOS 26.0), Metro on the batch: Settings → About → Version shows 0.0.1 · 6b11c934a · 2026-10-16 03:36 · qa/batch-4 (light + dark) |
✅ pass |
| Tap Version → "Copied", clipboard holds the full string | ✅ pass |
-dirty suffix |
✅ appears when the worktree has uncommitted tracked edits (seen as 6b11c934a-dirty before I cleaned the worktree), absent on a clean tree |
| Release build stamp | by reading: Xcode's "Bundle React Native code and images" phase runs Metro from apps/mobile, where metro.config.js runs git and sets EXPO_PUBLIC_BUILD_*; the production Metro cache is keyed on the commit (ed0b279). To be confirmed on the next iPhone Release build. |
| Android | untested |
Checks on the batch: root + mobile typecheck clean; mobile + client vitest 277 files / 2135 tests passed. pnpm lint passes except for local-only noise in the QA worktree (an untracked stray ADR file and untracked promo/ images that aren't part of the batch).





Requested by Vain · project thread
Why the change
During testing nobody could tell which build was installed on the phone or served by the Web Client. Both now show a build id (short git SHA + local build time) in Settings → About / 测试时看不出手机和网页端是哪一版,现在两端「设置 → 关于」都显示构建号。
Supersedes #1922: its Web Client half is ported here unchanged; the mobile half uses Metro instead of
app.config.ts(see below).Special things to note
tsdown.config.tsbuildStamp()stamps__BOTHARNESS_BUILD__(git rev-parse --short=9 HEAD+ build time,BOTHARNESS_BUILD_SHA/BOTHARNESS_BUILD_TIMEoverride) into the client bundle only; About gets a Build row, e.g.555fe34f0 · 2026-10-15 18:26.metro.config.jssetsEXPO_PUBLIC_BUILD_COMMIT(9-char SHA,-dirtyif tracked files had changes;BOTHARNESS_BUILD_SHAorEAS_BUILD_GIT_COMMIT_HASHwhen there is no git),EXPO_PUBLIC_BUILD_TIMEandEXPO_PUBLIC_BUILD_BRANCHwhen Metro starts, unless already set. About → Version shows0.0.1 · f63284a94 · 2026-10-15 18:27 · <branch>; tapping copies it.app.config.tsextra.build(Show a build id in Settings on the Web Client and the mobile app #1922):@expo/fingerprinthashesexpoConfig.extraby default, so a per-run SHA/time there changes the native fingerprint every run andscripts/e2e-mobile-sim.mjswould rebuild the native app each time.EXPO_PUBLIC_*into Metro's transform cache, so withNODE_ENV=productionthe stamp also goes intoconfig.cacheVersion(a second localexpo exportotherwise kept the old commit). Dev reads them at serialize time and keeps its cache.pnpm lint,pnpm typecheck(root + mobile),pnpm vitest run apps/mobileandpackages/client/test/build-id.test.tspass.pnpm build:packages/client/lib/client.jscarries{ sha: "555fe34f0", time: "2026-10-15T18:26:26Z" }.Change outline
Mobile Settings: 390 × 844, unpaired web render
Before: no version anywhere.
After: About → Version shows version, commit, build time and branch.
Web Client Settings → About
Screenshots follow in a comment from the QA Host run.
🤖 Generated with Claude Code
https://claude.ai/code/session_01RESQX8EVBt9d4fGKdV4ips