feat(client): show app + server version at the bottom of settings #290
No reviewers
Labels
No labels
area:auth
area:ci
area:db
area:infra
area:native
area:pwa
area:service
epic
feature
foundation
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
james/carol!290
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "289-settings-version-display"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Embeds the build version and surfaces it at the bottom of the account/settings screen, and fixes the release pipeline so the version actually updates per release.
Display (
apps/client/app/(app)/account.tsx)A new
VersionFooterafter<TokensCard />:Carol <version>— from the bundle'sexpo.versionviaexpo-constants. No network call.App <version>(expo-constants) andServer <version>(fromGET /api/healthvia a newuseServerVersionhook in@carol/api-client). ShowsChecking…while loading andUnknownon failure.The underlying defect
The version was a static
0.0.0everywhere —app.jsonexpo.version, rootpackage.json,apps/api/package.json— and the release workflows parsed the git tag but never wrote it before building. So/api/healthalways reported0.0.0and the AndroidversionName/versionCodenever updated per release.Both release workflows now stamp the tag version before building:
release.yml→ writes the tag version intoapps/api/package.json(+ root) beforedocker build, so/api/healthreports the real version.release-android.yml→ writesexpo.version+ a monotonicexpo.android.versionCode(MAJOR*1000000 + MINOR*1000 + PATCH, pre-release suffix stripped) intoapp.jsonbeforeexpo prebuild, so the APK/AAB carry the realversionName/versionCode.package.json/app.jsonstay at the0.0.0dev placeholder — CI is the only writer.build-android.shnotes this for local builders.Notes / decisions
/api/healthisn't in the generated OpenAPI surface (no zod schema), souseServerVersioncalls it through the typed client with a narrow cast rather than hand-authoring the route into the spec / drift baseline.versionCodeformula assumes minor/patch < 1000 (documented in-workflow).account.version.*(en only; siblings fall back per-key).Verification
@carol/api-clienttypecheck ✓ · vitest 26/26 ✓@carol/clienttypecheck ✓ · eslint ✓@carol/api openapi:check— spec up to date ✓actionlinton both edited workflows — clean ✓Closes #289
🤖 Generated with Claude Code
📊 Test coverage
Patch coverage: no testable lines changed.
Overall (
app/,lib/,db/, excluding UI per ADR-0019):Soft thresholds per ADR-0019. Coverage is informational and does not block merge.