Bug 469663 - With certain combination of Klipper settings, Clipboard action menu pop-ups spawn infinitely until Plasma crashes
Summary: With certain combination of Klipper settings, Clipboard action menu pop-ups s...
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Clipboard widget & pop-up (show other bugs)
Version: master
Platform: Debian testing Linux
: NOR crash
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords: wayland
Depends on:
Blocks:
 
Reported: 2023-05-12 12:56 UTC by imthenachoman
Modified: 2024-10-19 10:13 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.2.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description imthenachoman 2023-05-12 12:56:41 UTC
SUMMARY

I am on a fresh install of Debian 12 RC2 with KDE Plasma. I made some changes to the clipboard settings. After I did, the system repeatedly shows the action menu popup - in an infinite loop.

Video showing issue: https://www.youtube.com/watch?v=k0mqbvhTVis

STEPS TO REPRODUCE

1. In the clipboard configuration, set:
   - General > Selection and Clipboard > Keep the selection and clipboard the same
   - General > Text selection > Always save in history
   - Action Menu > Show action popup menu > Immediately on selection
   - Action Menu > For an item chosen from history

OBSERVED RESULT

Infinite loop of the action menu pop up even when nothing is selected.

EXPECTED RESULT

Action menu pop up should not invoke unless something is selected.

SOFTWARE/OS VERSIONS
OS: Debian Linux 12 RC2
KDE Plasma Version: 5.27.2
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Kernel Version: 6.1.0-8-amd64 (64-bit)
Graphics Platform: Wayland

ADDITIONAL INFORMATION

Processors: 6 x Intel Core i5-8500 CPU @ 3.00 Ghz
Memory: 30.7 GiB of RAM
Graphics Processor: Mesa Intel UHD Graphics 630
Manufacturer: HP
Product Name: HP ProDesk 600 G4 SFF
Comment 1 Nate Graham 2023-05-15 18:36:16 UTC
Cannot reproduce the issue with those exact settings.
Comment 2 imthenachoman 2023-05-16 03:56:05 UTC
I was able to recreate it.

Here is my `~/.config/klipperrc` file:

```
[Actions]
ReplayActionInHistory=true

[General]
IgnoreImages=false
IgnoreSelection=false
MaxClipItems=999
SyncClipboards=true
URLGrabberEnabled=true
Version=5.27.2
```

With this set, go into Chrome, then copy the URL in the address bar.
Comment 3 Nate Graham 2023-05-16 15:47:24 UTC
Hmm, still cannot reproduce with my klipperrc file looking exactly like that. When I copy a URL in Chrome's URL bar, I see a popup, but only one. When I dismiss it, it stays gone.

This is in Plasma 6 on X11, so maybe there's a difference between P5 on Wayland.
Comment 4 Colin J Thomson 2023-05-16 16:09:36 UTC
(In reply to Nate Graham from comment #3)
> Hmm, still cannot reproduce with my klipperrc file looking exactly like
> that. When I copy a URL in Chrome's URL bar, I see a popup, but only one.
> When I dismiss it, it stays gone.
> 
> This is in Plasma 6 on X11, so maybe there's a difference between P5 on
> Wayland.

OK, I just tested this and once I enabled - Action Menu > Show action popup menu > Immediately on selection and copied a URL I had exactly the same issue. I had to kill plasma :-( 
I did notice this in the shell upon restart, repeats many times, not sure if it is of any use:

qt.qpa.wayland: setGrabPopup called with a parent, QtWaylandClient::QWaylandXdgSurface(0x55865b8b1dd0) which does not match the current topmost grabbing popup, QtWaylandClient::QWaylandXdgSurface(0x55865cb57e50) According to the xdg-shell protocol, this is not allowed. The wayland QPA plugin is currently handling it by setting the parent to the topmost grabbing popup. Note, however, that this may cause positioning errors and popups closing unxpectedly because xdg-shell mandate that child popups close before parents

Operating System: Fedora Linux 38
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.106.0
KDE Gear 23.04.1
Qt Version: 5.15.9
Kernel Version: 6.3.2-200.fc38.x86_64 (64-bit)
Graphics Platform: Wayland
Comment 5 imthenachoman 2023-05-16 16:15:40 UTC
(In reply to Nate Graham from comment #3)
> This is in Plasma 6 on X11, so maybe there's a difference between P5 on Wayland.

Yes. i am on Wayland.

(In reply to Colin J Thomson from comment #4)
> OK, I just tested this and once I enabled - Action Menu > Show action popup menu > Immediately on selection and copied a URL I had exactly the same issue. I had to kill plasma :-( 

Thank you for confirming.
Comment 6 Nate Graham 2023-05-17 13:36:45 UTC
All right, so maybe it's a Wayland-only issue. Will re-test on Wayland later.
Comment 7 Nate Graham 2023-05-18 16:11:59 UTC
Can reproduce the issue on Wayland.
Comment 8 Colin J Thomson 2023-12-12 10:01:15 UTC
I am currently testing Plasma 6 beta 1 (Awesome BTW) but sadly this problem is still happening :(
copy a URL in Brave's URL bar, and a  popup appears, move the pointer and it goes into a loop with never ending popups and no control over my Desktop.
I have to drop to a shell and kill plasma and set URLGrabberEnabled=false in my klipperrc before I can restart Plasma.

Operating System: Fedora Linux 39
KDE Plasma Version: 5.90.0 
KDE Frameworks Version: 5.246.0
Qt Version: 6.6.0
Kernel Version: 6.6.6-200.fc39.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 5600G with Radeon Graphics
Memory: 29.2 GiB of RAM
Comment 9 Colin J Thomson 2024-04-13 09:14:37 UTC
Just FYI, this is still happening with the latest release:

Operating System: Fedora Linux 39
KDE Gear Version 24.02.2
KDE Plasma Version: 6.0.4
KDE Frameworks Version: 6.1.0
Qt Version: 6.7.0
Kernel Version: 6.8.5-201.fc39.x86_64 (64-bit)
Graphics Platform: Wayland
Comment 10 Akseli Lahtinen 2024-06-06 13:17:10 UTC
I can't repro this exactly. 

In chromium when I double click the url, I get two popups, but it never gets stuck in a loop.

Also when selecting something from history, the history menu closes and if i click anything, i get the popup menu appear immediately.

Also it doesnt copy text, it copies the *whole HTML document file*

There's definitely something weird going on.
Comment 11 Yavor Buyukliev 2024-06-13 21:56:13 UTC
Just recovered from this nasty one by editing ~/.config/klipperrc changing URLGrabberEnabled to false.

It's bad, because there is black screen - no panel, no chance to go to the klipper settings and change it back from there. 

The KRunner was up, so I tried to set Global shortcut to clear the clipboard content - didn't work, maybe another bug. The shortcut is set but did nothing.

Ended up here, trying to fix the popup position but messing with the actions in the process.  Turns out the position is currently governed by the global Window placement, setting that to "Under mouse" worked for me.

Not a rant, just trying to help.
Peace!

Operating System: Arch Linux 
KDE Plasma Version: 6.0.5
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.1
Kernel Version: 6.9.4-arch1-1 (64-bit)
Graphics Platform: Wayland
Comment 12 Akseli Lahtinen 2024-06-14 10:56:56 UTC
I still can't repro this, so it might be fixed in Plasma 6.1.

Can you test this again in Plasma 6.1 when it's out and see if it happens again? I tried the exact same config pasted earlier here but I couldn't get the bug to happen.
Comment 13 imthenachoman 2024-06-16 20:12:15 UTC
I am on KDE 6 and I'm still seeing the bug but now it's also causing KDE to crash and restart. 

When I set the settings in question, and then I go to copy a string like a URL, it shows the action menu popup and keeps showing new ones AND then it'll crash all of KDE which restarts it but it still shows the pop up menu (even though I am not touching the keyboard/mouse) and it just goes into a loop.

I took a video of it from my phone since I can't use the computer to take a screenshot.

https://photos.app.goo.gl/r4FvUVy4FJ2jfpVVA

SOFTWARE/OS VERSIONS
OS: openSUSE Tumbleweed 20240612
KDE Plasma Version: 6.0.5
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.1
Kernel Version: 6.9.3-1-default (64-bit)
Graphics Platform: Wayland
Comment 14 Yavor Buyukliev 2024-06-22 19:06:04 UTC
(In reply to Akseli Lahtinen from comment #12)
> I still can't repro this, so it might be fixed in Plasma 6.1.
> 
> Can you test this again in Plasma 6.1 when it's out and see if it happens
> again? I tried the exact same config pasted earlier here but I couldn't get
> the bug to happen.

It seems fixed now. Probably even before 6.1 release. I didn't do a proper test when it hit me last time. Apology about that.
Now, with brand new profile everything works as expected!

It's still happens on my main profile tho, my home folder is many years old :)

All the best!
Comment 15 imthenachoman 2024-06-23 02:58:05 UTC
(In reply to Yavor Buyukliev from comment #14)
> (In reply to Akseli Lahtinen from comment #12)
> > I still can't repro this, so it might be fixed in Plasma 6.1.
> > 
> > Can you test this again in Plasma 6.1 when it's out and see if it happens
> > again? I tried the exact same config pasted earlier here but I couldn't get
> > the bug to happen.
> 
> It seems fixed now. Probably even before 6.1 release. I didn't do a proper
> test when it hit me last time. Apology about that.
> Now, with brand new profile everything works as expected!
> 
> It's still happens on my main profile tho, my home folder is many years old
> :)
> 
> All the best!

It's still happening to me on KDE 6 on a fresh install.
Comment 16 Nate Graham 2024-06-26 19:20:35 UTC
(In reply to imthenachoman from comment #15)
> It's still happening to me on KDE 6 on a fresh install.

6.0 or 6.1?
Comment 17 imthenachoman 2024-06-26 19:52:27 UTC
(In reply to Nate Graham from comment #16)
> (In reply to imthenachoman from comment #15)
> > It's still happening to me on KDE 6 on a fresh install.
> 
> 6.0 or 6.1?

6.0

6.1 just became available in OS TW and I haven't updated yet.
Comment 18 Nate Graham 2024-06-26 20:09:29 UTC
Ok, let us know if it's still happening in 6.1. Thanks!
Comment 19 Colin J Thomson 2024-06-30 09:47:52 UTC
(In reply to Nate Graham from comment #18)
> Ok, let us know if it's still happening in 6.1. Thanks!

Still happens to me on this box:
Enable URLGrabberEnabled=true highlight a URL and the pop up appears and will not release and then starts to eat all the resources.
I have to jump to a shell and kill plasma, edit URLGrabberEnabled=false and restart plasma.

Operating System: Fedora Linux 40
KDE Plasma Version: 6.1.1
KDE Frameworks Version: 6.3.0
KDE Gear 24.05.1
Qt Version: 6.7.1
Kernel Version: 6.9.7-200.fc40.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 5600G with Radeon Graphics
Memory: 29.2 GiB of RAM
Graphics Processor: AMD Radeon Graphics
Comment 20 imthenachoman 2024-06-30 21:01:52 UTC
(In reply to Nate Graham from comment #18)
> Ok, let us know if it's still happening in 6.1. Thanks!

Still happens on OS TW running KDE 6.1.
Comment 21 Colin J Thomson 2024-07-22 18:58:59 UTC
Since the last set of updates, I cannot reproduce this now. I seem to remember reading there where quite a few fixes for Klipper.
I'll leave URLGrabberEnabled=true and see how it behaves.

FWIW:
Operating System: Fedora Linux 40
KDE Plasma Version: 6.1.3
KDE Frameworks Version: 6.4.0
Qt Version: 6.7.2
Comment 22 Colin J Thomson 2024-08-11 10:46:30 UTC
(In reply to Colin J Thomson from comment #21)
> Since the last set of updates, I cannot reproduce this now. I seem to
> remember reading there where quite a few fixes for Klipper.
> I'll leave URLGrabberEnabled=true and see how it behaves.
> 
> FWIW:
> Operating System: Fedora Linux 40
> KDE Plasma Version: 6.1.3
> KDE Frameworks Version: 6.4.0
> Qt Version: 6.7.2

No issues at all, works as it should.
Comment 23 Nate Graham 2024-08-13 18:27:05 UTC
This is also fixed "officially" in the upcoming Plasma 6.2 by replacing the old menu with a new one.