/usr/bin/ubuntu-advantage:UnboundLocalError:wrapper:main:action_security_status:security_status_dict:get_installed_packages_by_origin:__enter__:get_apt_pkg_cache:get_last_known_candidate:get_pkg_candidate_version:__enter__:get_apt_pkg_cache:/usr/bin/ubuntu-advantage@33:wrapper:_warn_about_new_version:check_for_new_version:get_last_known_candidate
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ubuntu-advantage-tools (Ubuntu) |
Fix Released
|
Medium
|
Grant Orndorff | ||
Xenial |
Fix Released
|
Undecided
|
Unassigned | ||
Bionic |
Fix Released
|
Undecided
|
Unassigned | ||
Focal |
Fix Released
|
Undecided
|
Unassigned | ||
Jammy |
Fix Released
|
Undecided
|
Unassigned | ||
Lunar |
Won't Fix
|
Undecided
|
Unassigned | ||
Mantic |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
[ Impact ]
When apt cannot be run as a normal user, and a pro command is run as a normal user, a bug occurs in the error handling. An UnboundLocalError occurs.
The fix is to give that variable an initial value so that it is not unbound during the error handling.
[ Test Plan ]
lxc launch ubuntu-daily:jammy test
lxc shell test
# now inside the container
# intentionally mess up permissions on apt-related files
chmod 600 /var/lib/dpkg
sudo -u ubuntu pro version
# that will give you a long backtrace if the bug is present
[ Where problems could occur ]
The changed code involves notifying the user if there is a newer version of u-a-t available. It runs at the end of every pro CLI command. If a mistake was made it could prevent pro from notifying users that an update is available. In the worst case, if the change causes a permanent error, then that would cause all pro commands to start exiting non-zero.
[ Original Description ]
The Ubuntu Error Tracker has been receiving reports about a problem regarding ubuntu-
If you do not have access to the Ubuntu Error Tracker and are a software developer, you can request it at http://
Related branches
- Simon Quigley (community): Approve
- Bryce Harrington (community): Approve
-
Diff: 35 lines (+8/-1)2 files modifieddebian/changelog (+6/-0)
uaclient/version.py (+2/-1)
description: | updated |
Changed in ubuntu-advantage-tools (Ubuntu): | |
status: | New → Triaged |
importance: | Undecided → Medium |
assignee: | nobody → Grant Orndorff (orndorffgrant) |
It seems like you're encountering an issue related to ubuntu- advantage- tools on your Ubuntu system. The provided link leads to the Ubuntu Error Tracker, which contains details about the problem, including affected package versions, stack traces, and individual crash reports. /errors. ubuntu. com/problem/ f81cc464c2fac37 0f79ae4c1c2f340 0b2eb55481) to get more information about the problem. Look for any details that might provide insights into the nature of the issue, affected packages, and potential workarounds.
To address this issue, you can take the following steps:
Review the Error Tracker Page:
Visit the provided link (https:/
Check for Updates:
Ensure that your system is up-to-date by running the following commands in the terminal:
sudo apt update
sudo apt upgrade
Nataniel :)