Created attachment 697023 [details] Callstack of the crash. Hi! Some Qt applications seem to have random crashes with qtwayland-5.15.2-r1. Those random crashes occur mostly when the application receives focus. Reproduction steps: 1) Install Sway (or any other Wayland compositor, really) 2) Install Clementine (or any other Qt application) 3) Have the application open, and wait. Sometimes focus it. 4) Observe that after a couple of minutes to hours the Qt application will crash upon receiving focus. The error message shown is simply "ERROR unknown The Wayland connection broke. Did the Wayland compositor die?" For good measure, I've attached a callstack to this bug report. This bug has also been reported to the Clementine developers here: https://github.com/clementine-player/Clementine/issues/6595 A very similar callstack has been reported for qbittorrent as well: https://github.com/qbittorrent/qBittorrent/issues/13216 I might be misreading the source code and call stacks, but to me it seems this bug has been fixed upstream: https://github.com/qt/qtwayland/commit/16760280fd04cf70255bab16d9acecad254fdd8f I've added this commit as a user patch on my system, and since then no Qt applications have crashed. However I've only done this a few hours ago, and with the crash being random, there's no guarantee that it isn't a coincidence. Best Regards, Andreas
I indeed misread the issue, the linked github patch does not resolve the problem. However there is a bugreport for Sway upstreamed, that might have a solution people claimed working: https://github.com/swaywm/sway/issues/4506
You could try with this patch applied to qtwayland: https://invent.kde.org/qt/qt/qtwayland/-/commit/9ee2ea141adc7765f6c212e63839ef23a4494b30
9ee2ea141adc7765f6c212e63839ef23a4494b30 just changes the severity of the error to warning, but still terminates the program. https://github.com/swaywm/sway/issues/4506#issuecomment-778666954 supplies a patch for the issue, and since I put that into the user patches folder for qtwayland, I haven't seen a single qt application crash and gotten quite a few hours uptime with clementine constantly running, so I'm reasonably confident that this indeed prevents the crashes. By the way, there is also an upstream bug report at qt: https://bugreports.qt.io/browse/QTBUG-81504
This sounds relevant, and it applies cleanly at least: https://invent.kde.org/qt/qt/qtwayland/-/commit/93058de8d7e7c2f320c22b3bd898aa06cf5babcd
Please test with latest available version in tree.