Bug 455913 - [Wayland + Nvidia] Plasma popups (e.g. Kickoff and KRunner) sometimes stops showing after opening / closing them a few times
Summary: [Wayland + Nvidia] Plasma popups (e.g. Kickoff and KRunner) sometimes stops s...
Status: RESOLVED UPSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 5.91.0
Platform: Arch Linux Linux
: VHI grave
Target Milestone: ---
Assignee: Alexander Lohnau
URL:
Keywords: wayland
: 477028 477762 479087 479723 479766 479865 479947 480101 480153 480559 480617 480786 480806 480813 (view as bug list)
Depends on:
Blocks:
 
Reported: 2022-06-25 11:06 UTC by qlum
Modified: 2024-02-14 14:20 UTC (History)
39 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
krunner log when it dissapears (242.27 KB, text/x-log)
2023-12-08 19:15 UTC, Dmitrii Chermnykh
Details

Note You need to log in before you can comment on or make changes to this bug.
Description qlum 2022-06-25 11:06:47 UTC
SUMMARY
Specifically on Wayland using an Nvidia GPU Krunner will not show, after toggling it a few times (it will show a maximum of 3 times). 

The issue does not occur on 2 other machines using Intel IGP's.
The issue does not occur on X11.
I can confirm the issue also occurred on 5.25.0 but have not tested older versions as Nvidia + wayland was not really usable before 5.25 for me at least.
I saw someone comment my exact issue on this bug: https://bugs.kde.org/show_bug.cgi?id=454671
But the bug itself describes a different issue.

STEPS TO REPRODUCE
1. open Krunner with a keyboard shortcut (ALT+Space in my case)
2. close Krunner either by clicking on something else or by using ALT+Space
3. open Krunner again
4. close Krunner
5. open Krunner
6. close Krunner
7. open Krunner (krunner will no longer show)

Aditional info:
running kKunner from command line, I get the following:
When launching: 
qt.qpa.wayland: Wayland does not support QWindow::requestActivate()

The second time opening after closing: 
QCommandLineParser: argument list cannot be empty, it should contain at least the executable name
kf.plasma.quick: Couldn't create KWindowShadow for View(0x7ffee8a255d0)
kf.plasma.quick: Couldn't create KWindowShadow for View(0x7ffee8a255d0)
kf.plasma.quick: Couldn't create KWindowShadow for View(0x7ffee8a255d0)
kf.plasma.quick: Couldn't create KWindowShadow for View(0x7ffee8a255d0)
qt.qpa.wayland: Wayland does not support QWindow::requestActivate()

Third time, the same as the second (krunner still shows)
Fourth time, same as the second, only krunner no longer shows
After that only: 
QCommandLineParser: argument list cannot be empty, it should contain at least the executable name



SOFTWARE/OS VERSIONS
KDE Plasma Version: 5.25.1
KDE Frameworks Version: 5.95.0
Qt Version: 5.15.5

