Bug 468295 - 5.27.4 Night color remains on at sunrise, can't disable
Summary: 5.27.4 Night color remains on at sunrise, can't disable
Status: RESOLVED DUPLICATE of bug 461657
Alias: None
Product: kwin
Classification: Plasma
Component: general (show other bugs)
Version: 5.27.6
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-08 16:28 UTC by Evan
Modified: 2023-08-02 09:43 UTC (History)
10 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 Evan 2023-04-08 16:28:09 UTC
SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***

If automatic night color schedule is enabled, sometimes it remains enabled when it is supposed to be turned off (at sunrise). The tray icon hides like plasma thinks its disabled but the filter is still on. Trying to toggle night color off via the tray icon or in system settings does nothing, night color filter remains on until re-logging.

This has happened twice on 2 different systems and distros since upgrading to 5.27.4, both times the systems were either suspended or screen offed. That may have something to do with it. Doesn't always happen.

STEPS TO REPRODUCE
1. Enable night color automatic switching times based on sunrise/sunset
2. Use system at night so night color is enabled automatically
3. Put system in suspend / screen off until sunrise (unsure if needed)
4. Wake computer, night color is still enabled with no way to disable

OBSERVED RESULT
Night color is still enabled and can't be disabled

EXPECTED RESULT
Night color is toggled off

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Arch Linux and Fedora Kinoite 37
(available in About System)
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.104.0
Qt Version: 5.15.8

ADDITIONAL INFORMATION
Comment 1 Evan 2023-04-15 17:06:08 UTC
Update: When night color won't disable, changing the night color temperature in system settings then exiting without saving fixes it until the next night/day cycle.
Comment 2 BKMO 2023-04-24 18:13:53 UTC
When the system resumes from sleep after sunrise night color is off but remains in the sunset NIGHT setting. Toggling the color in systemsettings will return it to the proper daytime color.

Arch Linux 5.27.4
Comment 3 Ray Leon 2023-05-21 18:37:46 UTC
Clicking anywhere on the "Night color temperature" slider in System Settings (and then closing without saving) also seems to reset it.
Comment 4 Ray Leon 2023-05-21 18:39:03 UTC
(In reply to Ray Leon from comment #3)
> Clicking anywhere on the "Night color temperature" slider in System Settings
> (and then closing without saving) also seems to reset it.

Should've read more than the last comment. Sorry for the duplicate lol
Comment 5 restuccia 2023-05-26 08:45:16 UTC
I encounter the same problem on my conf, and the fix via the slider in the settings also works for me.

Operating System: Fedora Linux 38
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.106.0
Qt Version: 5.15.9
Kernel Version: 6.2.15-300.fc38.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 4 × Intel® Core™ i5-6200U CPU @ 2.30GHz
Memory: 7,6 GiB of RAM
Graphics Processor: Mesa Intel® HD Graphics 520
Comment 6 hexchain 2023-06-19 04:06:18 UTC
Same issue. I think if the screen is off (DPMS) when it reaches the Night Color switching time, the switching wouldn't happen.
Comment 7 jade 2023-07-15 22:31:23 UTC
See also (possible duplicate): https://bugs.kde.org/show_bug.cgi?id=461657
Comment 8 Vlad Zahorodnii 2023-07-25 09:51:49 UTC
Can you please post the output of `qdbus org.kde.KWin /ColorCorrect GetAll org.kde.kwin.ColorCorrect` when screen color temperature is incorrect? Please also specify the expected screen temperature
Comment 9 Nate Graham 2023-07-25 13:42:41 UTC
.
Comment 10 hexchain 2023-07-25 15:32:18 UTC
The output when night color should be active but it isn't:
~ % qdbus org.kde.KWin /ColorCorrect GetAll org.kde.kwin.ColorCorrect
available: true
currentTemperature: 6500
enabled: true
inhibited: false
mode: 2
previousTransitionDateTime: 1690236000
previousTransitionDuration: 60000
running: true
scheduledTransitionDateTime: 1690298220
scheduledTransitionDuration: 60000
targetTemperature: 6500
~ % date +%s
1690298743

After changing one of the color temperature sliders once without saving:
% qdbus org.kde.KWin /ColorCorrect GetAll org.kde.kwin.ColorCorrect
available: true
currentTemperature: 4500
enabled: true
inhibited: false
mode: 2
previousTransitionDateTime: 1690298220
previousTransitionDuration: 60000
running: true
scheduledTransitionDateTime: 1690322400
scheduledTransitionDuration: 60000
targetTemperature: 4500


The following reproducer worked for me:

1. Set switching times to custom times, and begin time to a few minutes later;
2. Set transition duration to 1 minute;
3. Apply. Night color should be inactive at this point;
4. Lock screen and press Esc to enter DPMS;
5. Wait till begin time + a few minutes later;
6. Wake up the screen and notice that night color isn't active as it should be.
Comment 11 Evan 2023-07-26 14:37:42 UTC
Slightly different command output when night color should be inactive but is not (day). Command output is the same before and after clicking on the night color temp slider.

Configured settings:
switching times: switch at sunrise/sunset
day temp: 6500K
night temp: 3200K

Before: night color filter is visibly ON but settings say it should be off

╰─ qdbus org.kde.KWin /ColorCorrect GetAll org.kde.kwin.ColorCorrect
available: true
currentTemperature: 6500
enabled: true
inhibited: false
mode: 0
previousTransitionDateTime: 1690361907
previousTransitionDuration: 2992668
running: true
scheduledTransitionDateTime: 1690415773
scheduledTransitionDuration: 2992669
targetTemperature: 6500

After: Clicking the "night color temperature" slider at 3200K (where it was already at before), which causes the visible night filter to go away.

╰─ qdbus org.kde.KWin /ColorCorrect GetAll org.kde.kwin.ColorCorrect
available: true
currentTemperature: 6500
enabled: true
inhibited: false
mode: 0
previousTransitionDateTime: 1690361907
previousTransitionDuration: 2992668
running: true
scheduledTransitionDateTime: 1690415773
scheduledTransitionDuration: 2992669
targetTemperature: 6500
Comment 12 Ilya Bizyaev 2023-07-28 10:32:28 UTC
I also get the same output before and after the workaround when night color gets stuck at daytime:

available: true
currentTemperature: 6500
enabled: true
inhibited: false
mode: 0
previousTransitionDateTime: 1690513628
previousTransitionDuration: 3402645
running: true
scheduledTransitionDateTime: 1690569498
scheduledTransitionDuration: 3402646
targetTemperature: 6500
Comment 13 Zamundaaa 2023-08-02 09:43:43 UTC

*** This bug has been marked as a duplicate of bug 461657 ***