Repository navigation
Fix lock screen black screen and fingerprint sensor lockout - #10653
neilisdale wants to merge 1 commit into
Conversation
The lock screen's fingerprint auth retried on a fixed 250ms timer with no backoff or retry cap. On sensors with firmware thermal-protection (e.g. Goodix), sustained rapid retries trip a "Device disabled to prevent overheating" cutoff. Once tripped, every retry failed instantly but the loop kept firing every 250ms anyway, spinning indefinitely with no way to recover short of falling back to a password. Separately, startFingerprint() never called runWake(), so the idleBlankTimer (deliberately excluded from tracking fingerprint auth, since the PAM session stays armed for the whole lock) blanks the display after 5 seconds of no keyboard/mouse activity regardless of in-progress fingerprint attempts. A multi-attempt fingerprint unlock taking longer than 5 seconds runs mostly with the display powered off, which reads as a black/frozen screen. This backs off the retry interval exponentially after the first few consecutive failures (capped at 15s) so the sensor can't be hammered into a thermal lockout, and wakes the display on every fresh verify attempt so retries are visible instead of running in the dark. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BjKUq2LkanQxGMeLHSxAwv
|
Thanks for this, @neilisdale. The retry problem is real, but the change as it stands makes the lock screen wake itself all night, and #13819 handles the retry loop better, so this one is waiting on the maintainer to choose between them. What was checked. Head 2d1cc3f, merged onto current The retry loop is real. On The The backoff counts the wrong thing ( Competing fixes. #13819, #12461 and #12420 also fix the retry loop. Codex Medium compared all four. Its pick, and mine, is #13819: it caps the retries, counts each failed conversation once (only the timer firing counts), and leaves the display blank alone. Its own weakness is that ordinary timeouts use up the same budget, so a healthy reader stops after about nine minutes locked until the mouse or keyboard wakes the lock. #12461 adds more new state and stops even sooner. #12420 ties the reader to whether the display is lit and keeps the 250ms loop while it is awake. This PR is the only one of the four that wakes the display and the only one that never stops retrying. Who checked it. The review and the worker runs above were done by Claude Opus 5.5. Codex Medium reviewed the diff separately and found the same three problems. It also pointed to Quickshell's source as the reason each failure is counted twice. It may have read this session's notes, so its agreement is not a guaranteed independent check. Waiting on the maintainer, to choose between this PR and #13819. If this one goes ahead, it needs the |
|
The retry-backoff part is superseded by merged #7158. Waking the display on every fingerprint attempt is not included, so the display behavior proposed here remains distinct. Keeping this open for that remaining scope; the shared retry path needs a rebase. GPT-6 in Codex and Claude Opus 5.5 Medium checked the coverage against the landed source; Claude's agreement does not guarantee independence. This closure review was read-only and did not rerun runtime tests. |
|
@neilisdale, an update since my last comment: #13819 has closed and #7158 has merged, so nothing in this PR is still worth landing. I'd recommend closing it. That's the maintainer's call. The backoff is on The One case Who checked it. Claude Opus 5.5 read this PR's diff against Waiting on the maintainer to decide whether to close this. |
Problem
Two related bugs in the lock screen's fingerprint flow (
shell/plugins/lock/Service.qml):Fingerprint retry has no backoff.
fingerprintRetryTimerfires at a fixed 250ms on every failure, with no cap. On sensors with firmware thermal-protection (Goodix in my case), sustained rapid retries trip aDevice disabled to prevent overheatingcutoff. Once tripped, every retry fails instantly but the loop keeps firing every 250ms anyway — a busy-loop with no way out short of falling back to password auth. Reproduced consistently: ~90 seconds of continuous retries, dozens of PAM subprocess spawns, until manual password fallback.startFingerprint()never wakes the display.idleBlankTimerdeliberately excludes fingerprint auth from resetting its countdown (see its own comment — the fingerprint PAM session stays "armed" for the whole lock, so gating on it would keep the panel lit indefinitely). But that means the display physically blanks (omarchy-brightness-display off) after 5s of no keyboard/mouse activity even while a fingerprint verify is actively in flight. Any multi-attempt fingerprint unlock over 5s runs mostly with the screen off — which reads as a black/frozen screen.Fix
fingerprintFailureCount, reset on lock/unlock.scheduleFingerprintRetry()backs off exponentially after the first 3 consecutive failures (250ms → 500ms → 1s → ... capped at 15s), so the sensor can never be hammered into thermal lockout.runWake()at the start of each freshstartFingerprint()attempt, so the display lights up (and the idle-blank countdown re-arms) every time a new verify attempt begins, instead of staying dark through retries.First three failures keep the original fast 250ms retry (normal misread UX unchanged); backoff only kicks in on sustained failure.
🤖 Generated with Claude Code
https://claude.ai/code/session_01BjKUq2LkanQxGMeLHSxAwv