[Bug 1920836] Re: Show Extended Security Maintenence status

Chad Smith 1920836 at bugs.launchpad.net
Wed Jul 14 21:06:50 UTC 2021


@robert-ancell and @corradoventu those errors are due to running
software-properties-gtk as non-root user on a system that is not
attached to any ubuntu-advantage services.

 The /var/lib/ubuntu-advantage/status.json file is only created by a
root user via an `sudo ua status` or `sudo ua attach <token>` call. The
absence of the file means that the system is not attached to any valid
Ubuntu Advantage services, and the logic in
softwareproperties/gtk/util.py will still correctly return an empty
representation for ubuntu-advantage services as an empty dict {} and the
UX dialogs properly direct folks to how to activate ESM in this case.


I mistakenly thought software-properties-gtk is invoked as root user in order to install/update packages. Given that it is invoked as non-root user we can do one of two things:
   1. keep the current implementation which would print messages about missing status.json files knowing that the UX dialogs still behave correctly.
OR
   2. drop the subp call to 'ua' 'status' from utils.py:get_ua_status() because they will never emit the /var/lib/ubuntu-advantage/status.json artifact and also drop the printed messages about No ua status file written as that really only means you are non-root and on an unattached machine.

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to software-properties in Ubuntu.
https://bugs.launchpad.net/bugs/1920836

Title:
  Show Extended Security Maintenence status

Status in software-properties package in Ubuntu:
  Fix Released
Status in software-properties source package in Xenial:
  New
Status in software-properties source package in Bionic:
  Fix Committed
Status in software-properties source package in Focal:
  Fix Committed
Status in software-properties source package in Hirsute:
  Fix Committed

Bug description:
  [Impact]
  There is not currently a graphical method of determining if a system is subscribed to [Extended Security Maintenance](https://ubuntu.com/security/esm) updates. This is resolved by adding some [new UI](https://wiki.ubuntu.com/SoftwareUpdates#Extended_Security_Maintenance) to the software properties application.

  [Test Case]
  1. Install latest version of Ubuntu advantage:
  $ sudo add-apt-repository ppa:ua-client/stable
  $ sudo apt update
  $ sudo apt upgrade
  2. Open Software Properties
  3. Go to Updates tab.

  Expected result:
  Information is shown that indicates if this system is using Extended Security Maintenance updates, when updates will supported until, and a link to upgrade to ESM.

  Observed result:
  No ESM information currently shown.

  [Where problems could occur]
  - Software properties could hit a bug getting a response from the ua app. The current code carefully checks if and what is returned, falling back to a safe default behavior.
  - Launching software properties could trigger a bug in the ua app.
  - Software properties could show incorrect information, causing confusion for the user. The solution uses information from distro-info and the ua app which means software-properties contains no data about ESM, and instead relies on these apps that can be updated if things change.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/software-properties/+bug/1920836/+subscriptions




More information about the foundations-bugs mailing list