Expo Updates fallback after a failed OTA launch: what triggers the revert and can it be forced?
0 reputation · 11 Aug 2021, 10:03 UTC
0 reputation · 11 Aug 2021, 10:03 UTC
I am designing a release process around expo-updates and need to understand the documented fallback behavior when an OTA update fails to load at launch. The docs describe the app reverting to the embedded binary, but the exact mechanics are unclear to me.
Assume a recent Expo SDK with expo-updates configured for automatic updates on both iOS and Android. My constraints: I cannot prompt users to reinstall, and I want to avoid shipping a native build just to recover from a bad JS bundle.
The points I cannot resolve from the documentation:
I plan to verify by deploying a deliberately broken bundle to a test channel, but I would like to know the expected behavior first. Note: behavior may have changed across recent SDK versions, so answers citing a specific SDK version are preferred.
35275 reputation · 11 Aug 2021, 14:40 UTC
In recent Expo SDKs, a failed OTA launch triggers an automatic fallback to the embedded binary on the next cold start. There is no supported client-side API to force a rollback or invalidate an update programmatically. Documented behavior is largely consistent across iOS and Android, though the underlying storage and crash-detection paths differ.
expo-updates is designed to record a successful-launch marker once the JS bundle has loaded and the app reaches a stable state. If the process terminates or the bundle fails to execute before that marker is written, the next launch treats the update as failed and reverts to the binary embedded in the native build.
The timing of the failure matters:
Exact timing thresholds and fallback asset selection have been refined across SDK releases, so confirm the behavior against your installed expo-updates version.
No supported client-side API exists to invalidate an update or force a rollback from JavaScript. Recovery is server-side:
Clearing app data or reinstalling removes the update cache, but that is a manual user action, not a programmatic mechanism.
Recent Expo SDKs document the same fallback model on both platforms: launch-failure detection, marker persistence, and embedded-binary fallback. The implementation details differ, but no platform-specific rollback API is exposed, and neither platform offers a supported "revert to previous OTA" option.
To confirm this on your installed version:
expo-updates on a physical device.expo-updates logging to verify whether the launch-failure marker was set before the crash.Is your concern a bundle that fails to load (immediate crash on launch), or one that loads successfully but crashes later? If it is the latter, the automatic fallback may not apply, and your recovery process must rely on publishing a corrective update rather than waiting for the revert.
Use comments to ask for clarification. Post a solution as an answer.
No question comments on this page.