Confirmed here that /var/lib/ubuntu-advantage/status.json is only updated when running 'ua status' as root.
No desktop software is running as root, in the few cases that root privileges are required a small service is run as root and that is communicated with via D-Bus.
The warning doesn't show for the majority of users, since they aren't going to be running from the command line so I would leave it for now, and remove in the next revision of this code.
I think there is a case where this won't work - if you have a fresh machine that you haven't done a 'ua attach' on then software-properties is going to not offer ESM as it's not going to think it's available.
Confirmed here that /var/lib/ ubuntu- advantage/ status. json is only updated when running 'ua status' as root.
No desktop software is running as root, in the few cases that root privileges are required a small service is run as root and that is communicated with via D-Bus.
The warning doesn't show for the majority of users, since they aren't going to be running from the command line so I would leave it for now, and remove in the next revision of this code.
I think there is a case where this won't work - if you have a fresh machine that you haven't done a 'ua attach' on then software-properties is going to not offer ESM as it's not going to think it's available.
In https:/ /code.launchpad .net/~robert- ancell/ software- properties/ +git/software- properties/ +merge/ 400153 that 'ua status' can timeout and return empty values, which is why we are accessing /var/lib/ ubuntu- advantage/ status. json. 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?