Clicking "Update server" on a relay-connected server showed a spinner, then a disconnected banner with a raw transport error, then hung until the page was refreshed. Three separate causes: 1. The boot-service (systemd) update path ran `systemctl --user restart` synchronously inside the RPC handler, so the process died before the acknowledgement flushed. Every successful update reached the client as an interrupt, which ServerUpdateAction released quietly — no success toast, and nothing told the connection layer a restart was coming. The restart is now deferred like the respawn path. Rollback and the in-flight reset move onto the detached fiber and log instead of failing the (already-acknowledged) RPC. 2. Reconnect backoff escalates to 16s, so the client was frequently asleep exactly when the server came back; refreshing reset the failure count, which is why refreshing "fixed" it. A restart-expected overlay is now armed before dispatch and retries on a flat 2s cadence while it is active, and only while the supervisor is sleeping in backoff so a live attempt is never interrupted. It expires on its own after 90s and is withdrawn on an explicit RPC failure, which proves the server stayed up. 3. Two consecutive websocket-ticket failures evicted the cached DPoP token, forcing a full relay bootstrap and token exchange during reconnect. Eviction is now limited to failures suggesting a stale endpoint; plain unreachability (network/timeout) — the shape of a restart — keeps the token. Also stops piping raw transport messages (which embed internal endpoint URLs) into the composer banner: presentation maps each failure reason to a stable summary and carries the reason for callers, while the raw message remains on the supervisor state for diagnostics. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
T3 Code Mobile
Warning
T3 Code Mobile is currently in development and is not distributed yet. If you want to try it out, you can build it from source.
Quickstart
Note
Uses native modules so using Expo Go is not supported. You need to use the Expo Dev Client.
This app has three variants:
development: Expo dev client, installable side-by-side asT3 Code Devpreview: persistent internal preview build, installable side-by-side asT3 Code Previewproduction: store/release build asT3 Code
Run commands from apps/mobile.
T3 Connect is optional and disabled in a fresh clone. Public configuration belongs in the
repository-root .env or .env.local, not an apps/mobile/.env file. See
../../.env.example.
Development
Start Metro for the dev client:
vp run dev:client
Build and run the local iOS dev client:
vp run ios:dev
If your Xcode account only has a Personal Team, use a bundle identifier you control and opt into the reduced-capability local build. Personal Team builds omit the widget and share extensions, push entitlement, and native Sign in with Apple entitlement; builds without this opt-in are unchanged.
T3CODE_IOS_PERSONAL_TEAM=1 \
T3CODE_IOS_PERSONAL_TEAM_BUNDLE_ID=com.example.t3code.dev \
vp run ios:dev
Build and install a self-contained Release app that does not need Metro:
vp run ios:release
The Personal Team equivalent also needs a unique bundle identifier:
T3CODE_IOS_PERSONAL_TEAM=1 \
T3CODE_IOS_PERSONAL_TEAM_BUNDLE_ID=com.example.t3code \
vp run ios:release
Build and run the local iOS preview app:
vp run ios:preview
Force the review diff highlighter engine:
EXPO_PUBLIC_REVIEW_HIGHLIGHTER_ENGINE=javascript vp run ios:dev
javascript is the default and recommended setting for the review diff screen. Set EXPO_PUBLIC_REVIEW_HIGHLIGHTER_ENGINE=native only when you explicitly want to test the native Shiki engine.
Inspect the resolved Expo config for a variant:
vp run config:dev
vp run config:preview
Run static checks for mobile native code:
node ../../scripts/mobile-native-static-check.ts
The native lint task runs SwiftLint for Swift plus ktlint and detekt for Kotlin. Missing native tools are reported as warnings and skipped locally. CI installs the default toolset from apps/mobile/Brewfile before running the native checks.
EAS Builds
CI uses Expo fingerprinting with the preview:dev profile to reuse an existing compatible build when possible, or start a new internal EAS build when native runtime inputs change. Production and default local builds continue to use the appVersion runtime policy.
For preview or production EAS environments, set T3CODE_CLERK_PUBLISHABLE_KEY,
T3CODE_CLERK_JWT_TEMPLATE, and T3CODE_RELAY_URL
as EAS environment variables. Expo config maps the canonical values into the mobile build.
Create a PR preview dev-client build manually:
vp run eas:ios:preview:dev
Create a cloud dev-client build:
vp run eas:ios:dev
Create a persistent preview build:
vp run eas:ios:preview
Android equivalents:
vp run eas:android:dev
vp run eas:android:preview:dev
vp run eas:android:preview