Bug 482054 - Monitor sleep and black screen on screen lock and after unlocking on X11
Summary: Monitor sleep and black screen on screen lock and after unlocking on X11
Status: RESOLVED DUPLICATE of bug 481308
Alias: None
Product: kscreenlocker
Classification: Plasma
Component: general (show other bugs)
Version: 6.0.0
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: qt6
Depends on:
Blocks:
 
Reported: 2024-02-29 16:26 UTC by Nelson
Modified: 2024-03-03 19:30 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nelson 2024-02-29 16:26:58 UTC
SUMMARY
After updating to KDE 6, when I lock the screen, either manually with the hotkey or letting it happen after the set time, the monitor goes into sleep mode. If I move the mouse, the monitor wakes up and I can see the cursor on a black screen. The controls are there and the cursor changes to the text cursor where the password field is supposed to be. 

Entering the password unlocks the screen, but the monitor again goes into sleep mode. After moving the cursor, it wakes up and I'm on a black screen on the desktop where the cursor changes upon hovering over windows and such, as if everything is there, but anything that's not the mouse cursor is black. 

It seems pressing some keys affects this issue, as pressing meta on the lock screen makes the image come back after ~5-10 seconds.
Same with unlocking, where triggering the overview feature or pressing meta, which opens the menu, bring the image back. These workarounds, however, don't prevent the monitor from going into sleep mode when lock is triggered or unlocked, as mentioned above.

STEPS TO REPRODUCE
1. Let the screen lock itself or do it manually with the hotkey
2. Move the cursor or press a key to wake up the monitor

OBSERVED RESULT
The monitor goes into sleep mode instead of showing the lock screen.
After waking up, there's a black screen with only the cursor visible.
Upon unlocking, monitor sleeps again and wakes up to black, unlocked screen.

EXPECTED RESULT
Monitor does not sleep when locking the screen.
Can see lock screen.
Monitor does not sleep after unlocking.
Can see desktop right away.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Neon
KDE Plasma Version: 6.0.0
KDE Frameworks Version: 6.0.0
Qt Version: 6.6.2

ADDITIONAL INFORMATION
I tested this on Wayland and it does not happen.
This did not happen on KDE 5.27 on X11 either.
Disabling and re-enabling compositing with alt+shift+F12 does return the screen to normal immediately, but after ~10 seconds, there's a fading-from-black effect as if the screen had been black just the same.
Moving the cursor to a corner to trigger overview does bring the image back, but it's promptly taken away, and only remains after a few tries (probably while the ~10 seconds are elapsing).
Comment 1 han0522 2024-03-01 00:52:51 UTC
Can confirm this bug is happening for me as well.

Just updated to KDE6 yesterday. Using X11 (can't change to wayland due to work app).

Locking through inactivity or manually locking causes screen to go black, only cursor visible. If I type in my password it will log in but remain as a black screen. Triggering Overview (I have it set to one of the screen edges) will show my desktop and any windows I have open. Clicking on a window causes the screen to go black. This cycle (triggering overview, clicking on a window, screen goes black) stops eventually after ~10 seconds and the screen remains on.

It appears as though this happens when the screen dims due to inactivity as well.

I'm using a Dell XPS 9310.

Here is my syslog generated around the same time my screen dimmed which triggered this issue:

Feb 29 18:20:51 han0522-dell dbus-daemon[1218]: [system] Activating service name='org.kde.powerdevil.backlighthelper' requested by ':1.387' (uid=1000 pid=14036 comm="/usr/lib/x86_64-linux-gnu/libexec/org_kde_powerdev" label="unconfined") (using servicehelper)
Feb 29 18:20:51 han0522-dell org.kde.powerdevil.backlighthelper: Detected locale "C" with character encoding "ANSI_X3.4-1968", which is not UTF-8.#012Qt depends on a UTF-8 locale, and has switched to "C.UTF-8" instead.#012If this causes problems, reconfigure your locale. See the locale(1) manual#012for more information.
Feb 29 18:20:51 han0522-dell dbus-daemon[1218]: [system] Successfully activated service 'org.kde.powerdevil.backlighthelper'
Feb 29 18:20:53 han0522-dell kernel: [24295.690123] workqueue: set_brightness_delayed hogged CPU for >10000us 8 times, consider switching to WQ_UNBOUND
Feb 29 18:21:11 han0522-dell plasmashell[13974]: kf.service.services: KApplicationTrader: mimeType "x-scheme-handler/file" not found

Not sure what other information to provide.
Comment 2 pmargeti34 2024-03-01 02:36:35 UTC

*** This bug has been marked as a duplicate of bug 481308 ***
Comment 3 Nelson 2024-03-01 11:14:01 UTC
(In reply to pmargeti34 from comment #2)
> 
> *** This bug has been marked as a duplicate of bug 481308 ***

For what it's worth, I see one difference with the bug this has been marked a duplicate of, and that's that the other user's monitor does not seem to go into sleep mode when locking nor unlocking.

That might be related to the monitor, but it wasn't the observed behavior when locking the screen up to 5.27. I would just see the lock screen.