Bug 427778 - Screen not locked when app is being dragged on panel when the machine is put to sleep
Summary: Screen not locked when app is being dragged on panel when the machine is put ...
Status: RESOLVED UPSTREAM
Alias: None
Product: kscreenlocker
Classification: Plasma
Component: general (show other bugs)
Version: unspecified
Platform: Kubuntu Linux
: NOR major
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-10-15 20:52 UTC by 24805860-1f42-4b27-a791-b8da26894c83
Modified: 2021-06-21 22:44 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Screen not locked after sleep (1.50 MB, video/webm)
2020-10-15 20:52 UTC, 24805860-1f42-4b27-a791-b8da26894c83
Details

Note You need to log in before you can comment on or make changes to this bug.
Description 24805860-1f42-4b27-a791-b8da26894c83 2020-10-15 20:52:26 UTC
Created attachment 132398 [details]
Screen not locked after sleep

SUMMARY
If the computer goes to sleep while an app is being dragged on the panel then at wake time the screen will not be locked.

STEPS TO REPRODUCE
1. Set Energy Saving setting so "When power button pressed" action is to sleep.
2. Open an app, eg Dolphin
3. Drag the app on the panel, as done to rearrange order of apps on the panel.
4. Put the computer to sleep, eg by pressing the power button (requires power settings to sleep the computer)
5. Wake the computer later by pressing a key.

OBSERVED RESULT
Desktop is available for use.

EXPECTED RESULT
Lock screen should be shown. Password should be required.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Kubuntu 20.04
KDE Plasma Version:  5.18.5
KDE Frameworks Version: 5.68.0
Qt Version: 5.12.8

ADDITIONAL INFORMATION
Video made with VirtualBox attached.

Also seen on openSuse Leap 15.2 in VirtualBox.

Have had several times where my laptop (native, not in VirtualBox) does not require the password when waking from sleep. Perhaps it's because I have a touchscreen and have the panel at the top of the screen.  It may be that I accidentally touch the top of the screen when closing the laptop.  Or perhaps a firm closure triggers a screen press, maybe the keyboard touches the screen briefly, before sleep occurs. 

The description above, about the item on the panel, is a re-creatable example I have found when trying to understand the problem. There may be other ways to trigger to this bug.
Comment 1 Nate Graham 2021-06-21 22:43:44 UTC
Can confirm on X11; probably the drag is blocking other stuff while it happens. The same thing happens if a context menu is open when the system is supposed to lock.

Unfortunately these are unfixable bugs on X11. They are not present on Wayland.
Comment 2 David Edmundson 2021-06-21 22:44:38 UTC
>The same thing happens if a context menu is open when the system is supposed to lock.

I can confirm it's the same bug on a technical level - a mouse grab