After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 726645 - post-update experience is bad
post-update experience is bad
Status: RESOLVED FIXED
Product: gnome-software
Classification: Applications
Component: General
unspecified
Other Linux
: Normal normal
: ---
Assigned To: GNOME Software maintainer(s)
GNOME Software maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2014-03-18 16:40 UTC by Matthias Clasen
Modified: 2014-03-20 00:45 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Remove stale notifications after an offline update has completed (3.45 KB, patch)
2014-03-19 19:07 UTC, Kalev Lember
committed Details | Review
Update the last installed timestamp after successful offline updates (2.66 KB, patch)
2014-03-19 19:07 UTC, Kalev Lember
committed Details | Review
Fix showing recently installed updates (1.17 KB, patch)
2014-03-19 19:07 UTC, Kalev Lember
committed Details | Review

Description Matthias Clasen 2014-03-18 16:40:50 UTC
I just installed an offline update (successfully, there is /var/lib/PackageKit/offline-update-completed), and after reboot and login, I see a 'updates available' notification hiding in the message tray. While I was looking at that, the 'updates installed' notification popped in. I clicked on it, and was presented with 'Checking for updates' and a spinner in gnome-software. That went on for multiple minutes, so I eventually clicked on the 'updates [4]' tab (no tab was selected before), and that immediately brought up 'All uptodate'.

Attempts to run gnome-software --mode=updated didn't succeed in seeing the contents of the (still available) offline-update-completed file either.
Comment 1 Kalev Lember 2014-03-19 10:55:16 UTC
GNotifications seem to persist over reboots and I couldn't find any API to remove them. I am not sure that persistent notifications are desirable here at all; they seem to get out of date pretty quickly.

I wonder if notifications are even necessary now that gnome-shell has the option to install updates in the shutdown dialog.

In any case, I guess an additional thing gnome-shell should do when triggering update installation, is to update org.gnome.software install-timestamp setting, so that gnome-software wouldn't offer updates again any time soon. Or maybe gnome-software should set it itself, when it finds the offline-update-completed file?
Comment 2 Kalev Lember 2014-03-19 19:06:41 UTC
I've asked around on IRC and there is API to remove notifications. It doesn't seem to work entirely right though in my testing; I'll need to look into it a bit more. Might be something broken on the gnome-shell side.

In any case, here come 3 gnome-software patches to make the situation better. Since we haven't released gnome-software 3.11.92 yet, perhaps the hard code freeze rules don't apply yet ...

One remaining pain point that these patches don't fix is the lack of feedback given to the user. After clicking 'Review' on the notification, the recently updated apps list shows up, but it's pretty hard to tell what it is:

https://people.gnome.org/~klember/gnome-software-installed-updates.png

Previously, gnome-software would set the title of the window to "Recent Software Updates", but after switching to the headerbar, it isn't shown any more.
Comment 3 Kalev Lember 2014-03-19 19:07:24 UTC
Created attachment 272423 [details] [review]
Remove stale notifications after an offline update has completed
Comment 4 Kalev Lember 2014-03-19 19:07:28 UTC
Created attachment 272424 [details] [review]
Update the last installed timestamp after successful offline updates

This makes sure our internal timestamp is up to date after an external
app (e.g. gnome-shell) has triggered offline updates.
Comment 5 Kalev Lember 2014-03-19 19:07:32 UTC
Created attachment 272425 [details] [review]
Fix showing recently installed updates

This fixes the state tracking code so that the updates page doesn't get
stuck at "Looking for new updates…" after clicking 'Review' on the
notification.
Comment 6 Matthias Clasen 2014-03-19 21:24:48 UTC
One thing I notice while testing these patches: We don't seem to clear the update information anymore. The gs_offline_updates_clear_status() function is only called after we show an error, or if we trigger it explicitly via an action.

I get shown the update information about the last update every single time I launch gnome-software.
Comment 7 Matthias Clasen 2014-03-19 21:48:58 UTC
Review of attachment 272425 [details] [review]:

I don't think this is 100% right. I don't see the 'Looking for new updates' text, but the headerbar now has the 'refresh' button visible, and it shows the number of installed updates in the tab button (6 on blue background).
Comment 8 Matthias Clasen 2014-03-20 00:45:04 UTC
Attachment 272423 [details] pushed as bfa2ade - Remove stale notifications after an offline update has completed
Attachment 272424 [details] pushed as 0e0fe27 - Update the last installed timestamp after successful offline updates
Attachment 272425 [details] pushed as 9dfd7ca - Fix showing recently installed updates
Comment 9 Matthias Clasen 2014-03-20 00:45:59 UTC
(In reply to comment #7)
> Review of attachment 272425 [details] [review]:
> 
> I don't think this is 100% right. I don't see the 'Looking for new updates'
> text, but the headerbar now has the 'refresh' button visible, and it shows the
> number of installed updates in the tab button (6 on blue background).

I've pushed a fix for these two things together with your other patches