LockScreen could latch on the locked screen with no working Face ID
prompt until a hard-quit. Two coupled causes:
- inFlight/busy could stay latched if authenticateAsync hung when called
mid active↔inactive transition → gate tryUnlock on AppState 'active'
and release the latch on background (iOS tears down the sheet anyway).
- foreground recovery missed background→inactive→active (prev was
'inactive' at the active event) → track "was backgrounded since last
active" instead, so re-prompt fires reliably (this is why only
hard-quit recovered it). The Face ID sheet's own active→inactive→active
no longer re-triggers (only real 'background' arms the flag).
- appLock.authenticate wraps authenticateAsync in try/catch so a native
reject always settles (the LockScreen finally relies on it).
cancelAuthenticate() is Android-only (no iOS native impl) — fix works by
prevention + self-heal, not cancellation. Frontend-only; needs a native
rebuild, no deploy.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>