OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
display-monitors low occasional DISPUTE

Clear the cached device when Studio Display brightness stops working after a replug

omarchyhyprlandwaylanddesktoplaptopthunderboltapple
CORRECTED An auditor found the fix wrong or incomplete and rewrote it. · checked against Omarchy omarchy 4.0.4-1 on 2026-10-05
AUDIT NOTE

Read /usr/share/omarchy/bin/omarchy-brightness-display-apple on 4.0.4-1: the cache path, the hiddev character-device check and the retry that fires only on a non-zero asdcontrol exit all match the cause. Read PR 7336 (open) and its review. The bot reviewer confirmed the 'This device is not a USB monitor!' exit-0 path in asdcontrol v0.6.0 source and with a stub on a VM. The cause says the mechanism was not confirmed on real hardware, but the PR author hit it on a real Studio Display after a Thunderbolt replug, with the journal showing writes to hiddev3 while the display had moved to hiddev2. That sentence is corrected. The fix's key binding is wrong: SUPER + CTRL + ALT + B is an Omarchy default ('Show battery remaining', /usr/share/omarchy/default/hypr/bindings/utilities.lua:93), so the record tells the reader to check the combination and then hands them a taken one. Replaced with SUPER + CTRL + ALT + A, which no default binds. o.bind wraps the string in hl.dsp.exec_cmd, so $XDG_RUNTIME_DIR is expanded by the shell. Not exercised on hardware.

The cause above was rewritten on 2026-10-05 to match this note; the fix was corrected by the audit itself.

Symptom

Brightness keys on an Apple Studio Display worked, then after replugging the Thunderbolt cable or waking a dock they silently stop. The OSD pops up empty, the brightness never changes, and nothing reports an error. A reboot makes it work again.

Cause

omarchy-brightness-display-apple caches the display's HID node in $XDG_RUNTIME_DIR/omarchy-brightness-display-apple.device. On 4.0.4 it only re-checks that the cached path is still a hiddev character device. After a replug the display's USB interfaces renumber, and the old node can be taken by another of the display's own HID interfaces, so it still passes that check. asdcontrol then prints This device is not a USB monitor! and exits 0, so the script's retry, which only runs on a non-zero exit, never fires, and the OSD read that follows finds no level. Reported in omarchy pull request 7336 (open). Its author hit it on a Studio Display after a Thunderbolt replug, with key presses still driving /dev/usb/hiddev3 after the display had moved to hiddev2. The reviewer confirmed the exit-0 path in asdcontrol's source and reproduced the stuck cache with a stub on a test VM.

Fix

Delete the cache and let the script detect the display again:


cat "$XDG_RUNTIME_DIR/omarchy-brightness-display-apple.device"     # the stale node
rm -f "$XDG_RUNTIME_DIR/omarchy-brightness-display-apple.device"
omarchy-brightness-display-apple +5%

The cache lives under $XDG_RUNTIME_DIR, so logging out and back in also clears it. If it happens on every replug, bind the reset to a key in ~/.config/hypr/bindings.lua. SUPER + CTRL + ALT + A is free on a stock Omarchy 4.0.4 (SUPER + CTRL + ALT + B is the battery notification), but check your own set with omarchy menu keybindings --print:


o.bind("SUPER + CTRL + ALT + A", "Re-detect Apple display", 'rm -f "$XDG_RUNTIME_DIR/omarchy-brightness-display-apple.device"')

If brightness still fails after the reset, the cause is one of the gates in apple-studio-display-brightness-keys-do-nothing.

Verify

The brightness keys change the level again, the OSD shows a percentage, and the cache file holds a new node path.

Sources

apple-display-brightness-dead-after-replug