Bug 456625

Summary: New rewritten Kwin results in TOTAL plasma/keyboard/mouse clicks FREEZE (Reproducible)
Product: [Plasma] kwin Reporter: John <kdelovaa>
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: major CC: kde, nate
Priority: NOR    
Version First Reported In: 5.25.2   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description John 2022-07-12 14:40:32 UTC
SUMMARY
This bug is way too nasty :(
Some people have hard time to reproduce it and reporting it. I figured out how to freeze KDE Plasma every time. (reproducable KDE Freeze). After invesigation I did it a few times and KDE freezes totally every time.

What happens:
Keys on keyboard are intercepted you can't use mouse to close a window. You can't restart system because keyboard DEOSN'T (ctrl+alt+del to see logout/shutdown menu) RESPOND, you can't go through new start menu: you can open it but clicking shutdown/restart (& small button to logout) DOES NOT work. Nothing is clickable. Connecting new mouse instead of using touchpad doesn't help at all. Its the same effect. Can't use keyboard either. 


It MAY BE (not sure) similar to bug:
https://bugs.kde.org/show_bug.cgi?id=420157
and maybe fee other random freezes reported here, that are very difficult to track it down.

==> I figured out what the cultprit is. Here are the steps to fully reproduce it:

1. Fresh login
2. open these apps: Kate, meta+E, Konsole, gimp, falkon, firefox (use krunner to do it quickly)
3. Use alt+tab intensively to be sure, until you get Kate again (also use arrows this way and other way)
4. Click "Restore" (next to close and minimize, aka unmaximize)
5. use alt+right click inside Kate. Click white space in Kate to clear this context menu.  Now, use Meta+ (fn) PgUp to maximize window.
6. Now try to type in Kate.
7. Now try to close kate, try to use alt+tab, try to restart the system either using ctrl+alt+del to get you to the shutdown/logout screen or try to shutdown via start menu. Total freeze. You have to hard reset the whole computer.

THE CULPRIT IS THE SHORTCUT META+PgUP to maximize window. So far I have no freezes after deleting the shortcut and changing it to ... META+M. (I know its weired...).

This is a nasty bug. If someone has freezezes, can't click intercepted, keyboard (on non exotic graphics, xorg,libinput, etc.) they can try deleting this shortcut and maybe alt+tab and everyghing will be OK. So far so good on my system.


Technical info:
This is not nvidia nor AMD APU. nor wayland. Its pure intel skylyke, generic, xorg, libinput and latest updated arch. It happens on the few last iterations of KDE after kwin rewrite regardless of alt+tab plugins present or not, regardless of which plugins for alt+tab used (now a separate library to get cover or flip switch, happens on breeze too without plugins).


OBSERVED RESULT


EXPECTED RESULT
NO Freezes, keboard freeze, libinput freeze with new rewritten Kwin.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: Arch
(available in About System)
KDE Plasma Version: Few last iterations: ..., 5.22, 5.23
KDE Frameworks Version: Few last iterations, 5.9x, ..., 5.96
Qt Version: 5.15.5

ADDITIONAL INFORMATION
Pure Intel Skylyke, Xorg, libinput, No nvidia, no wayland, no AMD APU.
Comment 1 John 2022-07-12 14:49:41 UTC
Meta+PgUp and Meta+Right Click to rezise seem to be the culprit of total freeze. Just chaning shortcuts did not help. Happens with new shortcut too :(.
Comment 2 John 2022-07-12 15:34:51 UTC
Update [too bad I cannot edit the previous post]: I narrowed it down:
1. Open Kate
2. Unmaximize Kate
3. Use "Meta + Right Click" to resize windows a few times (diagonally, not horizontal). Leave it unmaximized.
4. Type something in Kate plus some spaces "ggg    "
5. Use Alt+Tab a few times
5. Now press Meta (+Fn) + PgUP
6. Try Alt+Tab or closing Kate. Try to shutdown the computer any way you want.

Its the weirdes thing ever.
Comment 3 Nate Graham 2022-07-13 19:30:37 UTC
Cannot reproduce on X11 or Wayland with any of those steps FWIW. It's an extremely odd sequence of events to cause such a bug.
Comment 4 Marc Deop 2023-02-22 14:12:06 UTC
(In reply to Nate Graham from comment #3)
> Cannot reproduce on X11 or Wayland with any of those steps FWIW. It's an
> extremely odd sequence of events to cause such a bug.

I cannot reproduce either on Fedora 37 with Plasma 5.27.1

Nvidia 1070
Comment 5 Nate Graham 2023-02-22 21:03:30 UTC
Are you able to reproduce the issue on Plasma 5.27, John>
Comment 6 Bug Janitor Service 2023-03-09 03:45:34 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 7 Bug Janitor Service 2023-03-24 03:45:39 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!