>> Is there a reason why the ua client doesn't do this itself
internally, i.e. it gives you fresh json or returns the cached copy if
it can't do the update?

Currently the only "time" during which ubuntu-advantage-tools (UA
client) could perform the logic to exec 'sudo ua status' is during
postinst at package install upgrade time. UA client can not perform that
status setup during package install for the same timeout reasons you
mentioned.  It is a potentially long operation. If run during a package
install it could delay or prevent other package upgrades if it hits a
timeout and/or error. That said, we are working on instrumenting a
systemd timer service that can run config change/setup operations out of
band of typical APT package installs. So, this case could be handled by
that timer-based service.  This SRU does represent.

This changeset as-is does represent an improvement to existing cases
because the Software properties UX demonstrates awareness of ESM (and
contract expiry information) properly for attached machines, or
unattached machines where `sudo ua status` has been run.

Subsequent releases of software-properties will now be able to take
advantage of reading "ua status --format=json" output directly as non-
root (due to a bug-fix released in 27.2.1). The non-root user will not
have to rely anymore on that json file if absent as the --format=json
output will render the same JSON dict that would be present on disk for
the root user. This is a fix that is under verification in the -proposed
queue now for ua-tools and was not available at the time of this
original software-properties PR. I'm ok with this approach as-is knowing
that we can significantly improve the behavior once ubuntu-advantage-
tools 27.2.1 is released to X B F and H

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, 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


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to     : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to