linuxmint / mintupdate

The Linux Mint Update Manager
326 stars 158 forks source link

Silently failed flatpak update appears in history with the new version column containing the error message – and screen shows "system is up to date" until refresh #890

Closed carlosmintfan closed 1 month ago

carlosmintfan commented 3 months ago

Describe the bug When a flatpak update fails, I don't know if sometimes there are error messages but this time, it failed silently: I updated wpasupplicant and a flatpak runtime, and as wpasupplicant disconnected me from my wifi, the flatpak update after that failed. However, I think I didn't see an error message: It just failed silently and even showed "system is up to date" until I opened settings or something like that after which a non-full refresh gets triggered – and the flatpak update appeared again. However, in the update history, the failed flatpak update appears – with the new version column containing the error message.

Screenshots Screenshot showing update history

To Reproduce Steps to reproduce the behavior: (As there isn't always an update for wpasupplicant, I'll try to reproduce the issue by disconnecting from the internet before updating the flatpak).

  1. Disconnect from the internet
  2. Update an available flatpak
  3. After clicking "install updates", the window gets unresponsive (as it should) and the mouse spins – but only for a second, then everything is up to normal again. As opposed to the screen showing "system is up to date", in this case (there are also APT updates available which I didn't select), the update is still selected and everything is like before. However, no error message.
  4. Actually, the update history doesn't show the update now, hmm. Let's try to do all APT updates together with the flatpak and disconnect from the internet when the APT updates have been downloaded and are in applying phase.
  5. Yes, now it shows "system is up to date" and the update history shows the update with the error message in new version field again.

Expected behavior An error message should show for the failed Flatpak update and the history shouldn't show failed updates – or if it shows them, clearly mark them as such instead of putting the error message into the new version field.

Distribution: Tested in Mint 21.3 Cinnamon

Software version: 6.0.9

Logs:

08.09@13:11 ++ Launching Update Manager
08.09@13:11 ++ Changes to the package cache detected, triggering refresh
08.09@13:11 ++ Inhibited power management
08.09@13:11 ++ Initial refresh will happen in 0 day(s), 0 hour(s) and 10 minute(s)
08.09@13:11 ++ Starting refresh (local only)
08.09@13:11 ++ Tracker: Mintupdate update button was pressed recently: 2 days ago
08.09@13:11 ++ Found 5 software updates
08.09@13:11 ++ Refresh finished
08.09@13:11 ++ Resumed power management
08.09@13:18 ++ Inhibited power management
08.09@13:18 ++ Install requested by user
08.09@13:18 ++ Resumed power management
08.09@13:19 ++ Inhibited power management
08.09@13:19 ++ Install requested by user
08.09@13:19 ++ Resumed power management
08.09@13:21 ++ Update Manager window is open, skipping initial refresh
08.09@13:21 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:21 ++ Inhibited power management
08.09@13:21 ++ Install requested by user
08.09@13:21 ++ Will install firefox-locale-de
08.09@13:21 ++ Will install firefox-locale-en
08.09@13:21 ++ Will install firefox
08.09@13:21 ++ Will install krb5-locales
08.09@13:21 ++ Will install libgssapi-krb5-2
08.09@13:21 ++ Will install libkrb5support0
08.09@13:21 ++ Will install libkrb5-3
08.09@13:21 ++ Will install libk5crypto3
08.09@13:21 ++ Will install linux-headers-generic
08.09@13:21 ++ Will install linux-generic
08.09@13:21 ++ Will install linux-image-generic
08.09@13:21 ++ Will install linux-libc-dev
08.09@13:21 ++ Will install code
08.09@13:21 ++ Ready to launch synaptic

(synaptic:4496): Gtk-CRITICAL **: 13:21:46.193: gtk_widget_hide: assertion 'GTK_IS_WIDGET (widget)' failed
08.09@13:22 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:23 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:24 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:25 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:26 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:27 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:28 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:29 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:30 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:31 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:32 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:33 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:34 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:35 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:36 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:37 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)
08.09@13:38 ++ Update Manager window is open, delaying recurring refresh by 60s
08.09@13:39 ++ Return code:0
08.09@13:39 ++ Install finished
08.09@13:39 ++ Resumed power management
08.09@13:39 ++ Inhibited power management
08.09@13:39 ++ Starting refresh (local only)
08.09@13:39 ++ System is up to date
08.09@13:39 ++ Refresh finished
08.09@13:39 ++ Resumed power management
08.09@13:39 ++ Recurring refresh will happen in 0 day(s), 0 hour(s) and 1 minute(s)

Additional info: Related to #872 as not showing error messages.

mtwebster commented 1 month ago

https://github.com/linuxmint/mintupdate/commit/545f7bd300263c58b0be060aeae02c5e064da6cf