HARDWARE
GPU: GTX 1080
Number of displays in use: 4
Comment 1 kodatarule 2022-06-29 14:59:14 UTC
To add to this, not just krunner but a lot of other stuff glitched out(like opening panels, and simple applications as Steam outright freeze and no longer open after they were opened).
Just for info - the issue wasn't present in 5.24.5
Comment 2 kilgore.trout 2022-06-30 09:46:37 UTC
(In reply to kodatarule from comment #1)
> To add to this, not just krunner but a lot of other stuff glitched out, like opening panels.
> Just for info - the issue wasn't present in 5.24.5

I have this same issue, in fact I don't know where to submit it.
More details:
- clicking on buttons in the System Tray doesn't always open the desired popup — the frequency of this happening is nod related to high resources' usage;
- typing in KRunner hangs — the input is regitered, so if I type "system settings" and press enter, the query isn't displayed, but KRunner correctly opens System Settings

OS: openSUSE Tumbleweed 20220628
KDE Plasma: 5.25.1
KDE Frameworks: 5.95.0
Qt: 5.15.2
Kernel: 5.18.6-1-default (64-bit)
Graphics Platform: Wayland
CPU: AMD Ryzen 5 2600 Six-Core
Memory: 7.7 GiB RAM
Graphics Processor: NVIDIA GeForce GTX 750
Comment 3 kodatarule 2022-06-30 18:50:49 UTC
(In reply to idesmi from comment #2)
> (In reply to kodatarule from comment #1)
> > To add to this, not just krunner but a lot of other stuff glitched out, like opening panels.
> > Just for info - the issue wasn't present in 5.24.5
> 
> I have this same issue, in fact I don't know where to submit it.
> More details:
> - clicking on buttons in the System Tray doesn't always open the desired
> popup — the frequency of this happening is nod related to high resources'
> usage;
> - typing in KRunner hangs — the input is regitered, so if I type "system
> settings" and press enter, the query isn't displayed, but KRunner correctly
> opens System Settings
> 
> OS: openSUSE Tumbleweed 20220628
> KDE Plasma: 5.25.1
> KDE Frameworks: 5.95.0
> Qt: 5.15.2
> Kernel: 5.18.6-1-default (64-bit)
> Graphics Platform: Wayland
> CPU: AMD Ryzen 5 2600 Six-Core
> Memory: 7.7 GiB RAM
> Graphics Processor: NVIDIA GeForce GTX 750

Do you experience clicking on panel multiple times, or other drop down notification to stop showing up ?
Also if you have steam open for longer, does the client itself just freeze for you too ?
OS: openSUSE Tumbleweed 20220628
KDE Plasma: 5.25.2
KDE Frameworks: 5.95.0
Qt: 5.15.5
Kernel: 5.18.6-262-tkg-pds
Graphics Platform: Wayland
CPU: AMD Ryzen 7 5800X3D
Memory: 31.3 GiB RAM
Graphics Processor: NVIDIA GeForce RTX 3070
Comment 4 kodatarule 2022-06-30 18:51:16 UTC
Apologies, forgot to change that I use Arch Linux
Comment 5 Clarence Manuel 2022-07-06 03:27:14 UTC
Same thing with my PC, but for Application Launcher. I'm using Fedora 36 KDE Plasma Spin.
Comment 6 archetech 2022-09-16 15:00:49 UTC
This bug is in 5.25.90 too.   GTX960  Linux fr Scratch source build Qt 5.15.5  NV 515.57 drv.
Comment 7 kodatarule 2022-09-19 17:37:44 UTC
(In reply to archetech from comment #6)
> This bug is in 5.25.90 too.   GTX960  Linux fr Scratch source build Qt
> 5.15.5  NV 515.57 drv.

Can you confirm if it's still present if you set your env variable - QSG_RENDER_LOOP=basic ?
Comment 8 keydieyeah 2022-09-21 16:26:07 UTC
I am using KDE Plasma 5.26 Beta / Wayland and "QSG_RENDER_LOOP=basic" does not solve this problem.
Comment 9 marvelrenju1 2022-09-22 00:54:48 UTC
*** This bug has been confirmed by popular vote. ***
Comment 10 absdee 2023-01-08 17:04:11 UTC
NVIDIA/Wayland/Fedora 37/KDE Plasma 5.26.5 - same trouble
Comment 11 Jakub Narolewski 2023-03-25 11:21:47 UTC
Same stuff on Tumbleweed with Plasma 5.27.3 - also on nvidia GPU.
Comment 12 keydieyeah 2023-04-09 10:07:25 UTC
It's been almost a year and it's still the same. KDE apparently doesn't care about NVIDIA users.  Also, the panel freezes from time to time completely visually. This has been the case for a long time. So NVIDIA users will always have a problem with KDE. I recommend using Sway(with Vulkan renderer) or Hyprland.
Comment 13 Moritz 2023-07-01 13:47:47 UTC
Actually I'd call this a major showtrooper and it must be fixed before plasma 6.0 (when wayland is the default)
Comment 14 hmnd 2023-07-07 21:16:34 UTC
Happening for me too on Manjaro + KDE Wayland + NVIDIA GPU.
Comment 15 Spyros Angelis 2023-10-12 08:05:58 UTC
Same issue here, it happens very often. I have to kill krunner to be able to use it again.

Fedora Linux 38,
KDE Plasma Version: 5.27.8,
KDE Frameworks Version: 5.110.0,
WAYLAND,
NVIDIA RTX 3080
Comment 16 mcanders1 2023-10-14 00:46:50 UTC
Another repro!

KDE Plasma 5.27.8
Debian 12 (SID)
Wayland
Nvidia RTX 4090
Comment 17 mcanders1 2023-10-14 00:52:17 UTC
Hackey workaround: create a custom shortcut with "add command" in the Shortcuts menu and write `pkill 'krunner'`.
Or alternatively, just give up on krunner and launch applications with the app launcher.
Comment 18 David Redondo 2023-11-17 15:17:47 UTC
Does 

QSG_RENDER_LOOP=basic krunner --replace

fix this issue or at least help?
Comment 19 Dmitrii Chermnykh 2023-11-17 17:00:45 UTC
(In reply to David Redondo from comment #18)
> Does 
> 
> QSG_RENDER_LOOP=basic krunner --replace
> 
> fix this issue or at least help?

It does not, krunner still hangs after spam clicking its hotkey
Comment 20 Dmitrii Chermnykh 2023-11-17 17:18:54 UTC
forcing qml software render also does not help:
`QSG_RENDER_LOOP=basic krunner --replace` - krunner hangs
`QMLSCENE_DEVICE=softwarecontext krunner --replace` - krunner also hangs
`QMLSCENE_DEVICE=softwarecontext QSG_RENDER_LOOP=basic krunner --replace` - krunner hangs
Comment 21 David Edmundson 2023-12-08 14:44:08 UTC
When you say hangs, you mean it doesn't open or is visually frozen?

Can you run qdbus org.kde.krunner when "frozen" and confirm if it prints results?
Comment 22 Spyros Angelis 2023-12-08 15:56:34 UTC
UPDATE
-----------

For me the issue has been resolved with one of the plasma or framework updates. Now running the following:

Operating System: Fedora Linux 39
KDE Plasma Version: 5.27.9
KDE Frameworks Version: 5.111.0
Qt Version: 5.15.11
Kernel Version: 6.6.4-200.fc39.x86_64 (64-bit)
Graphics Platform: Wayland
Graphics Processor: NVIDIA GeForce RTX 3080/PCIe/SSE2

and now krunner  is working consistently.
Comment 23 Dmitrii Chermnykh 2023-12-08 19:02:18 UTC
it does
qdbus org.kde.krunner
/
/App
/MainApplication
/org
/org/kde
/org/kde/krunner

the krunner window in frozen state is not shown on screen or in kwin overview
Comment 24 qlum 2023-12-08 19:03:59 UTC
Just for reference, I personally no longer use Nvidia hardware since early this year but other people seem to be more than capable of  handling it.
Comment 25 Dmitrii Chermnykh 2023-12-08 19:15:17 UTC
Created attachment 164023 [details]
krunner log when it dissapears

If I list kwin clients with the script described in https://unix.stackexchange.com/questions/706477/is-there-a-way-to-get-list-of-windows-on-kde-wayland 
I get KRunner there when it works as expected, but there are no krunner script when it stops showing even though the `krunner` process exists:
 8589  chermnyx │       0.0 0.7 00:00:00 │ /usr/bin/krunner


Seems like it stops being able to create window 

I've tried to run kurnner with `QT_LOGGING_RULES='*=true' krunner`
and got the following when it hangs:
qt.qpa.wayland.backingstore: Didn't receive frame callback in time, window should now be inexposed
Comment 26 Nate Graham 2023-12-12 16:04:07 UTC

*** This bug has been marked as a duplicate of bug 477028 ***
Comment 27 Nate Graham 2023-12-12 16:09:37 UTC
Per Bug 477762 Comment 16, this is an NVIDIA issue that's fixed upstream in Qt via https://codereview.qt-project.org/c/qt/qtwayland/+/503674. We also have an option to work around the issue via https://invent.kde.org/plasma/plasma-integration/-/merge_requests/119 in case that Qt patch isn't merged in time for the Plasma 6 launch.
Comment 28 Nate Graham 2023-12-12 16:10:05 UTC
*** Bug 477762 has been marked as a duplicate of this bug. ***
Comment 29 Nate Graham 2023-12-12 16:10:09 UTC
*** Bug 477028 has been marked as a duplicate of this bug. ***
Comment 30 Dmitrii Chermnykh 2023-12-24 12:03:48 UTC
setting `QT_QUICK_BACKEND=software` works as a workaround
Comment 31 Szczepan Hołyszewski 2023-12-29 15:13:41 UTC
(In reply to Dmitrii Chermnykh from comment #30)
> setting `QT_QUICK_BACKEND=software` works as a workaround

Is there a way to apply this workaround permanently? Notably there seems to be no krunner.desktop anywhere.
Comment 32 Szczepan Hołyszewski 2023-12-29 16:02:29 UTC
(In reply to Szczepan Hołyszewski from comment #31)
> Notably there seems to be no krunner.desktop anywhere.

There is /usr/share/kglobalaccel/org.kde.krunner.desktop, but copying it to ~/.local/share/applications and editing there has no effect.
Comment 33 Dmitrii Chermnykh 2023-12-29 16:04:12 UTC
(In reply to Szczepan Hołyszewski from comment #31)
> (In reply to Dmitrii Chermnykh from comment #30)
> > setting `QT_QUICK_BACKEND=software` works as a workaround
> 
> Is there a way to apply this workaround permanently? Notably there seems to
> be no krunner.desktop anywhere.

I'm using the following override:

systemctl --user edit plasma-krunner.service 

[Service]
Environment=QT_QUICK_BACKEND=software
Comment 34 Nate Graham 2024-01-16 22:41:25 UTC
*** Bug 479865 has been marked as a duplicate of this bug. ***
Comment 35 Nate Graham 2024-01-16 23:03:58 UTC
*** Bug 479723 has been marked as a duplicate of this bug. ***
Comment 36 Nate Graham 2024-01-17 01:20:28 UTC
*** Bug 479766 has been marked as a duplicate of this bug. ***
Comment 37 Nate Graham 2024-01-18 20:05:04 UTC
*** Bug 479947 has been marked as a duplicate of this bug. ***
Comment 38 Nicolas Fella 2024-01-22 13:22:55 UTC
*** Bug 480153 has been marked as a duplicate of this bug. ***
Comment 39 Nate Graham 2024-01-23 18:27:42 UTC
*** Bug 480101 has been marked as a duplicate of this bug. ***
Comment 40 Nate Graham 2024-01-30 21:18:21 UTC
*** Bug 480559 has been marked as a duplicate of this bug. ***
Comment 41 Nate Graham 2024-01-30 23:00:31 UTC
*** Bug 479087 has been marked as a duplicate of this bug. ***
Comment 42 Nate Graham 2024-02-01 19:40:41 UTC
*** Bug 480617 has been marked as a duplicate of this bug. ***
Comment 43 David Redondo 2024-02-02 13:34:08 UTC
We merged a workaround in Qt: https://codereview.qt-project.org/c/qt/qtwayland/+/536202
Comment 44 Antonio Rojas 2024-02-03 17:35:42 UTC
*** Bug 480786 has been marked as a duplicate of this bug. ***
Comment 45 Antonio Rojas 2024-02-03 21:41:04 UTC
*** Bug 480806 has been marked as a duplicate of this bug. ***
Comment 46 Antonio Rojas 2024-02-03 23:00:25 UTC
*** Bug 480813 has been marked as a duplicate of this bug. ***
Comment 47 Landgraf132 2024-02-12 05:14:30 UTC
(In reply to Dmitrii Chermnykh from comment #33)
> (In reply to Szczepan Hołyszewski from comment #31)
> > (In reply to Dmitrii Chermnykh from comment #30)
> > > setting `QT_QUICK_BACKEND=software` works as a workaround
> > 
> > Is there a way to apply this workaround permanently? Notably there seems to
> > be no krunner.desktop anywhere.
> 
> I'm using the following override:
> 
> systemctl --user edit plasma-krunner.service 
> 
> [Service]
> Environment=QT_QUICK_BACKEND=software

How can this be adapted for a plasma panel? I added the following lines to the ~/ .bashrc file:
QT_QUICK_BACKEND=software
QSG_RENDER_LOOP=basic

But the plasma panel still opens its menu every other time.
Comment 48 Dmitrii Chermnykh 2024-02-12 06:03:44 UTC
(In reply to Landgraf132 from comment #47)
> How can this be adapted for a plasma panel? I added the following lines to

You can set the "render loop" property in Plasma Renderer configuration window to "basic"
Comment 49 David Redondo 2024-02-14 08:38:49 UTC
Git commit d5ccdeb50dfd46c5d80d28ec5b0519b998ae851b by David Redondo.
Committed on 14/02/2024 at 08:37.
Pushed by davidre into branch 'master'.

qt6: Bring back basic render loop on nvidia wayland when Qt < 6.6.3

This reverts commit 87d0efdc7ef1fe3d9f461d6b6aa8c82a71442150.
Qt 6.6.3 and up contain a similar check for now until a proper
fix is merged.

M  +14   -1    qt6/src/platformtheme/qtquickrenderersettings.cpp

https://invent.kde.org/plasma/plasma-integration/-/commit/d5ccdeb50dfd46c5d80d28ec5b0519b998ae851b
Comment 50 Bug Janitor Service 2024-02-14 13:15:21 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-integration/-/merge_requests/136
Comment 51 David Redondo 2024-02-14 14:20:21 UTC
Git commit 1034813b14738e770ebd30e59120c23d0b0c9fd6 by David Redondo.
Committed on 14/02/2024 at 13:15.
Pushed by davidre into branch 'Plasma/6.0'.

qt6: Bring back basic render loop on nvidia wayland when Qt < 6.6.3

This reverts commit 87d0efdc7ef1fe3d9f461d6b6aa8c82a71442150.
Qt 6.6.3 and up contain a similar check for now until a proper
fix is merged.


(cherry picked from commit d5ccdeb50dfd46c5d80d28ec5b0519b998ae851b)

M  +14   -1    qt6/src/platformtheme/qtquickrenderersettings.cpp

https://invent.kde.org/plasma/plasma-integration/-/commit/1034813b14738e770ebd30e59120c23d0b0c9fd6