Merge lp:~brian-murray/update-manager/bug-1826213 into lp:update-manager

Proposed by Brian Murray
Status: Merged
Merged at revision: 2888
Proposed branch: lp:~brian-murray/update-manager/bug-1826213
Merge into: lp:update-manager
Diff against target: 50 lines (+16/-2)
2 files modified
UpdateManager/UpdateManager.py (+7/-2)
debian/changelog (+9/-0)
To merge this branch: bzr merge lp:~brian-murray/update-manager/bug-1826213
Reviewer Review Type Date Requested Status
Ubuntu Core Development Team Pending
Review via email: mp+384673@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'UpdateManager/UpdateManager.py'
2--- UpdateManager/UpdateManager.py 2020-04-08 15:56:20 +0000
3+++ UpdateManager/UpdateManager.py 2020-05-27 20:25:14 +0000
4@@ -235,6 +235,9 @@
5 self._look_busy()
6 self.refresh_cache()
7
8+ if self.cache is None:
9+ return
10+
11 pane = self._make_available_pane(self.cache.install_count
12 + self.cache.del_count,
13 os.path.exists(REBOOT_REQUIRED_FILE),
14@@ -376,7 +379,8 @@
15 "Please use the package manager \"Synaptic\" or run "
16 "\"sudo apt-get install -f\" in a terminal to fix "
17 "this issue at first.")
18- self.start_error(True, header, desc)
19+ self.start_error(False, header, desc)
20+ return
21 except SystemError as e:
22 header = _("Could not initialize the package information")
23 desc = _("An unresolvable problem occurred while "
24@@ -384,7 +388,8 @@
25 "Please report this bug against the 'update-manager' "
26 "package and include the following error "
27 "message:\n") + str(e)
28- self.start_error(True, header, desc)
29+ self.start_error(False, header, desc)
30+ return
31
32 # Let the Gtk event loop breath if it hasn't had a chance.
33 def iterate():
34
35=== modified file 'debian/changelog'
36--- debian/changelog 2020-04-23 17:47:54 +0000
37+++ debian/changelog 2020-05-27 20:25:14 +0000
38@@ -1,3 +1,12 @@
39+update-manager (1:20.04.11) UNRELEASED; urgency=medium
40+
41+ * UpdateManager/UpdateManager.py: when refreshing the cache and encountering
42+ an error return rather than trying to use the undefined cache which causes
43+ crashes. Additionally, don't present the dialog with a "Try Again" button
44+ which won't do anything. (LP: #1826213)
45+
46+ -- Brian Murray <brian@ubuntu.com> Wed, 27 May 2020 11:45:53 -0700
47+
48 update-manager (1:20.04.10) focal; urgency=medium
49
50 * Fix intermittent hang during snap updates (LP: #1874469).

Subscribers

People subscribed via source and target branches

to status/vote changes: