Skip to content

fix(fingerprint): prevent sensor timeout on long-running sessions#962

Open
JeremieRodon wants to merge 3 commits into
hyprwm:mainfrom
JeremieRodon:feat/fp_verif_timeout
Open

fix(fingerprint): prevent sensor timeout on long-running sessions#962
JeremieRodon wants to merge 3 commits into
hyprwm:mainfrom
JeremieRodon:feat/fp_verif_timeout

Conversation

@JeremieRodon
Copy link
Copy Markdown

Introduces an inactivity timeout mechanism that pauses fingerprint verification after a configurable period (default: 0 second/disabled) when no user input is detected. This prevents some device drivers from disconnecting or disabling the sensor during extended lock sessions.

The verification automatically resumes when user activity is detected (mouse movement, clicks, or keyboard input). The sensor is properly released when paused and re-claimed when resuming.

May fixe #702 though that's unclear as the issue is not well documented

See #955 for more context and history on this PR.

@kylemanna
Copy link
Copy Markdown

Been running this for a few days on Lenovo Slim 7i with flaky goodixtls-55x4 firmware.

Previously it'd pretty much always display a message about timing out, with this it seems to recover most of the time. I suspect the other issues are due to the firmware :-/

After varying amounts of time (1 min - 25 minutes) fprintd disconnects leading to this issue from my initial observations. I set the inactive timeout to 15 seconds to disable the finger print sensor just before hypridle turns off the display again and this works better then ever.

Comment thread src/auth/Fingerprint.cpp Outdated
Comment thread src/core/hyprlock.cpp Outdated
Comment thread src/core/hyprlock.cpp Outdated
@JeremieRodon JeremieRodon force-pushed the feat/fp_verif_timeout branch 3 times, most recently from 26ff1e9 to 6a00086 Compare May 9, 2026 07:50
Introduces an inactivity timeout mechanism that pauses fingerprint verification after a configurable period (default: 0 second/disabled) when no user input is detected. This prevents some device drivers from disconnecting or disabling the sensor during extended lock sessions.

The verification automatically resumes when user activity is detected (mouse movement, clicks, or keyboard input). The sensor is properly released when paused and re-claimed when resuming.

May fixe hyprwm#702 though that's unclear as the issue is not well documented
@JeremieRodon JeremieRodon force-pushed the feat/fp_verif_timeout branch from 6a00086 to 53a4718 Compare May 9, 2026 09:29
@JeremieRodon
Copy link
Copy Markdown
Author

I took the liberty to rebase the branch on 0.9.5 and I changed the 2 log lines to use the hyprutils logger helper.

@PointerDilemma
Copy link
Copy Markdown
Collaborator

@JeremieRodon needs a clang-format. Otherwise looks ok.

However, I wonder if we should add idle/resume to the auth interface and use the idle-notify wayland protocol to trigger those methods.
The benefit of that would be that one, I think the lid-switch counts as an idle event on the compositor level and that would allow a user to open the laptop and use the fingerprint sensor right away; two, some pam usages might also benefit from such and idle mechanism.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants