Bug 424725

Summary: When clearing the clipboard, the "Are you sure?" dialog breaks future clipboard clearing if you answer "no" with "don't ask again" checked
Product: [Applications] klipper Reporter: Lua <lv215bd5>
Component: plasma-widgetAssignee: Plasma Bugs List <plasma-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: nate, plasma-bugs
Priority: HI Keywords: triaged, usability
Version: 5.18.5   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: clipboard bug
plasmashell --replace doesn't solve
plasma-shell --replace on terminal
plasma-shell --replace 2

Description Lua 2020-07-27 23:43:39 UTC
Created attachment 130444 [details]
clipboard bug

SUMMARY
It simply stop working. Reboot doesn't solve.
Clipboard widget version: 4:5.18-50ubuntu0.1

STEPS TO REPRODUCE
I'm not able to reproduce this because it's happening right now.

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: Kubuntu 20.04
(available in About System)
KDE Plasma Version: 5.18.5
KDE Frameworks Version: 5.68.0
Qt Version: 5.12.8

ADDITIONAL INFORMATION
Comment 1 Nate Graham 2020-07-28 18:51:49 UTC
You said:

> Reboot doesn't solve.
And:

> I'm not able to reproduce this because it's happening right now.

So what solved it? Did it just randomly stop happening?
Comment 2 Lua 2020-07-29 20:28:27 UTC
Nothing that I tried solved, including recreating the panel, defaulting the clipboard settings. Even reboot doesn't help.
Comment 3 Lua 2020-07-29 20:29:37 UTC
Ops, sorry. I meant "I'm not able to trigger this bug manually, because it's still happening", in other words, I can't stop this bug to reproduce it again.
Comment 4 Nate Graham 2020-07-29 23:07:02 UTC
I see, so it's always happening.

Works for me on 5.19 and git master FWIW.

Can you run `plasmashell --replace` in a terminal window and then click the clear button and tell me if anything appears in the terminal window right afterwards?
Comment 5 Lua 2020-07-30 16:57:27 UTC
Created attachment 130520 [details]
plasmashell --replace doesn't solve
Comment 6 Lua 2020-07-30 16:57:56 UTC
It didn't work. I attach a video showing that it didn't solve.
Comment 7 Nate Graham 2020-07-30 17:07:19 UTC
That wasn't supposed to solve the problem but rather provide logging information that might help me debug the issue. Can you provide the logging that I requested?
Comment 8 Lua 2020-07-30 17:10:25 UTC
Oops, I recorded 2 videos, one of them was with terminal, but I got worried. Does the output include personal info?
Comment 9 Nate Graham 2020-07-30 17:13:45 UTC
No. :)
Comment 10 Lua 2020-07-30 17:15:39 UTC
Created attachment 130521 [details]
plasma-shell --replace on terminal
Comment 11 Lua 2020-07-30 17:15:53 UTC
Done!
Comment 12 Nate Graham 2020-07-30 17:22:45 UTC
I need to see the terminal output when you press the "clear history" button. :)
Comment 13 Lua 2020-07-30 17:48:52 UTC
But I did press it and no output was created. Sorry, what I need to do?
Comment 14 Nate Graham 2020-07-30 17:50:04 UTC
I didn't see you press the "clear history button" in that video. Are you saying you clicked it while not taking a video and nothing happened?
Comment 15 Lua 2020-07-30 18:02:42 UTC
Created attachment 130523 [details]
plasma-shell --replace 2
Comment 16 Lua 2020-07-30 18:02:51 UTC
Done!
Comment 17 Nate Graham 2020-07-30 18:04:25 UTC
Thanks!

Sadly you were right, no special output. That makes this a bit weird.
Comment 18 David Edmundson 2020-07-30 21:12:59 UTC
Heh, I know what this is.

Can I see your ~/.config/plasmashellrc

Do you have the lines:

[Notification Messages]
really_clear_history=false
Comment 19 Lua 2020-08-02 16:27:06 UTC
Yes:

[Notification Messages]
really_clear_history=false
Comment 20 Lua 2020-08-02 16:28:11 UTC
[ActionsWidget]
ColumnState=AAAA/wAAAAAAAAABAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcoAAAACAQAAAQAAAAAAAAAAAAAAAGT/////AAAAgQAAAAAAAAACAAAA+gAAAAEAAAAAAAAA0AAAAAEAAAAAAAAD6AAAAABk

[ConfigDialog]
Height 768=516
Width 1366=595

[DownloadDialog Settings]
Height 768=454
Width 1366=700

[General]
Number of Actions=0

[KFileDialog Settings]
Recent Files[$e]=blue-and-red-wallpaper-2560x1600.jpg,file:$HOME/Pictures/Wallpapers/neon-cubes.jpg,file:$HOME/Pictures/Wallpapers/1039991.jpg,file:$HOME/Pictures/Wallpapers/1054256.jpg,file:$HOME/Pictures/Wallpapers/Explosion-Of-Colors-2560x1600.jpg,file:$HOME/Pictures/Wallpapers/San Francisco-Oakland Bay Bridge at Twilight.jpg,file:$HOME/Pictures/Wallpapers/Red moon desert.jpg,file:$HOME/Pictures/Wallpapers/REFLECTION - GALLERYPLAYER.jpg
Recent URLs[$e]=file:$HOME/Pictures/Wallpapers/
iconViewIconSize=43

[Notification Messages]
really_clear_history=false

[PlasmaRunnerManager]
LaunchCounts=6 services_easytag.desktop,15 services_simplescreenrecorder.desktop,1 services_org.kde.ksysguard.desktop,1 services_google-chrome.desktop,1 services_kwinscreenedges.desktop,1 services_darktable.desktop,2 services_gimp.desktop,6 services_org.gnome.DiskUtility.desktop,1 services_org.kde.konsole.desktop,3 services_chrome-apdfllckaahabafndbhieahigkjlhalf-Profile_5.desktop,3 services_steam.desktop,9 services_firefox.desktop,1 services_org.kde.ktimer.desktop,5 services_org.gnome.clocks.desktop,1 services_kwinoptions.desktop,5 services_libreoffice-writer.desktop,2 services_kcm_pulseaudio.desktop,1 services_screenlocker.desktop,1 services_org.kde.kate.desktop,1 services_code.desktop,3 services_inkscape.desktop,1 services_chrome-eigpmdhekjlgjgcppnanaanbdmnlnagl-Profile_5.desktop,1 services_kcm_sddm.desktop,2 services_soundconverter.desktop,9 services_virtualbox.desktop,3 services_kvantummanager.desktop,1 services_org.kde.spectacle.desktop,2 services_org.kde.discover.desktop,1 services_chrome-adnlfjpnmidfimlkaohpidplnoimahfh-Profile_5.desktop
pluginWhiteList=desktopsessions,services,places,PowerDevil,calculator,unitconverter,shell,bookmarks,recentdocuments,locations,baloosearch

[PlasmaViews][Panel 2][Defaults]
thickness=36

[PlasmaViews][Panel 2][Horizontal1366]
thickness=36

[PlasmaViews][Panel 24][Defaults]
thickness=36

[PlasmaViews][Panel 24][Horizontal1366]
thickness=36

[PlasmaViews][Panel 46][Defaults]
thickness=27

[PlasmaViews][Panel 46][Horizontal1366]
thickness=27

[ScreenConnectors]
0=eDP-1

[Updates]
performed=/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/move_desktop_layout_config.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/obsolete_kickoffrc.js,/usr/share/plasma/shells/org.kde.plasma.desktop/contents/updates/unlock_widgets.js
Comment 21 Lua 2020-08-02 16:30:07 UTC
After changing it to true and running plasma-shell --replace, it started to work again! But wait, why this happened?
Comment 22 David Edmundson 2020-08-02 20:38:44 UTC
There's a prompt "Do not ask again" on the dialog that shows the message

"Are you sure you want to clear the history"

at some point you've pressed that no you're not sure you want to clear and you don't want to be asked again.

It behaved in a way that is "technically correct" even if it's not super intuitive.
Comment 23 Nate Graham 2020-08-02 22:04:34 UTC
Not useful either, since it gets you into a broken state.

This is a great candidate for showing an inline Undo post-clear instead of a confirmation dialog pre-clear. That's what Elisa does when you clear the playlist and It's a way better UX IMO.
Comment 24 Lua 2020-08-02 23:09:37 UTC
Understood! Furthermore, there's no setting available in clipboard settings to restore the confirmation dialog, so the user indeed gets in a broken state.
Comment 25 Lua 2020-08-02 23:10:30 UTC
A "undo changes" banner with an "undo" button is also a great solution. I prefer this one.
Comment 26 David Edmundson 2020-08-03 09:42:13 UTC
A post-clear undo is not a viable option for an action that's about deleting private information as in order to work it would have to not delete it.
Comment 27 Nate Graham 2020-08-03 13:38:46 UTC
Elisa puts the undo action for playlist clearing on a timer. It's visible for IIRC 7 seconds, and after that, the option to undo clearing the playlist the disappears. So for Klipper, we could do the same thing: the cleared data could be secretly kept around in the background for a few seconds while the user has a chance to undo it, and after that, both the cleared data and the undo option would disappear.

This is also how many mobile apps handle similar situations. And I'd encourage you try it out in Elisa if you haven't used it before. It's quite user friendly.
Comment 28 Lua 2020-08-07 16:25:21 UTC
What is Elisa?
Comment 30 Christoph Feck 2020-08-07 17:07:59 UTC
Is this bug 336053?
Comment 31 Nate Graham 2020-08-07 17:16:24 UTC
Looks like it!

*** This bug has been marked as a duplicate of bug 336053 ***