Bug 443351 - Discover fails to revoke "updates available" notification after updating
Summary: Discover fails to revoke "updates available" notification after updating
Status: CONFIRMED
Alias: None
Product: Discover
Classification: Applications
Component: discover (show other bugs)
Version: 5.22.4
Platform: Other Linux
: NOR minor
Target Milestone: ---
Assignee: Dan Leinir Turthra Jensen
URL:
Keywords: usability
Depends on:
Blocks:
 
Reported: 2021-10-05 14:12 UTC by Eduardo
Modified: 2021-10-06 14:55 UTC (History)
2 users (show)

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


Attachments
"Updates available" notification being shown while Discover is up-to-date (342.78 KB, image/png)
2021-10-05 14:12 UTC, Eduardo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eduardo 2021-10-05 14:12:13 UTC
Created attachment 142168 [details]
"Updates available" notification being shown while Discover is up-to-date

SUMMARY
Discover's "updates available" notification remains even after updating.

While running in the background, Discover realizes there are updates available and emits the "Updates available" notification to KDE's notification center.

If the user runs Discover without clicking that notification and updates everything, the notification is not cleared. The user may look at it only hours later and will be fooled into thinking there are more updates to be applied when there is actually none.


STEPS TO REPRODUCE
1. Wait for Discover to notify that it has updates available
2. Run Discover through other means, do not acknowledge the notification, don't click the "View Updates" button inside the notification.
3. Update everything inside Discover

OBSERVED RESULT
The notification will remain in the notification center, even though the system is up to date.

EXPECTED RESULT
The notification should have been cleared from the notification center.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.22.5
KDE Frameworks Version: 5.86.0
Qt Version: 5.15.2
Kernel Version: 5.14.9-arch2-1 (64-bit)
Graphics Platform: X11

ADDITIONAL INFORMATION
If the KDE notification framework doesn't provide a way for Discover to clear its own notification, then there is a bug in that framework and should be addressed there first. It should allow apps to clear their own notifications when they are no longer relevant.
Comment 1 Nate Graham 2021-10-05 17:48:19 UTC
Can confirm. It needs to revoke the notification in the case that it's still visible in the history.
Comment 2 Aleix Pol 2021-10-06 14:55:19 UTC
This is odd.
Doesn't close() revoke it?

https://invent.kde.org/plasma/discover/-/blob/master/notifier/DiscoverNotifier.cpp#L89