Bug 448275 - All qt apps are freezed/crashed after screen wake up
Summary: All qt apps are freezed/crashed after screen wake up
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 5.23.5
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
: 450679 (view as bug list)
Depends on:
Blocks:
 
Reported: 2022-01-11 17:50 UTC by Artur Rudenko
Modified: 2022-06-24 08:38 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Video recording (obs source freezed after screen dimming) (2.24 MB, video/mp4)
2022-01-11 17:53 UTC, Artur Rudenko
Details
Dolphin output with WAYLAND_DEBUG=1 (552.76 KB, text/plain)
2022-02-09 09:39 UTC, Yannick
Details
Dolphin unresponsive (58.78 KB, image/png)
2022-02-09 09:43 UTC, Yannick
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Artur Rudenko 2022-01-11 17:50:02 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
***
Sorry, don't know if I should debug kscreen/kwin or not, but I tried to run qt python application in debug mode with no luck (it just shows exit code 1)

After monitor wake up literally every qt app is freezing for a few seconds then crashing when I do some input to them. Gtk apps aren't affected

STEPS TO REPRODUCE
1. Set monitor to switch off after 1 minute
2. Open some qt apps like dolphin or system settings
2. Let monitor sleep
3. Wake up

OBSERVED RESULT
All qt apps crashed

SOFTWARE/OS VERSIONS
Windows:
macOS:
Linux/KDE Plasma:
(available in About System)
KDE Plasma Version: KDE 5.23.5
KDE Frameworks Version: 5.90
Qt Version: 5.15.2

ADDITIONAL INFORMATION
Single 2560x1440 144hz monitor, wayland only, amd gpu (rx470)
Comment 1 Artur Rudenko 2022-01-11 17:53:14 UTC
Created attachment 145333 [details]
Video recording (obs source freezed after screen dimming)
Comment 2 Yannick 2022-02-05 09:59:32 UTC
I have the exact same issue.
Not all Qt apps are affected though, VLC for example is still responsive after the monitor wakes up.
It looks like only KDE apps are affected.
Comment 3 Vlad Zahorodnii 2022-02-07 10:05:55 UTC
Can you get the backtrace of a crashing app? Also could you please capture the output of such an app while it runs with the WAYLAND_DEBUG=1 environment variable set? it may require ssh'ing from another computer
Comment 4 Yannick 2022-02-09 09:39:18 UTC
Created attachment 146484 [details]
Dolphin output with WAYLAND_DEBUG=1

Here is the output of Dolphin 21.12.2 with the WAYLAND_DEBUG=1 environment variable set, after turning off then on a DisplayPort monitor.

The output is very large, I suppose it starts to be relevant at line 1018: "qt.qpa.wayland: Creating a fake screen in order for Qt not to crash"

GPU: AMD RX560 (with Mesa 21.3.5)
Plasma version: 5.24.0
Frameworks version: 5.90.0
Distribution: Archlinux
Comment 5 Yannick 2022-02-09 09:43:48 UTC
Created attachment 146485 [details]
Dolphin unresponsive

KDE apps such as Dolphin, Yakuake (when it is visible) or System Settings, etc. no longer seem to crash, but they become unresponsive for a while after the screen wakes up (the window is greyed out, as in the screenshot attached).
After a minute or so the applications can be used normally again.
Comment 6 Antoine Gatineau 2022-02-18 14:24:43 UTC
I am having the same issue. Freeze of kde apps, Konsole and Kontact mainly as they are often visible but no crash for me.
GPU: AMD RX 5700 XT (with Mesa 21.3.6)
Plasma version: 5.23.5/5.24.0/5.24.1
Frameworks version: 5.90.0/5.90/5.91
Distribution: Fedora 35

On another laptop I don't experience that. It has an Intel gpu, maybe it is linked.
Where I have the issue, I also have steam installed with all the i686 dependencies. Maybe linked too...

Tell me if I can help with debugging
Comment 7 Yannick 2022-03-13 14:02:02 UTC
It looks like it's fixed on my end now!
It may be related to the Plasma 5.24.3 or Qt 5.15.3 updates.
Comment 8 Nate Graham 2022-03-13 15:26:56 UTC
Oh great!
Comment 9 Antoine Gatineau 2022-03-14 08:51:21 UTC
(In reply to Yannick from comment #7)
> It looks like it's fixed on my end now!
> It may be related to the Plasma 5.24.3 or Qt 5.15.3 updates.

It must be the QT 5.15.3 patch that fixes the issue. In fedora, the patch hasn't landed and with plasma 5.24.3 and qt 5.15.2, I still have the issue.
Waiting for the qt patch to land :)
Comment 10 Nate Graham 2022-05-12 16:56:53 UTC
*** Bug 450679 has been marked as a duplicate of this bug. ***
Comment 11 Shmerl 2022-06-12 07:21:14 UTC
Looks like Debian unstable / testing is *finally* getting newer Qt, so this nasty bug will hopefully be fixed:

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1007170
Comment 12 Shmerl 2022-06-24 08:38:17 UTC
Debian testing finally after a huge wait got a newer Qt  (5.15.4) and this bug is gone!