Repository navigation
fix(mobile): show the update screen instead of native screens when the desktop has no page - #29956
Conversation
…prop; unknown routes say unavailable
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Priority: ➖ Normal Merge Risk: ⚪ Minimal · up to
|
What changes for users
New phone builds only. When the paired desktop cannot provide the mobile workspace page, the phone now shows the existing "Update Orca on your computer" screen instead of opening the old native screens.
out/mobile-web)Both blocked cases now use one message, the existing desktop-too-old body. The separate "does not include the mobile workspace yet" body is deleted. Title stays "Update Orca on your computer".
Why
The OTA plan decided there is no native fallback: a host that cannot serve the page gets the update screen (
docs/reference/plans/mobile-ota-phase-a.local.md). Step 0 (#29882, orcad servers ship the page) has merged. This PR is step 1a, the behaviour change only. Step 1b deletes the native screens that are now unreachable.Release ordering: the desktop release that contains #29882 must ship before any phone build that contains this PR. Otherwise users paired to an orcad server get the update screen with no update available.
Design choices
gateVerdict):bundle-unavailableis a wall like every other blocked verdict;onManifestRead): a route the page does not serve is a wall. The compat check now runs first, so a page below the floor is always "desktop too old" even when it lacks the route. The route wall says which side is behind. If a shell with every grant would serve the route, the page needs a grant this app lacks (page-route-grant-missing, "Update Orca Mobile"). Otherwise the desktop's page predates the screen (page-route-unlisted, the shared desktop copy);openByOwnRoutes): a cached bundle that lacks the route now gets a screen the caller picks. Offline it is the existing offline screen ("Connect to this host to download the latest app"), the same answer as having no cache. A host we cannot reach cannot be judged too old, and reconnecting restarts the flow. After a failed download it is the download-failed screen with Try again, because the newer manifest claimed the route (or never arrived), so the failure belongs to the download.native-routeremoved. Nothing produces it any more, so the state kind and the shell'sfallbackprop are gone fromMobileWebShellScreenand from every route call site, includingweb.tsx's redirect. Each switch keeps its native element only for the native-shell build path (shellSwitchDecision), which step 1c removes. The savednative-routeupdate-failure outcome still parses, so older records read.route-unavailable, which the shell renders as that screen. The catch-all opts in withappNamesRoute={false}. Known page routes that an older desktop doesn't list still show desktop-too-old.canOwnHostArea, added in v1.4.225) used to leave wide sessions native under an older page. It now walls them. iPad and foldable users paired to a v1.4.218 to v1.4.224 desktop see "Update Orca on your computer", which is true. Raising the page floor instead would be wrong, becauseMOBILE_WEB_PAGE_VERSIONis still 1 on current desktops. Phones are not affected.route-unavailableoutcome, with copy in Troubleshoot. The persistednative-routeoutcome is kept so older records still parse.Mixed versions
The change is phone-only, with no wire change. Installed apps behave as before. Desktops are unaffected.
Testing
ProtocolBlockScreencopy. All 23 changed or new cases fail against main's source.tsc --noEmit,pnpm lint,oxfmt --check, full mobile vitest (10804 passed), root mobile-web script tests,pnpm run check:code-quality:changed.EXPO_PUBLIC_MOBILE_SHELL=ota, change confirmed in the Hermes bundle) on an Android emulator against three isolatedorca-dev servehosts:out/mobile-webabsent: wall with the shared copy. Both "Back to hosts" and system Back return to the host list, and re-entering shows the wall again;pageVersion): same wall.