ADFA-4971: don't misread a live restore as a killed install + confine… - #317
Merged
Conversation
… Back A healthy restore reached Home and showed 'Installation interrupted — reinstall the app', and reopening landed on the boot gate instead of the restore screen. Both come from one miscalc: restore holds InstallGuard (correct), but LibraryActivity.recovering didn't exclude a live deep-op, so it read the restore as a killed install — firing the recovery AND (via the !recovering guard) blocking the backup/restore return-to-op routing. - LibraryActivity: recovering += !EnvironmentLock.ownerHeld(this). Kills the false 'reinstall' and unblocks the return-to-op routing, so a reopen/notification tap lands directly on the restore screen. A truly killed restore (process dead -> ownerHeld self-heals) still enters recovery. - BackupJobFragment: confine Back like the module index — first Back shows the soft hint, every Back after sends the app to the background (moveTaskToBack), never in-app navigation to a server-down Home.
The Back confinement was active during the pre-service restore copy+validate phase too, where there's no DeepOpService notification yet (it starts at confirm) and nothing is destructive — so backgrounding there left no way back. Gate the confinement on DeepOpProgressRepository running for this owner; before that (copy/validate) a Back just cancels to the bifurcation.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
… Back
A healthy restore reached Home and showed 'Installation interrupted — reinstall the app', and reopening landed on the boot gate instead of the restore screen. Both come from one miscalc: restore holds InstallGuard (correct), but LibraryActivity.recovering didn't exclude a live deep-op, so it read the restore as a killed install — firing the recovery AND (via the !recovering guard) blocking the backup/restore return-to-op routing.