Public bug reported:

Hello
When I try to launch some ua command I get :
-----
root@server:~# ua status
Unexpected error(s) occurred.
For more details, see the log: /var/log/ubuntu-advantage.log
To file a bug run: ubuntu-bug ubuntu-advantage-tools
---

The log file indicate :

2021-11-11 08:46:29,270 - cli.py:(1456) [DEBUG]: Executed with sys.argv: 
['/usr/bin/ua', 'status']
2021-11-11 08:46:29,270 - util.py:(425) [DEBUG]: Reading file: 
/var/lib/ubuntu-advantage/private/machine-token.json
2021-11-11 08:46:29,274 - util.py:(425) [DEBUG]: Reading file: 
/var/lib/ubuntu-advantage/notices.json
2021-11-11 08:46:29,274 - cli.py:(1426) [ERROR]: Unhandled exception, please 
file a bug
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/uaclient/cli.py", line 1385, in wrapper
    return func(*args, **kwargs)
  File "/usr/lib/python3/dist-packages/uaclient/cli.py", line 1471, in main
    return args.action(args, cfg=cfg)
  File "/usr/lib/python3/dist-packages/uaclient/cli.py", line 1257, in 
action_status
    status = cfg.status(show_beta=show_beta)
  File "/usr/lib/python3/dist-packages/uaclient/config.py", line 747, in status
    response = self._attached_status()
  File "/usr/lib/python3/dist-packages/uaclient/config.py", line 720, in 
_attached_status
    self._attached_service_status(ent, inapplicable_resources)
  File "/usr/lib/python3/dist-packages/uaclient/config.py", line 647, in 
_attached_service_status
    contract_status = ent.contract_status()
  File "/usr/lib/python3/dist-packages/uaclient/entitlements/base.py", line 
633, in contract_status
    entitlement_cfg = self.cfg.entitlements.get(self.name, {})
  File "/usr/lib/python3/dist-packages/uaclient/config.py", line 333, in 
entitlements
    for e in machine_token.get("resourceTokens", [])
  File "/usr/lib/python3/dist-packages/uaclient/config.py", line 333, in 
<genexpr>
    for e in machine_token.get("resourceTokens", [])
KeyError: 'type'

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: ubuntu-advantage-tools 27.1~16.04.1
ProcVersionSignature: Ubuntu 4.4.0-210.242-generic 4.4.262
Uname: Linux 4.4.0-210-generic i686
ApportVersion: 2.20.1-0ubuntu2.30
Architecture: i386
Date: Thu Nov 11 08:28:52 2021
InstallationDate: Installed on 2012-01-31 (3571 days ago)
InstallationMedia: Ubuntu-Server 11.10 "Oneiric Ocelot" - Release i386 
(20111011)
SourcePackage: ubuntu-advantage-tools
UpgradeStatus: Upgraded to xenial on 2021-03-08 (247 days ago)

** Affects: ubuntu-advantage-tools (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: apport-bug i386 third-party-packages xenial

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

Title:
  UA cli / Exception on launch

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-advantage-tools/+bug/1950576/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to