Exceptions in the state machine (D-Bus) should result in UpdateAvailableStatus with an error_reason

Bug #1250817 reported by errors.ubuntu.com bug bridge
52
This bug affects 22 people
Affects Status Importance Assigned to Milestone
Ubuntu system image
Fix Released
High
Barry Warsaw
system-image (Ubuntu)
Fix Released
High
Barry Warsaw

Bug Description

The Ubuntu Error Tracker has been receiving reports about a problem regarding system-image. This problem was most recently seen with version 1.9.1-0ubuntu1, the problem page at https://errors.ubuntu.com/problem/99f4f3e3ccd3d0349d82e550e0b8bd7af389feea contains more details.

Related branches

Revision history for this message
Barry Warsaw (barry) wrote :

This looks like a network error coming from u-d-m. There's not much system-image can do if ubuntu-download-manager can't make a network connection.

Changed in system-image (Ubuntu):
status: New → Invalid
Revision history for this message
Sebastien Bacher (seb128) wrote :

@Barry: can you trap the exception?

The current situation is that when it happens users get a whoopsie error dialog in the middle if their screen ... we can't consider that a normal user experience.

Either it's a real issue and we fix it, or it's a transient issue which is fine to ignore and we don't make whoopsie bother the user to report it...

Changed in system-image (Ubuntu):
status: Invalid → New
Revision history for this message
Barry Warsaw (barry) wrote :

Service._check_for_update() should catch exceptions that occur in the state machine (such as this one) and return UpdateAvailableStatus() with an appropriate error_reason.

Changed in system-image (Ubuntu):
status: New → Triaged
tags: added: client
Changed in ubuntu-system-image:
milestone: none → 2.1
status: New → Triaged
summary: - /usr/sbin/system-image-
- dbus:FileNotFoundError:<lambda>:_check_for_update:check_for_update:run_until:_get_blacklist_1:get_keyring:get_files
+ FileNotFoundErrors coming from u-d-m should result in
+ UpdateAvailableStatus with an error_reason
Barry Warsaw (barry)
Changed in ubuntu-system-image:
importance: Undecided → Medium
Changed in system-image (Ubuntu):
importance: Undecided → Medium
Barry Warsaw (barry)
Changed in ubuntu-system-image:
milestone: 2.1 → none
Barry Warsaw (barry)
Changed in ubuntu-system-image:
status: Triaged → In Progress
importance: Medium → High
assignee: nobody → Barry Warsaw (barry)
milestone: none → 2.2
Changed in system-image (Ubuntu):
status: Triaged → In Progress
importance: Medium → High
assignee: nobody → Barry Warsaw (barry)
Barry Warsaw (barry)
summary: - FileNotFoundErrors coming from u-d-m should result in
- UpdateAvailableStatus with an error_reason
+ Exceptions in the state machine should result in UpdateAvailableStatus
+ with an error_reason
summary: - Exceptions in the state machine should result in UpdateAvailableStatus
- with an error_reason
+ Exceptions in the D-Bus state machine should result in
+ UpdateAvailableStatus with an error_reason
summary: - Exceptions in the D-Bus state machine should result in
+ Exceptions in the state machine (D-Bus) should result in
UpdateAvailableStatus with an error_reason
Barry Warsaw (barry)
Changed in ubuntu-system-image:
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package system-image - 2.2-0ubuntu1

---------------
system-image (2.2-0ubuntu1) trusty; urgency=medium

  [ Barry Warsaw ]
  * New upstream release.
    - LP: #1284217 - When CheckForUpdate() is called a second time, while
      an auto-download is in progress, but after the first check is
      complete, we send an UpdateAvailableStatus signal with the cached
      information.
    - LP: #1287919 - Close a race condition when manually downloading and
      issuing multiple CheckForUpdate calls.
    - LP: #1278589 - Support disabling either HTTP or HTTPS services for
      custom system image servers.
    - Allow the channel.ini file to override the [service] section.
    - LP: #1287287 - Do not do atomic renames of temporary download files;
      ubuntu-download-manager now supports this by default.
    - LP: #1250817 - Exceptions in the state machine are caught and
      logged, with an appropriate error message added to
      UpdateAvailableStatus signals. These exceptions do not percolate up
      to the GLib main loop.
    - LP: #1279532 - During testing, pass the log dir argument to
      ubuntu-download-manager.
  * d/rules: Add override_dh_python3 rule to set shebang line to
    /usr/bin/python3. (LP: #1283277)
  * d/patches/lp1284217.patch: Removed; applied upstream.
 -- Ubuntu daily release <email address hidden> Mon, 17 Mar 2014 17:28:16 +0000

Changed in system-image (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Sebastien Bacher (seb128) wrote :

Reopening, that's still an issue with 2.2, see e.g https://errors.ubuntu.com/oops/3a22e620-af85-11e3-8908-2c768aafd08c

"Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/systemimage/dbus.py", line 86, in _check_for_update
    self._update = self._api.check_for_update()
  File "/usr/lib/python3/dist-packages/systemimage/api.py", line 96, in check_for_update
    self._state.run_until('download_files')
  File "/usr/lib/python3/dist-packages/systemimage/state.py", line 175, in run_until
    step()
  File "/usr/lib/python3/dist-packages/systemimage/state.py", line 209, in _get_blacklist_1
    'image-master', 'gpg/image-master.tar.xz', 'archive-master')
  File "/usr/lib/python3/dist-packages/systemimage/keyring.py", line 107, in get_keyring
    (ascxz_src, ascxz_dst),
  File "/usr/lib/python3/dist-packages/systemimage/download.py", line 205, in get_files
    fd, path = tempfile.mkstemp(suffix='.tmp', prefix='', dir=head)
  File "/usr/lib/python3.4/tempfile.py", line 409, in mkstemp
    return _mkstemp_inner(dir, prefix, suffix, flags)
  File "/usr/lib/python3.4/tempfile.py", line 339, in _mkstemp_inner
    fd = _os.open(file, flags, 0o600)
FileNotFoundError: [Errno 2] No such file or directory: '/android/cache/recovery/btxk4vie.tmp'"

Changed in ubuntu-system-image:
status: Fix Committed → Confirmed
Changed in system-image (Ubuntu):
status: Fix Released → Confirmed
Revision history for this message
Barry Warsaw (barry) wrote :

Please attach a new /var/log/system-image/client.log file and provide some detail on how you reproduced this. Thanks!

Barry Warsaw (barry)
Changed in ubuntu-system-image:
status: Confirmed → Fix Released
Changed in system-image (Ubuntu):
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.