Bug 427946 - Uninstalled Plasma widget is not immediately removed from system tray settings
Summary: Uninstalled Plasma widget is not immediately removed from system tray settings
Status: RESOLVED DUPLICATE of bug 429442
Alias: None
Product: plasmashell
Classification: Plasma
Component: System Tray (show other bugs)
Version: master
Platform: Neon Linux
: NOR normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-10-18 23:09 UTC by Patrick Silva
Modified: 2020-12-27 00:23 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Silva 2020-10-18 23:09:16 UTC
STEPS TO REPRODUCE
1. right-click on desktop, choose "Add widgets..."
2. click on "Get new widgets" > "Download new Plasma widgets"
3. search and install Redshift Control or Weather Widget Plasma widgets
https://store.kde.org/p/998916/
https://store.kde.org/p/998917/
4. open system tray settings, click on "Entries" section: the just installed widget is present as expected
5. uninstall the just installed widget via Widget Explorer
6. reopen system tray settings, "Entries" section: uninstalled widget unexpectedly is still present
7. restart Plasma with "plasmashell --replace"
8. reopen system tray settings, "Entries" section: uninstalled widget
is no longer present

EXPECTED RESULT
Plasma widget should immediately be removed from system tray settings
after the step 5

SOFTWARE/OS VERSIONS
Operating System: KDE neon Unstable Edition
KDE Plasma Version: 5.20.80
KDE Frameworks Version: 5.76.0
Qt Version: 5.15.0
Comment 1 Konrad Materka 2020-10-20 20:23:14 UTC
Hi Patrick,

uninstall from Widget Explorer is always postponed for 1 minute (IIRC), so that user can cancel the delete action. If you uninstall it from the "Download new Plasma widgets" it will apply immediately.

Can you check if that was your case?
Comment 2 Patrick Silva 2020-10-21 14:42:55 UTC
(In reply to Konrad Materka from comment #1)
> Hi Patrick,
> 
> uninstall from Widget Explorer is always postponed for 1 minute (IIRC), so
> that user can cancel the delete action. If you uninstall it from the
> "Download new Plasma widgets" it will apply immediately.
> 
> Can you check if that was your case?

Widget uninstalled via "Download new Plasma widgets" is immediately removed from system tray settings. Widget uninstalled via Widget Explorer remains
in system tray settings even after 1 minute.
Comment 3 Konrad Materka 2020-10-21 15:47:58 UTC
I've run some tests and it is working fine for me - even with applet activated, it was correctly removed from the system tray.

Maybe I understand Widget Explorer differently - how do you access it? By right-clicking on desktop, then choosing "Add widgets..."?
Comment 4 Patrick Silva 2020-10-21 16:08:21 UTC
(In reply to Konrad Materka from comment #3)
>By right-clicking on desktop, then choosing "Add widgets..."?

yes
Comment 5 Konrad Materka 2020-10-21 16:29:11 UTC
Then I have no idea what happened, it is working correctly for me (I just need to wait around 1 minute).

Maybe there is something wrong with your cache? I remember I had to run kbuildsycoca5 at some point, but it might be unrelated.

Can you run:
dbus-monitor | grep "interface=org.kde.plasma.kpackage;"

It should output something like this after install and uninstall:

signal time=1603297655.524835 sender=:1.330 -> destination=(null destination) serial=494 path=/KPackage/Plasma/Applet; interface=org.kde.plasma.kpackage; member=packageUpdated
signal time=1603297659.999057 sender=:1.330 -> destination=(null destination) serial=495 path=/KPackage/Plasma/Applet; interface=org.kde.plasma.kpackage; member=packageUninstalled

If there is no uninstall signal, then there is a bug in Widget Explorer or KPackage, not in the System Tray (which depends on this signal).
Comment 6 Konrad Materka 2020-10-23 14:50:26 UTC
Patrick, did you had a chance to check that?
Comment 7 Patrick Silva 2020-10-24 09:38:47 UTC
When should I run your commnand? Before uninstalling the widget via widget explorer? If so, it gives me no output 1 minute after I uninstall the widget.
Comment 8 Konrad Materka 2020-10-24 17:04:41 UTC
Firstly run:
kbuildsycoca5
to rebuild cache.


Then:
> dbus-monitor | grep "interface=org.kde.plasma.kpackage;"
"Download new Plasma widgets"
Should output signals when widget is installed and uninstalled. Check "Download new Plasma widgets" first, to make sure you have those signals.

Then uninstall from widget explorer, wait around one minute. Widget should disappear from widget explorer at the same time as signal is emitted. Or maybe it never disappears (until Plasma is restarted)?
Comment 9 Patrick Silva 2020-10-25 13:04:28 UTC
I ran kbuildsycoca5, re-installled fokus, Weather Widget and redshift control
widgets but currently they not even are marked as installed in "Download new Plasma widgets" window, despite they appear in the Widget Explorer. And Plasma crashes often immediately after widget installation.
Comment 10 Patrick Silva 2020-10-25 13:08:16 UTC
And

dbus-monitor | grep "interface=org.kde.plasma.kpackage;"

shows no output 1 minute after I uninstall a widget via Widgets Explorer.
Comment 11 Patrick Silva 2020-10-25 13:11:35 UTC
(In reply to Patrick Silva from comment #10)
> And
> 
> dbus-monitor | grep "interface=org.kde.plasma.kpackage;"
> 
> shows no output 1 minute after I uninstall a widget via Widgets Explorer.

the uninstalled widget disappears from Widget Explorer as expected, but no output...
Comment 12 Konrad Materka 2020-11-01 18:05:47 UTC
Can you check of fresh user? I just tested and it is working correctly.
Comment 13 Patrick Silva 2020-11-02 14:12:23 UTC
Tested with a new user account and the situation remains the same on my system:
Plasma widgets uninstalled via Widget Explorer disappear after 1 minute but they
remain in system tray settings until plasmashell process is restarted.

Operating System: KDE neon Unstable Edition
KDE Plasma Version: 5.20.80
KDE Frameworks Version: 5.76.0
Qt Version: 5.15.0
Comment 14 popov895 2020-11-10 23:35:57 UTC
Sorry guys, but I don't have enough skills to fix this issue, so please assign it to someone else;)
Comment 15 Patrick Silva 2020-11-12 20:07:43 UTC
This issue also affects systray applets.
For example, uninstall kdeconnect and print manager, both installed by default
at least on neon unstable.
Printers and KDE Connect applets remain in system tray settings, under "Hardware Control", until plasmashell process is restarted.

Operating System: KDE neon Unstable Edition
KDE Plasma Version: 5.20.80
KDE Frameworks Version: 5.76.0
Qt Version: 5.15.1
Comment 16 Patrick Silva 2020-12-26 23:55:37 UTC
I no longer can reproduce this bug after fix for bug 429442.

Operating System: KDE neon Unstable Edition
KDE Plasma Version: 5.20.80
KDE Frameworks Version: 5.78.0
Qt Version: 5.15.2
Comment 17 Nate Graham 2020-12-27 00:23:47 UTC
Yaaaaaaaay!

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