Lock shell dies during normal idle->lock; session permanently locked, reboot required
Summary
The Omarchy shell (a single quickshell process hosting the omarchy.idle and omarchy.lock services) exits while the session is locked during a normal idle → lockscreen cycle with no user interaction and no idle inhibitor active. Because ext-session-lock leaves the session permanently locked when the lock client dies, Hyprland shows its "lockscreen app died" failsafe and the machine is unusable until a reboot.
Expected behavior
The idle → lockscreen → lock cycle should not end in a dead shell. At minimum, if the lock client dies, the session should be recoverable (respawn / re-acquire the lock) instead of requiring a reboot, and diagnostics should be available afterwards.
Reproduction steps
- Start a session and leave the machine untouched (no media playing, no idle inhibitor, nothing fullscreen).
- Idle timeout fires at
idle.screensaver(150s), thenidle.lock(300s). The lock screen appears normally. - After some time the lock surface vanishes and the Hyprland gray failsafe ("lockscreen app died") appears.
- Nothing recovers the display. Only a reboot (or TTY + reboot) restores the system.
Environment
- OS: Arch Linux, kernel 7.1.6
- CPU: Intel Core i5-13500 (13th gen)
- GPU: Intel UHD Graphics 770 (iGPU only)
hyprland0.56.2-1quickshell-git0.3.0.r18.g10b439f-3 (quickshell-git AUR, built 2026-07-25, since omarchy requires the git build)omarchy-dev4.0.0.r1569.g007d6fc-1idle.lock= 300,idle.screensaver= 150
Diagnostics / observations
- No coredump. The previous session's journal contains no
systemd-coredump/ signal-crash entry forquickshell, and no Hyprland crash report — the death looks like an exit without a signal (or the dump was lost). - No shell log.
quickshell -n -p $OMARCHY_PATH/shellis launched by Hyprland autostart viahl.exec_cmd()with no output redirection, so the idle/lock event trail is not persisted anywhere and is lost on reboot. This made root-cause analysis impossible from the shell side. - Hyprland journal shows
error in client communication (pid …)~15 min into the (short, otherwise quiet) session, which may be the shell being killed by the compositor. - The lock service (
/usr/share/omarchy/shell/plugins/lock/Service.qml) already contains a guard for zero/phantom screens (requestSessionLock/hasRealScreen()/ pending timers), presumably in response to Quickshell's known session-lock crash reports. This crash appears to get past that guard, or comes from a different path.
Possibly related upstream
- quickshell-mirror/quickshell #61 —
qFatal()"Session lock screen does not correspond to a real screen" when a lock surface targets a phantom/no screen. - quickshell-mirror/quickshell #76 — crash in
WlSessionLock::realizeLockTarget()when the compositor rejects a lock request while no real screen exists.
Happy to attach a full omarchy debug log and/or a screen capture of the failsafe on the next occurrence.
Update after a second confirmed occurrence. This is now reproducible and I have the server-side smoking gun.
- Crashed boot 2 (2026-08-08 13:07–14:24):
error in client communication (pid 17682)at 14:09:48, right at the idle→cycle transition. - Crashed boot 3 (2026-08-08 14:25–15:08):
error in client communication (pid 1308)at 15:03:23 —1308is thequickshell -n -p /usr/share/omarchy/shellPID in that session (confirmed while it was running).
So the shell is not crashing on its own: Hyprland (0.56.2) terminates it with a client/protocol error during the idle→screensaver→lock handoff. Because the shell is holding ext-session-lock at that moment, the session remains locked, Hyprland shows its 'lockscreen app died' failsafe, and only a reboot recovers.
After this report
The failure has been falling into a gap: quickshell's output was un-redirected (launched via quickshell -n -p $OMARCHY_PATH/shell from Hyprland autostart) and Hyprland's own log only lives in /run/user/*/hypr/*/hyprland.log, wiped on every reboot. Both are now persisted:
- quickshell stdout/stderr →
~/.local/share/omarchy/quickshell.log(wrapper on PATH) - Hyprland log → copied to
~/.local/share/omarchy/hyprland-crash.logwhenever the shell process exits (the wrapper's exit trap)
Next occurrence we will attach the exact hybrid protocol error from the Hyprland log.
Questions for maintainers:
- Known Hyprland 0.56.x behavior: does it terminate an ext-session-lock client on any protocol error while holding the lock, rather than allowing re-acquire?
- Any known quickshell/omarchy protocol misuse around idle→screensaver start (e.g. duplicate lock surfaces, wl_surface role misuse) that would trigger
error in client communication?
Definitive trace from a captured crash (2026-08-08, boot that ended at quickshell exit 15:28:29 local / 09:58:29Z)
Caught it with a user-side wrapper that snapshots the compositor log as the shell dies. Conclusion: not idle-inhibit. The crash is a monitor link flap → headless Hyprland → EGL death of the lock surface while ext-session-lock is held.
Timeline (UTC, quickshell.log):
09:47:49Z idle-monitor: active
09:54:42Z idle-monitor: idle; idle-cycle-start: screensaver=150 lock=300; screensaver process-start
09:54:42Z idle-monitor: active (event window); screensaver cycle remains armed; screensaver exits 0
09:57:12Z lock-system: lock-timeout
09:57:12Z lock-requested; lock-pending: screen-stabilizing
09:57:13Z secure=true <-- ext-session-lock acquired
09:58:29Z WARN qt.qpa.wayland: Could not create EGL surface (EGL error 0x3000)
09:58:29Z WARN qt.qpa.wayland: eglSwapBuffers failed with 0x300d, surface: 0x0
09:58:29Z WARN: The Wayland connection experienced a fatal error: Invalid argument
09:58:29Z quickshell exited rc=255 <-- shell dies while lock still held
Unifying observation: quickshell.spam-managed log contains, repeatedly across the session:
WARN quickshell.hyprland.ipc: Got removal for monitor "FALLBACK" which was not previously tracked.
and Hyprland's aquamarine log shows the physical connector dropping repeatedly:
DEBUG from aquamarine ]: drm: Connector HDMI-A-2 disconnected
DEBUG from aquamarine ]: drm: Connector HDMI-A-2 connected
6 disconnects in that ~4h boot. In the (stable) session since, 0. When the sole real output disappears Hyprland goes effectively headless/FALLBACK, Quickshell's lock surface can no longer create an EGL surface, and Qt raises fatal error: Invalid argument → whole shell process dies while holding the session lock → Hyprland failsafe → user must reboot.
Environment: hyprland 0.56.2-1, quickshell-git 0.3.0.r18.g10b439f-3, aquamarine 0.14.0-1, kernel 7.1.6-arch1-1, Intel UHD 770 (i915), single monitor 2560x1440 @ HDMI-A-2.
Asks:
- Quickshell should not be tearing down the whole shell (and leaving the session stuck) when a monitor it's using for a lock surface briefly disappears — could the lock surface gracefully tolerate the output dropping/hotplug, so the shell survives (and reconnect) instead of exiting rc 255 ?
- Hyprland/aquamarine: can a transient HDMI flicker be masked/retried so the sole output doesn't enter headless with
FALLBACK?
Full logs available on request (quickshell.log + hyprland-crash.log).
I was looking into this too but had trouble getting enough information to solve it.
I thought this was related to the transition after DPMS sends the 'off' signal to the monitor; some monitors completely disconnect from the host when they receive the DPMS off signal. The lock client is still trying to render to a surface that doesn't exist.
A DPMS related fix was included in hyprland 0.56 that was for a bug during unplug/replug of a DP monitor. It looked like that solved the problem I was looking at where the display ID was lost and a new one was issued when the monitor disconnects and re-connects. But I still have the problem and basically can't walk away from my computer without 'stay awake' enabled.
It sounds like you are getting some useful logs. Does your monitor not turn off a few seconds after lock? On my system, the screen goes off and when I wake it I see the hyprland lockdead screen. I was lead to believe that it happened during wake as it transitions back to a real surface, but I had trouble getting good logs. If your monitor stays on, then you can see exactly when lock dies.
I had the problem intermittently on omarchy before I installed quattro where the lock client changed from hyprlock to quickshell, but it seems to be worse now which could just be updated versions of hyprland.
@CaffeinatedTech — you nailed it. Confirmed the same mechanism here with the captured logs.
1. Does the monitor turn off a few seconds after lock? Yes.
The omarchy lock plugin runs, ~5 s after acquiring ext-session-lock (idleBlankTimer in /usr/share/omarchy/shell/plugins/lock/Service.qml), a blank step:
Process blankProcess: bash -c "omarchy-brightness-keyboard off; omarchy-brightness-display off"
omarchy-brightness-display off dispatches hl.dsp.dpms({ action = "disable" }) through Hyprland.
2. Exactly when it dies relative to that — from the captured boot:
09:57:13Z secure=true <- ext-session-lock acquired
09:57:18Z ~5s later: DPMS off dispatched (idleBlankTimer => blankProcess)
09:58:29Z aquamarine: drm Connector 527 connection state: 2
09:58:29Z drm Connector HDMI-A-2 disconnected -> Disabling output HDMI-A-2
09:58:29Z quickshell.hyprland.ipc: Got removal for monitor "FALLBACK"
09:58:29Z qt.qpa.wayland: Could not create EGL surface (EGL error 0x3000)
09:58:29Z eglSwapBuffers failed with 0x300d, surface: 0x0
09:58:29Z The Wayland connection experienced a fatal error: Invalid argument
09:58:29Z quickshell exited rc=255 <- while lock still held
So the crash is ~1 m + screen-off after the DPMS blank, not on wake: this monitor (Lenovo L24q-35 over plain HDMI) treats DPMS power-off as a physical unplug — the DRM connector goes to connection state: 2 and aquamarine tears the output down. The quickshell log also shows the hit path explicitly on every occurrence:
INFO qt.qpa.wayland: There are no outputs - creating placeholder screen
WARN: Layershell screen does not correspond to a real screen. Letting the compositor pick.
DEBUG: Not creating lock surface for screen QScreen(name="") as it is not backed by a valid wayland output.
WARN quickshell.hyprland.ipc: Got removal for monitor "FALLBACK"
And one interesting datapoint: the disconnects happen periodically (6×, evenly spaced across the boot ≈ every DPMS-off cycle). Every one of them lands a FALLBACKremoval warning; the fatal one is the removal that hits while a lock surface is already realized and targeting that monitor.
So the responsible-party split:
- Hyprland/aquamarine: a DPMS power-off is being escalated into a full connector disconnect + output teardown on this monitor. (You mentioned hyprland 0.56 had a DP/serial-DP fix but it doesn't cover this DVI/HDMI-reaction behavior.) If DPMS-off stayed as "powered off, link up" (i.e. keep the CRTC/framebuffer instead of
Disabling output), the lock surface would apparently never crash. - Quickshell: when a lock surface's output is lost mid-lock, it does a full error exit (
Could not create EGL surface ... fatal error) that kills the entire shell while holding ext-session-lock. It should recreate the surface on the next real screen / notqFatal. That's exactly the#61/#76family.
If either side ships a fix, happy to re-build hyprland/quickshell-git and re-test the same stay awake off → idle → lock cycle.
Want me to also try the DPMS-off workaround (blank the screen without hlall .dsp.dpms off) to confirm the trigger in isolation? I can patch my local lock config to skip omarchy-brightness-display off and see if the crash disappears without a lock change.
Yeah if you come up with a patch I can test it on my system. I still have everything in place to build hyprland and test it, I can do the same with quickshell.
Root cause now pinned after a live recovery drill + DPMS-off A/B test.
We verified on a running session with the lock-shell-recovery build active:
The crash is caused by the lock's own DPMS blank, not by idle-inhibit.
Sequence on our system (single Lenovo L24q-35 over HDMI-A-2, i915, Hyprland 0.56.2 + aquamarine 0.14.0):
- Idle → lock acquires (ext-session-lock
secure=true). - ~5 s later the lock plugin (omarchy shell
lock/Service.qml) runs the blank step:omarchy-brightness-keyboard off; omarchy-brightness-display off→ dispatcheshl.dsp.dpms({action="disable"}). - This monitor treats DPMS power-off as a physical unplug. aquamarine immediately logs:
→ Hyprland momentarily headless → Quickshelldrm: Connector HDMI-A-2 enabledState changed true -> false drm: Connector HDMI-A-2 disconnected -> Disabling output HDMI-A-2 drm: Connector HDMI-A-2 connectedGot removal for monitor "FALLBACK"→ the lock surface can't create an EGL surface (EGL error 0x3000,eglSwapBuffers failed 0x300d) →The Wayland connection experienced a fatal error: Invalid argument→ the whole shell exits rc 255 while ext-session-lock is still held → Hyprland lockdead failsafe → reboot only.
The DPMS-off theory is confirmed by A/B:
- With
omarchy-brightness-display offin the blank: reproducible drop/death every lock (observed repeatedly, including the recovered shell dying again within ~14 s). - With the display-blank skipped (local workaround: blank keyboard only): full lock → blank-window → unlock, 0 connector disconnects, shell alive throughout, user authenticated back in normally.
Two upstream gaps (what needs fixing):
- Hyprland/aquamarine: a DPMS power-off on this HDMI monitor escalates to a full connector disconnect + output teardown (
enabledState true→false→disconnected → Disabling output). If DPMS-off stayed "link up, powered off", the lock surface would never lose its output. (CaffeinatedTech mentioned the hyprland 0.56 DP fix; it does not cover this HDMI link-drop behavior.) - Quickshell: when a lock surface's output vanishes mid-lock, it
qFatals the entire shell (Could not create EGL surface ... fatal error) instead of recreating the surface — killing the only process that holds ext-session-lock. This is the#61/#76family: it must not exit the process on a transient output loss while locked.
Partial recovery (PR direction) is validated: omarchy-restart-shell (in the lock-shell-recovery PR) successfully relaunches the shell and re-secures the lock from a dead-lock state — no reboot needed for recovery. But the underlying DPMS-triggered crash continues to recur until the two gaps above are addressed.
Net: the fix we'd want upstream is either keep DPMS-off as link-up on HDMI, or make Quickshell survive lock-surface output loss.
New datapoint: Quickshell #61 — "Fatal Error from SessionLock after turning off the monitor" — is already closed/fixed, and its fix is in our build. The remaining defect is at the Hyprland/aquamarine stage, not Quickshell's old surface bug.
Upstream status:
quickshell-mirror/quickshell#61("Fatal Error from SessionLock/surface after turning off the monitor") is CLOSED / COMPLETED (2025-06-19, fix commit3d3b7f1c).- Our installed
quickshell-gitis0.3.0.r18.g10b439f, built 2026-08-06 — a year after that fix, so #61's fix is already compiled in. The shipped tree since then also contains the related lock hardening (wayland/lock: avoid creating lock surfaces for uninited wl screens,wayland/lock: add window null check in surface isVisible).
Yet we still crash. So the fatal is being re-driven by a sequence #61 never covered:
lock blank (5s after secure) -> hl.dsp.dpms({action="disable"})
-> Lenovo L24q over HDMI physically drops the link
-> aquamarine: "drm: Connector HDMI-A-2 disconnected -> Disabling output HDMI-A-2"
-> Hyprland briefly headless / FALLBACK
-> quickshell "Got removal for monitor FALLBACK"
-> EGL surface fail -> "The Wayland connection experienced a fatal error: Invalid argument"
-> shell exits rc 255 while ext-session-lock is still held
The A/B proof (comment above) confirms the DPMS-off trigger: skipping the display blank yields 0 connector disconnects and a surviving shell across full lock→blank→unlock cycles; with it, the drop/death reproduces every time.
Routing suggestion: since Quickshell already fixed its session-lock output-loss path (and that fix is present in our build), the actionable upstream fix is now Hyprland/aquamarine not escalating a DPMS power-off into a hard connector disconnect on HDMI — i.e. keep the link up while powered off, instead of Disabling output. Worth filing at hyprwm/Hyprland + hyprwm/aquamarine (this monitor also showed error in client communication kill lines from Hyprland).
For anyone following this thread:
- Recovery (dead-lock → restart+relock without reboot): PR #6630.
- Mitigation (
lock.displayBlank: falseavoids the DPMS drop entirely): PR #6642.
No coredump. … This made root-cause analysis impossible from the shell side.
I hit this on 2026-08-14 and did get the coredump, so here it is in case it helps. Different hardware to yours (desktop, dual DP, NVIDIA RTX 3080 / nvidia 610.57.04), omarchy 4.0.0-1, quickshell-git 0.3.0.r20.g28771c7-1, hyprland 0.56.2-1. Same shape: normal idle → lock cycle, lock surface vanished, Hyprland failsafe, TTY needed.
The shell had locked normally at 23:13:52 (secure=true) and died ~2.5 min later, as I returned to the machine (idle-monitor: active).
omarchy-shell[1553]: FATAL: Tried to show lockscreen surfaces without active lock
coredumpctl, SIGABRT, quickshell -n -p /usr/share/omarchy/shell:
#6 abort (libc.so.6 + 0x25685)
#8 _ZN6QDebugD1Ev (libQt6Core.so.6 + 0x111d11)
#9 _ZN13WlSessionLock14updateSurfacesEbPS_ (quickshell + 0x836e1)
#10 _ZN13WlSessionLock11qt_metacallEN11QMetaObject4CallEiPPv
#11-16 … QQmlPropertyPrivate::write / QObjectWrapper::setProperty …
#30 _ZN9QQmlTimer5eventEP6QEvent (libQt6QmlMeta.so.6 + 0x20a5c)
So it is a qFatal() in WlSessionLock::updateSurfaces(), driven by a QQmlTimer writing a property on WlSessionLock — i.e. pendingSessionLockTimer (Service.qml L442) → requestSessionLock() (L63) → L76 sessionLock.locked = true. That is a deliberate hard-abort, not a segfault, which may explain why it can look like "an exit without a signal" if the dump is lost.
Note this is a different failure from the realizeLockTarget() / phantom-screen crashes you linked (quickshell #61 / #76) — realizeLockTarget does not appear in the trace, and hasRealScreen() reported 2 real screens throughout.
On my machine the abort then looped: quickshell's crash handler re-execs a fresh instance, which sees the compositor's ext-session-lock still held by the dead client, runs recoverStrandedLock(), and aborts again at the same L76 — a fresh service-ready every ~8–12s for ~70s, until strandedLockRetryTimer exhausted its retry budget and froze at secure:true / sessionLocked:false. That end state is #6888, which I've commented on with the detail.
Re: your "no shell log" point — the event trail did survive here, because the shell is launched under the systemd user session and its DEBUG qml: output lands in the journal as omarchy-shell[PID]. journalctl --user -b | grep 'omarchy lock' gave me the full lock/idle trail across reboots, which is what made the loop visible. Might be worth a try on the next occurrence.
Recovery without a reboot is possible: restart the shell and re-lock (omarchy-restart-shell does exactly this, though a guard bug currently makes it refuse in this state — details in #6888).
Reproduced the same EGL/Wayland fatal signature from this issue (EGL error 0x3000 → eglSwapBuffers failed ... surface: 0x0 → Wayland connection fatal → quickshell exited rc=255), but on a run without any DPMS-off or monitor-disconnect event preceding it — so this may be a second path into the same failure, not covered by the DPMS/aquamarine root cause pinned above.
Environment: omarchy 4.0.0-1, quickshell-git 0.3.0.r20.g28771c7-1, hyprland 0.56.2-1, aquamarine 0.14.0-2, single external monitor (Dell U2718Q, HDMI-A-2), Intel Haswell iGPU (i915).
Timeline (UTC, journal):
17:35–17:36 pacman upgrades: wayland, mesa, wayland-protocols, xorg-xwayland,
vulkan-icd-loader, gtk4, gtk4-layer-shell, vulkan-intel
17:58:27 one isolated lock-requested/idle-monitor cycle (not a loop)
18:19:35 omarchy-shell starts a continuous crash-restart loop:
"Omarchy shell exited with status 255; relaunching."
every ~15-17s, each new instance re-hitting
"lock-requested" -> "idle-monitor: active", some cycles
logging "Could not create EGL surface (EGL error 0x3000)"
and "The Wayland connection broke. Did the Wayland
compositor die?"
18:29:06 loop still running (35+ consecutive cycles observed)
(shortly after) loop stopped on its own, no reboot/manual intervention
No aquamarine/DRM connector disconnect and no DPMS dispatch appear anywhere in the 5 minutes before the loop started, or during it — different from the mechanism identified above. The nearest correlated event is the gtk4/wayland/mesa/vulkan-intel package upgrade ~43 minutes earlier, though I can't prove causation, only correlation.
Collateral damage: during the loop, a third-party GTK4 + gtk4-layer-shell client (voxtype-osd-gtk4, unrelated to Omarchy) segfaulted twice, both inside wl_display_dispatch_queue_pending → GTK4 callback — consistent with Wayland client-side proxy/output objects being destabilized by the repeated surface teardown/recreation during the loop. Not an Omarchy bug on its own, but a symptom of the same instability, worth noting since other layer-shell clients on the system could hit it too.
Filed by Claude Sonnet 5 via Claude Code.
Reproduced twice on 2026-08-15 (18:01 and 20:40 PDT) on different hardware: Intel HD 630 (Kaby Lake, i915), dual DisplayPort monitors, hyprland 0.56.2-1, quickshell-git 0.3.0.r20.g28771c7-1, aquamarine 0.14.0-2, omarchy-dev 4.0.0.r1761.g7be59e1-1, kernel 7.1.8-arch1-3.
Same signature as the captured trace above, but on the wake side rather than DPMS-off: session locked on idle timeout → displays off → on user return (idle-monitor: active) the DP outputs renegotiate and all wl_outputs briefly disappear → There are no outputs - creating placeholder screen → Not creating lock surface for screen QScreen(name="") as it is not backed by a valid wayland output → Got removal for monitor "FALLBACK" → ~4 s later Hyprland logs error in client communication (pid <shell>) and the shell dies with The Wayland connection experienced a fatal error: Invalid argument.
One data point contrasting with #6888: on this build the stranded-lock recovery worked both times — the restarted shell logged lock-stranded: recovering, re-acquired ext-session-lock within ~2 s (secure=true), and a normal password unlock followed. So the failure mode here is a visible lockscreen death/restart, not a stuck session.
Filed by Claude Fable 5 via Claude Code.
Follow-up from my earlier comment: a user-side workaround that confirms the zero-outputs mechanism and holds up in testing.
Workaround: keep a headless guard output alive for the entire locked period, so the session can never drop to zero wl_outputs while the shell holds ext-session-lock. Via omarchy plugin clone omarchy.lock, then in the clone's Service.qml:
beginLock(): runhyprctl output create headless lockguardfinishUnlock(): runhyprctl output destroy lockguard
Results (same machine as my previous comment — Kaby Lake HD 630, dual DP): multiple idle→lock→DPMS→wake cycles including a 1h20m blank, shell PID unchanged throughout, none of the crash-signature lines (There are no outputs - creating placeholder screen, error in client communication, fatal error: Invalid argument). Before the guard, the same wake transition killed the shell three times in one day.
Two notes for whoever picks this up:
- Scope the guard to the whole locked period, not the blank/wake commands. My first attempt created the guard at blank and destroyed it on a 10 s delay after wake; that races re-blank cycles and failed — crashes recurred with the zero-outputs line back. Lock-scoped, it has been airtight so far.
- There appears to be a second, rarer error path. In one crash storm the freshly restarted recovery shell died again 18 s after re-locking without the zero-outputs line — some other protocol error during output churn. The guard closes the primary documented path; it may not close that one.
A guard output (or equivalent "never zero outputs while locked" invariant) might be worth shipping as a stopgap in the lock plugin itself until the quickshell/qtwayland placeholder-screen path is fixed.
Filed by Claude Fable 5 via Claude Code.
Root cause identified: a race between output removal and ext_session_lock_v1.get_lock_surface. Captured with WAYLAND_DEBUG=client on a controlled reproduction, twice, with the same sequence both times.
This also answers the question posed upthread — "any known quickshell/omarchy protocol misuse around idle→screensaver start (e.g. duplicate lock surfaces, wl_surface role misuse) that would trigger error in client communication?" — yes, and here is the exact exchange.
Reproduction
Same machine as my earlier comments: Intel HD 630 (Kaby Lake, i915), dual DisplayPort, hyprland 0.56.2-1, quickshell-git 0.3.0.r20.g28771c7-1, aquamarine 0.14.0-2, omarchy-dev 4.0.0.r1761.g7be59e1-1, kernel 7.1.8-arch1-3.
- Ran the shell under
WAYLAND_DEBUG=clientplusQT_LOGGING_RULES="qt.qpa.wayland*=true", from a supervisor mirroringomarchy-launch-shell's relaunch behaviour so a captured crash still recovers the session lock. - Locked the session.
- Flapped DPMS in a loop:
hyprctl dispatch 'hl.dsp.dpms({ action = "disable" })'/... "enable", roughly 20 s off, 15 s on.
Crash on flap cycle 8 (~4.5 minutes in), and again on the wake at unlock — two independent captures.
The fatal sequence
From capture 1 (capture 2 is identical modulo object ids — #126 instead of #141):
18:16:42.634 -> ext_session_lock_v1#60.get_lock_surface(new id ext_session_lock_surface_v1#141, wl_surface#138, wl_output#97)
18:16:43.210 ext_session_lock_surface_v1#141.configure(20499, 2560, 1440)
18:16:43.210 -> ext_session_lock_surface_v1#141.ack_configure(20499)
... output torn down during the DPMS churn ...
18:17:16.908 -> ext_session_lock_surface_v1#141.destroy()
18:17:17.182 wl_display#1.delete_id(141) <- id released for reuse
18:17:17.684 -> ext_session_lock_v1#60.get_lock_surface(new id ext_session_lock_surface_v1#141, wl_surface#175, wl_output#169)
^ no configure ever arrives for this one
18:17:20.865 -> ext_session_lock_surface_v1#141.destroy()
18:17:21.101 wl_display#1.error(wl_display#1, 0, "invalid object 141")
Immediately after: The Wayland connection experienced a fatal error: Invalid argument, and quickshell _exit()s while still holding ext-session-lock — which is what leaves the session on Hyprland's failsafe.
The bug is the second get_lock_surface: quickshell requests a lock surface on wl_output#169, an output the compositor has already torn down. The compositor never materialises the object (hence no configure), so the client's later destroy references an object the server does not have, and the connection is killed.
Notes
- This is the mechanism behind both observed variants. The "all outputs gone → placeholder screen" path and the crash I reported with outputs still present are the same race — zero outputs simply maximises the number of teardowns to race against.
- It reproduces with no idle/screensaver involvement at all. Plain DPMS churn while locked is sufficient, so anything that flaps a connector (monitors that drop their DRM connector on DPMS-off, DP link re-training, hotplug) can trigger it.
- The headless-guard workaround from my previous comment reduces but does not close this. Keeping an output alive for the locked period prevents the zero-output storms — it has held in day-to-day use here — but it cannot fix the race itself, and I could still reproduce with the guard removed in minutes.
Where the fix likely belongs
- quickshell: don't call
get_lock_surfacefor awl_outputwhose global has been removed (or has a removal in flight), and treat a lock surface that never receivedconfigureas never created — destroying such a surface is what draws the fatal error. - hyprland (arguably): posting a fatal
invalid objectat a client for destroying a lock surface the compositor silently declined to create is harsh; tolerating that destroy would make clients robust against this race for free.
Full protocol captures (774 KB and 237 KB; fatal error at run1.err:9496 and run2.err:4002) available — happy to attach, or to trim them to a window around the failure if that is more useful.
Filed by Claude Opus 5 via Claude Code.
Pinned to a source line. Follow-up to my root-cause comment above, now with a C++ backtrace — and a correction to something I got wrong there.
Useful shortcut for anyone else debugging this: no rebuild is needed. The omarchy repo's /usr/bin/quickshell ships unstripped with full debug info, so gdb resolves quickshell frames and source paths out of the box.
The backtrace
Breakpoint on WlSessionLock::updateSurfaces, same DPMS-flap reproduction (crashed on cycle 2 this time). The last call before the fatal error:
#0 WlSessionLock::updateSurfaces (show=true, old=0x0) at src/wayland/session_lock.cpp:55
#2 QWindowSystemInterface::handleScreenAdded(QPlatformScreen*)
#3 QtWaylandClient::QWaylandDisplay::handleScreenInitialized(QWaylandScreen*)
#4 QtWaylandClient::QWaylandScreen::maybeInitialize()
#8-9 libwayland-client
#10 wl_display_dispatch_queue_pending()
(the immediately preceding hit is the same function reached via handleScreenRemoved)
The mechanism
src/wayland/session_lock.cpp:47-48 connects the screen signals with the default (direct) connection type:
QObject::connect(guiApp, &QGuiApplication::screenAdded, this, &WlSessionLock::onScreensChanged);
QObject::connect(guiApp, &QGuiApplication::screenRemoved, this, &WlSessionLock::onScreensChanged);
So updateSurfaces() runs synchronously inside wl_display_dispatch_queue_pending(), part-way through a batch of queued registry events. It creates a lock surface for the just-added FALLBACK screen while that same screen's wl_registry.global_remove is still sitting further down the same undispatched batch.
That matches the protocol captures exactly. The global_remove had been on the wire for 385 ms (capture 1) and 433 ms (capture 2) before the doomed get_lock_surface — proven by a different event queue in the same process (mesa's EGL display queue, with its own wl_registry proxy) having already dispatched it. Qt's default queue only got to it 3.5 ms and 395 ms after the request went out.
The existing guard in updateSurfaces cannot catch this:
if (waylandScreen == nullptr || waylandScreen->isPlaceholder() || waylandScreen->output() == nullptr)
FALLBACK is a genuine wl_output advertised by the compositor, not Qt's placeholder screen, so it passes all three checks.
Suggested fix
Make those two connections Qt::QueuedConnection (or coalesce them into a single deferred update), so updateSurfaces runs after the dispatch batch is drained. By then the dead FALLBACK screen is gone from QGuiApplication::screens() and no lock surface is ever requested for it.
Correction to my earlier comment
Two things I framed wrongly above:
- I suggested Hyprland was "arguably harsh" to post a fatal error here. With 385–433 ms of advance notice already delivered to the client, that reading does not hold up — this is not a wire race, it is the client acting on a global it had already been told was removed. The fault sits clearly on the client side. (A compositor that ignored the destroy would still make clients robust for free, but that is a hardening nicety, not shared blame.)
- I said zero outputs "simply maximises the number of teardowns to race against." In fact
FALLBACKonly exists when outputs hit zero, and it is the output in both fatal requests — so the zero-output condition looks necessary, not merely aggravating. That is a better explanation of why the headless-guard workaround has held up in daily use here than the probabilistic story I gave.
Filed by Claude Opus 5 via Claude Code.
Correction: the Qt::QueuedConnection fix I suggested above does not work. I built it and tested it; posting the negative result so nobody spends time on it.
Method
Built quickshell from source at the exact revision I am running (28771c7, matching quickshell-git 0.3.0.r20.g28771c7-1), RelWithDebInfo, crash handler off so a crash exits cleanly. Ran that binary as the shell, session locked, guard workaround disabled, then flapped DPMS (~18 s off / 6 s on) until the shell died. Then changed only Qt::QueuedConnection on the two screen signals in src/wayland/session_lock.cpp, rebuilt incrementally (one translation unit), and repeated. Same tree, same flags, two words different.
Result
| build | outcome |
|---|---|
| stock | crashed on cycle 1 |
Qt::QueuedConnection |
crashed on cycle 10 |
Identical signature and path in both:
WARN quickshell.hyprland.ipc: Got removal for monitor "FALLBACK" which was not previously tracked.
INFO qt.qpa.wayland: There are no outputs - creating placeholder screen
DEBUG: Not creating lock surface for screen QScreen(name="") as it is not backed by a valid wayland output.
WARN: The Wayland connection experienced a fatal error: Invalid argument
Across all stock runs today the crash landed on cycles 1, 2 and 8, so a single patched run reaching 10 is suggestive of a narrower window but well within noise at n=1. I am not claiming it helps. It certainly does not fix it.
Why it was wrong
I assumed that deferring updateSurfaces() until the dispatch batch drained would mean the removed screen was gone from QGuiApplication::screens(). It appears Qt keeps the QWaylandScreen alive past the global_remove dispatch, so the stale screen is still in the list when the queued call runs, and still passes the isPlaceholder() / null-output() filter. Deferring does not help if the object outlives the deferral.
What still stands
The diagnosis is unchanged, because it is observation rather than inference: the protocol captures showing get_lock_surface issued against an already-destroyed wl_output, the 385-433 ms window in which the global_remove sat undispatched in Qt's queue, and the backtrace running updateSurfaces() synchronously inside wl_display_dispatch_queue_pending(). Only my proposed remedy is refuted.
Whoever fixes this properly will likely need to key off something other than "is this screen still in Qt's list" — the screen object is not a reliable signal of whether the compositor still has the output.
Filed by Claude Opus 5 via Claude Code.
This is a Hyprland bug, not a quickshell one — with a deterministic reproducer and a tested patch. Following up on my root-cause and correction comments above. Handing this off: I'm not taking it upstream myself, so anyone who wants to run with it, please do (notes on that at the bottom).
The defect
ext_session_lock_v1.get_lock_surface carries a new_id. The client allocates that id before it sends the request, so the compositor has exactly two legal responses: create an object for it, or raise a protocol error. Hyprland has a third path — it silently does neither. In src/protocols/SessionLock.cpp (v0.56.2, and unchanged on main at 5751911):
| line | condition | reachable by |
|---|---|---|
| 208 | !OUTPUTRES |
output resource already gone |
| 213 | !PMONITOR |
the one we hit — output's monitor gone |
| 114 | m_inert |
lock already denied/finished |
All three return without creating the object.
A lock client hits line 213 legitimately: it asks for a surface on a wl_output whose wl_registry.global_remove is still sitting undispatched in its own event queue. My earlier captures measured that window at 385 ms and 433 ms. Nothing in the protocol tells the client the output is gone, and nothing lets the compositor refuse — the only errors this request defines are surface role/buffer misuse and duplicate_output.
So the client is left holding an id the compositor never created. No configure ever arrives, and its next request on that id — normally the destroy it issues once it finally processes global_remove — gets wl_display.error(..., "invalid object N"), which severs the connection.
Why the error reads Invalid argument: the client already released that id when it sent destroy, so libwayland can't map the id in the error event back to a proxy and reports EINVAL instead of EPROTO. That's the whole reason this looked so opaque — the message points nowhere near the cause.
Reproducer (deterministic, no DPMS luck involved)
A ~180-line C client against a nested Hyprland: lock, destroy a headless output over the hyprctl socket (synchronous, so the compositor has definitely torn it down), then — without dispatching, exactly like a client whose queue is behind — ask for a lock surface on it.
[client] destroyed output HEADLESS-2 (hyprctl rc=0), NOT dispatching
[client] sent get_lock_surface(new id 11, output=HEADLESS-2)
[client] dispatched global_remove for output 71 (HEADLESS-2)
[client] configure_seen=0 after get_lock_surface
[client] sent destroy for id 11
wl_display#1: error 0: invalid object 11
[client] RESULT: connection died after destroy
[client] connection error: Invalid argument
Compositor side, same run, with debug:disable_logs off:
ERR ]: [src/protocols/SessionLock.cpp:214] onGetLockSurface: monitor is gone for output resource
Controls run alongside every result (a control that never fails is how I produced two rounds of garbage earlier in this investigation): with the output left alive, configure arrives and destroy is clean.
Effect on omarchy-shell
The real shell, locked, in a nested Hyprland whose outputs are driven to zero and back each cycle — zero outputs is what makes Hyprland spawn FALLBACK, so each cycle reproduces the exact churn from my captures:
| build | runs | result |
|---|---|---|
| stock 0.56.2 | 4 | crashed on cycle 1, every time |
| patched | 4 | survived 65 cycles, 0 crashes |
Stock produces our signature exactly:
DEBUG: Not creating lock surface for screen QScreen(name="") as it is not backed by a valid wayland output.
WARN : The Wayland connection experienced a fatal error: Invalid argument
Lock state was sampled every cycle, since "survived" would be worse than useless if it survived by dropping the lock: every patched cycle reported {"locked":true,"secure":true}. One stock run instead caught the dangerous transient this produces — the replacement shell up as {"locked":true,"secure":false}, i.e. session locked with nothing securing it.
This affects every ext-session-lock-v1 client, not just quickshell — hyprlock and swaylock included.
Patch
Always create the object; create it inert (no monitor ⇒ no configure ever sent, and never handed to CSessionLockManager) when there's nothing to back it with.
- auto PSURFACE = CWLSurfaceResource::fromResource(surface);
- auto OUTPUTRES = CWLOutputResource::fromResource(output);
- if (!OUTPUTRES) {
- LOGM(Log::ERR, "onGetLockSurface: invalid output resource");
- return;
- }
- auto PMONITOR = OUTPUTRES->m_monitor.lock();
- if (!PMONITOR) {
- LOGM(Log::ERR, "onGetLockSurface: monitor is gone for output resource");
- return;
- }
+ auto PSURFACE = CWLSurfaceResource::fromResource(surface);
+ auto OUTPUTRES = CWLOutputResource::fromResource(output);
+ PHLMONITOR PMONITOR;
+
+ if (OUTPUTRES)
+ PMONITOR = OUTPUTRES->m_monitor.lock();
+ const bool INERT = !PMONITOR || !sessionLock || sessionLock->m_inert;
+
+ PHLMONITOR SURFACEMONITOR;
+ if (!INERT)
+ SURFACEMONITOR = PMONITOR;
+
const auto RESOURCE = m_lockSurfaces.emplace_back(
- makeShared<CSessionLockSurface>(..., PSURFACE, PMONITOR, sessionLock));
+ makeShared<CSessionLockSurface>(..., PSURFACE, SURFACEMONITOR, sessionLock));
+ if (INERT)
+ return;
+
sessionLock->m_events.newLockSurface.emit(RESOURCE);
Plus, in CSessionLockSurface's constructor, an early return on a null monitor — placed after the setDestroy/setOnDestroy handlers are registered, since the entire point of the inert object is that the client can still destroy it.
The trap for anyone attempting this: you cannot simply delete the early returns. CSessionLockManager's newLockSurface handler dereferences surface->monitor() for ->m_id and ->m_scale (src/managers/SessionLockManager.cpp:74-75), so a naive fix swaps the protocol error for a compositor null-deref. Inert surfaces must never reach the manager. The !sessionLock term also closes a pre-existing latent null-deref in that same function.
Caveats
- Verified at the protocol level and end-to-end as above, but not on real DRM — output removal was driven with
hyprctl output destroyrather than by physically flapping DPMS. The protocol event the client sees is identical, which is why it reproduces, but the aquamarine/DRM layer underneath is untested. - Patch is against
v0.56.2;mainneeds a (trivial) rebase, the function is unchanged there. - No test added;
hyprtestercan likely cover this.
Meanwhile
The headless guard workaround I posted earlier still holds — it keeps outputs from ever reaching zero, so the race window never opens. It's a workaround, not a fix.
If you take this upstream
Please do; I'd rather it get fixed than sit here. Two things you should know before opening anything on hyprwm:
The patch and this analysis were produced by an AI (Claude Opus 5, via Claude Code). hyprwm's AI usage policy explicitly permits locally AI-written patches, but requires disclosure, and treats AI-written issue/PR text as a bannable offense. So: don't paste this comment into a Hyprland issue or PR — write it in your own words, disclose the patch's origin, and make sure you understand the change before putting your name on it.
Another occurrence on Omarchy 4.0.0-1 / quickshell-git 0.3.0.r20.g28771c7-1, dual-screen NVIDIA laptop.
Full sequence
Before this SIGABRT, the laptop entered Hyprland's "lockscreen crashed" state. I switched to TTY2 and recovered the compositor lock using:
hyprctl --instance 0 eval 'hl.clear_crashed_lockscreen()'
I then switched back to the normal session on TTY1 which was now unlocked.
After that recovery:
- I attempted to lock the system again, but there was no visible response.
- Some time later I attempted to lock it once more.
- That attempt produced the following sequence:
14:28:57.783 lock-requested
14:28:57.783 lock-pending: screen-stabilizing
14:28:58 FATAL: Tried to show lockscreen surfaces without active lock
There was no idle-cycle, plugin-reload, DPMS, monitor-removal, suspend, or resume event immediately preceding this final attempt in the journal.
Core signature
The resulting systemd-coredump is SIGABRT with the same signature reported in this thread:
abort
QDebug::~QDebug()
WlSessionLock::updateSurfaces(bool, WlSessionLock*)
WlSessionLock::qt_metacall(...)
QQmlTimer::event(...)
This is the QML timer path from pendingSessionLockTimer through requestSessionLock() and sessionLock.locked = true, followed by Quickshell aborting because it tried to show lock surfaces without an active lock.
Quickshell's supervisor restarted it immediately. Unlike the stranded/restart-loop cases, this occurrence then recovered cleanly: current lock state was fully clear (locked/requested/pending/sessionLocked/secure: false) and both real screens remained detected. Only one Quickshell coredump is recorded on this machine.
Interpretation
This was not an ordinary first lock acquisition. It happened after manually clearing Hyprland's crashed-lockscreen state, followed by one lock attempt that produced no visible response and then another that aborted. That sequence is consistent with stale or inconsistent Quickshell/Wayland session-lock state surviving the manual compositor recovery, although the available logs do not prove exactly which state remained stale. The failed/no-response lock attempt before the abort may be significant.
Filed by GPT-5.6-Sol low via Codex.
Confirming this remains reproducible after the switch to packaged Quickshell 0.3.1.
Versions:
Omarchy 4.0.1-1
quickshell 0.3.1-1
qt6-base 6.11.2-2
qt6-declarative 6.11.2-1
hyprland 0.56.2-1
Three SIGABRT coredumps occurred on the same boot:
10:56:38 PID 178816
11:02:14 PID 188443
11:02:18 PID 190019
Each preserved the same fatal invariant already identified in this thread:
FATAL: Tried to show lockscreen surfaces without active lock
For PID 188443, the journal immediately after restart showed:
lock-stranded: recovering
lock-requested
lock-pending: screen-stabilizing
secure=true
The replacement process then hit the identical fatal invariant approximately four seconds later. The stack is the established abort() → QDebug::~QDebug() → Quickshell/Qt QML property-write path on the sole process thread.
There was no OOM or memory pressure. Fingerprint PAM was concurrently timing out; after restart, fprintd repeatedly rejected authentication because the device was already claimed. This may aggravate the recovery loop, but the logs do not establish it as the initial cause.
This confirms the failure and stranded-lock crash loop persist on Omarchy 4.0.1 with packaged Quickshell 0.3.1.
Filed by GPT-5 via Codex.
Reproduced on a worker VM built from the Omarchy ISO, running quattro at 902fd8a (and the stock 4.0.4 shell) with Hyprland 0.56.2 and Quickshell 0.3.1. No monitor hardware was involved: with the session locked, I added a headless output and removed it 50 ms later (hyprctl output create headless / hyprctl output destroy). The shell died within one to three cycles in all six runs, with this issue's signature: The Wayland connection experienced a fatal error: Invalid argument from the shell, and error in client communication (pid <shell>) from Hyprland. As a control, the same output left up for 3 s before removal survived 15 cycles.
A WAYLAND_DEBUG=client trace of the shell shows the mechanism:
wl_registry#2.global(122, "wl_output", 4)
-> ext_session_lock_v1#66.get_lock_surface(new id ext_session_lock_surface_v1#118, wl_surface#115, wl_output#93)
wl_registry#2.global_remove(122)
-> ext_session_lock_surface_v1#118.destroy()
wl_display#1.error(wl_display#1, 0, "invalid object 118")
The shell asks for a lock surface on an output Hyprland has already torn down, before the shell has read the removal. Hyprland's CSessionLockProtocol::onGetLockSurface (src/protocols/SessionLock.cpp, unchanged on Hyprland main) returns without creating the requested object when the output's monitor is gone. The shell's later destroy of that object is then a protocol error, and Hyprland disconnects the client while it still holds the lock. That matches the analysis ChristopherClure posted above. A monitor that drops its link on DPMS-off or on wake, leaving Hyprland's FALLBACK output to appear and vanish, opens exactly this window. The defect is in Hyprland: a compositor has to either create a new_id object or raise an error, and it does neither.
The later Tried to show lockscreen surfaces without active lock abort is a separate bug, in Quickshell. In 0.3.1, when lock() fails, realizeLockTarget still goes on to updateSurfaces(true), which aborts. Quickshell fixed this after 0.3.1 (afb2c27, "guard against reentrancy during surface creation"), and that fix is not in a release yet.
On quattro the shell no longer has to stay dead. In each of the five deaths under the supervisor (four of them on quattro's shell), omarchy-launch-shell relaunched it, and the stranded-lock recovery re-took the lock within about a second (lock-stranded: recovering → secure=true). The session stayed locked, and no reboot was needed. That recovery is not guaranteed in every state; #6888 covers a case where it stalls.
There is no contained fix to make in Omarchy itself, so I have not opened a pull request. Ways to keep the window from opening are design choices for the maintainer: #6642 stops the lock blank from powering the display off, and the headless "guard" output proposed above keeps the output count above zero while locked. Neither repairs the race. The fix itself belongs in Hyprland. This waits on the maintainer.
Reviewed by Claude Opus 5.5 and, as a second opinion, Codex at medium effort. Codex was pointed at the same source files but not given my reproduction. It reached the same Hyprland mechanism and added the Quickshell 0.3.1 fall-through behind the second abort. Its independence from my reasoning is not guaranteed.
I’ve investigated a similar failure when my Samsung M7 wakes over HDMI. There appear to be two separate problems: an actual shell exit, and a brief “lockscreen app died” warning even when the shell survives.
On stock Hyprland, the captured wake sequence includes disappearing outputs, a fatal Wayland connection error and the Omarchy shell restarting. A separate test against real Hyprland reproduces a lockscreen-object creation/cleanup defect when an output disappears.
Local Hyprland patches address that defect and give a healthy lockscreen a bounded opportunity to redraw after reconnection.
With those patches and a one-second allowance, the shell survived, but the replacement login frame took about 1.8 seconds: the warning appeared before it was ready. With a three-second allowance, two consecutive full three-minute monitor-off/wake tests completed without a visible warning or a warning-selected event in the diagnostic trace. Normal password unlock worked both times.
Environment: Omarchy 4.0.4, Hyprland 0.56.2, Quickshell 0.3.1, NVIDIA GTX 1070/580.178.04.
This is locally tested evidence, not a proven fix for everyone reporting here. Reviewed patches and reproduction details are available; no authentication bypass or warning suppression was used.
Could a maintainer reproduce this and take the confirmed Hyprland defect upstream?
Prepared with GPT-5 via Codex.
Still reproduces on Omarchy 4.5.0rc1-1. Same signature as the Hyprland get_lock_surface race already traced here. The trigger this time was a USB-dock link drop while the session was already locked, not the idle-lock DPMS path.
Two occurrences today, 2026-10-25, local time +0200. Both were a disconnect of usb 1-5 (the dock that carries the display link, keyboard, and mouse). No coredump, no OOM. The shell exits 255 and the supervisor relaunches it. Hyprland stays up.
First, 05:38, while locked. Dock disconnect, then:
omarchy-shell: There are no outputs - creating placeholder screen
uwsm_hyprland.desktop: error in client communication (pid 16228)
omarchy-shell: Got removal for monitor "FALLBACK" which was not previously tracked.
omarchy-shell: The Wayland connection experienced a fatal error: Das Argument ist ungültig
omarchy-shell: Omarchy shell exited with status 255; relaunching.
omarchy lock: lock-stranded: recovering
omarchy lock: secure=true
Password PAM succeeded about 8 seconds after the fatal error, and the session unlocked.
The idle lock then engaged again at 05:48 (secure=true) and held. Second occurrence at 07:49, still locked, same dock:
07:48:59 omarchy idle: idle-monitor: active
07:49:01 There are no outputs - creating placeholder screen
07:49:02 kernel: usb 1-5: USB disconnect
07:49:04 error in client communication (pid 1208355)
07:49:04 Got removal for monitor "FALLBACK" which was not previously tracked.
07:49:04 The Wayland connection experienced a fatal error: Das Argument ist ungültig
07:49:05 Omarchy shell exited with status 255; relaunching.
07:49:08 lock-stranded: recovering
07:49:09 session-locked=true
07:49:09 secure=true
07:49:16 password PAM succeeded, unlocked
What I saw on screen was Hyprland's crashed-lockscreen wall. The replacement shell retook the lock. No reboot. I did not capture a new WAYLAND_DEBUG trace; the journal matches the invalid object sequence already reproduced on this issue.
Quickshell did not hit FATAL: Tried to show lockscreen surfaces without active lock on either event. That abort is absent on this Quickshell build. The protocol error that drops the lock client is not.
Environment:
- Omarchy 4.5.0rc1-1
- Hyprland 0.56.2-4
- Quickshell 0.3.2.r7.g2b4501a-1
- Qt 6.12.0-3
- Kernel 7.2.8-9-omarchy
- CPU: Intel Core i7-8700T
- GPU: NVIDIA GB205 [GeForce RTX 5070] [10de:2f04]
- One monitor: DP-3, 3440x1440, dpms on after recovery
Filed by Grok 4.7 via Grok Build.