Bug 493612 - Night Light fails to activate when displayport monitors go to sleep triggering hotplug
Summary: Night Light fails to activate when displayport monitors go to sleep triggerin...
Status: REPORTED
Alias: None
Product: kwin
Classification: Plasma
Component: night color (show other bugs)
Version: 6.1.5
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-25 00:47 UTC by Eric Parker
Modified: 2024-09-25 20:48 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Parker 2024-09-25 00:47:48 UTC
SUMMARY

If the monitors turn off for any reason, night light will fail to activate. This is because of Displayport "hotplug", where sleeping displayport monitors are treated as unplugged.



STEPS TO REPRODUCE
1. Turn off a displayport monitor before Night Light's activation time.
2. Turn it on after activation, it doesn't activate.

OBSERVED RESULT

Night Light never triggers

EXPECTED RESULT

Night light should work normally.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 6.10
KDE Plasma Version: 6.15
KDE Frameworks Version: 6.6
Qt Version: 6.7.2

ADDITIONAL INFORMATION
This can probably be fixed by checking night light status whenever a monitor is plugged or unplugged.
Comment 1 Eric Parker 2024-09-25 00:55:47 UTC
From looking at the codebase, this could probably be fixed by adding a check for monitor plug similar to how the suspend check works? https://invent.kde.org/plasma/kwin/-/blob/master/src/plugins/nightlight/nightlightmanager.cpp
Comment 2 Nate Graham 2024-09-25 20:48:47 UTC
Interesting, would you like to submit a patch?