[Bug 2067071] Re: cannot upgrade from 23.10 to 24.04, error in _install_t64_replacement_packages
Nick Rosbrook
2067071 at bugs.launchpad.net
Tue Jun 18 14:44:28 UTC 2024
I have verified the fix using ubuntu-release-upgrader from noble-
proposed (via do-release-upgrade --proposed):
root at m:~# cat /etc/os-release
PRETTY_NAME="Ubuntu 23.10"
NAME="Ubuntu"
VERSION_ID="23.10"
VERSION="23.10 (Mantic Minotaur)"
VERSION_CODENAME=mantic
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=mantic
LOGO=ubuntu-logo
root at m:~# apt install -y libts0
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following NEW packages will be installed:
libts0
0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
Need to get 62.0 kB of archives.
After this operation, 313 kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu mantic/universe amd64 libts0 amd64 1.22-1 [62.0 kB]
Fetched 62.0 kB in 0s (136 kB/s)
Selecting previously unselected package libts0:amd64.
(Reading database ... 33603 files and directories currently installed.)
Preparing to unpack .../libts0_1.22-1_amd64.deb ...
Unpacking libts0:amd64 (1.22-1) ...
Setting up libts0:amd64 (1.22-1) ...
Processing triggers for man-db (2.11.2-3) ...
Processing triggers for libc-bin (2.38-1ubuntu6.3) ...
Scanning processes...
No services need to be restarted.
No containers need to be restarted.
No user sessions are running outdated binaries.
No VM guests are running outdated hypervisor (qemu) binaries on this host.
root at m:~# cat > /etc/apt/preferences.d/lp2067071 << EOF
Package: libts0t64
Pin: release a=noble
Pin-Priority: -1
EOF
root at m:~# do-release-upgrade --proposed
Checking for a new Ubuntu release
= Welcome to Ubuntu 24.04 LTS 'Noble Numbat' =
The Ubuntu team is proud to announce Ubuntu 24.04 LTS 'Noble Numbat'.
To see what's new in this release, visit:
https://wiki.ubuntu.com/NobleNumbat/ReleaseNotes
Ubuntu is a Linux distribution for your desktop or server, with a fast
and easy install, regular releases, a tight selection of excellent
applications installed by default, and almost any other software you
can imagine available through the network.
We hope you enjoy Ubuntu.
== Feedback and Helping ==
If you would like to help shape Ubuntu, take a look at the list of
ways you can participate at
http://www.ubuntu.com/community/participate/
Your comments, bug reports, patches and suggestions will help ensure
that our next release is the best release of Ubuntu ever. If you feel
that you have found a bug please read:
http://help.ubuntu.com/community/ReportingBugs
Then report bugs using apport in Ubuntu. For example:
ubuntu-bug linux
will open a bug report in Launchpad regarding the linux package.
If you have a question, or if you think you may have found a bug but
aren't sure, first try asking on the #ubuntu or #ubuntu-bugs IRC
channels on Libera.Chat, on the Ubuntu Users mailing list, or on the
Ubuntu forums:
http://help.ubuntu.com/community/InternetRelayChat
http://lists.ubuntu.com/mailman/listinfo/ubuntu-users
http://www.ubuntuforums.org/
== More Information ==
You can find out more about Ubuntu on our website, IRC channel and wiki.
If you're new to Ubuntu, please visit:
http://www.ubuntu.com/
To sign up for future Ubuntu announcements, please subscribe to Ubuntu's
very low volume announcement list at:
http://lists.ubuntu.com/mailman/listinfo/ubuntu-announce
Continue [yN] y
Get:1 Upgrade tool signature [833 B]
Get:2 Upgrade tool [1282 kB]
Fetched 1283 kB in 0s (0 B/s)
authenticate 'noble.tar.gz' against 'noble.tar.gz.gpg'
extracting 'noble.tar.gz'
[screen is terminating]
root at m:~# cat /etc/os-release
PRETTY_NAME="Ubuntu 24.04 LTS"
NAME="Ubuntu"
VERSION_ID="24.04"
VERSION="24.04 LTS (Noble Numbat)"
VERSION_CODENAME=noble
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=noble
LOGO=ubuntu-logo
** Description changed:
[Impact]
Upgrades to Noble may crash while searching for t64 replacement
packages.
[Test Plan]
One way to reproduce this is by setting Pin-Priority: -1 for a t64
replacement package so that `replacement` will have no candidate.
$ apt install -y libts0
$ cat > /etc/apt/preferences.d/lp2067071 << EOF
Package: libts0t64
Pin: release a=noble
Pin-Priority: -1
EOF
- $ do-release-upgrade
+ $ do-release-upgrade --proposed
Before the patch, that will lead to the same crash shown in this bug
report.
[Where problems could occur]
The patch is confined to the t64 replacement quirk. Any other issues
would be there. The fix is to simply make sure the replacement has a
candidate (i.e. replacement.candidate is not None) before accessing more
attributes.
[Original Description]
it crashes while calculating space - cannot proceed to package
downloading.
short from the logs:
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeCache.py", line 497, in pre_upgrade_rule
self.quirks.run("PreDistUpgradeCache")
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeQuirks.py", line 95, in run
func()
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeQuirks.py", line 191, in PreDistUpgradeCache
self._install_t64_replacement_packages()
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeQuirks.py", line 1845, in _install_t64_replacement_packages
if replacement.candidate._cand != ver:
^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute '_cand'
full logs attached as files.
** Tags removed: verification-needed verification-needed-noble
** Tags added: verification-done verification-done-noble
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/2067071
Title:
cannot upgrade from 23.10 to 24.04, error in
_install_t64_replacement_packages
Status in ubuntu-release-upgrader package in Ubuntu:
Invalid
Status in ubuntu-release-upgrader source package in Noble:
Fix Committed
Bug description:
[Impact]
Upgrades to Noble may crash while searching for t64 replacement
packages.
[Test Plan]
One way to reproduce this is by setting Pin-Priority: -1 for a t64
replacement package so that `replacement` will have no candidate.
$ apt install -y libts0
$ cat > /etc/apt/preferences.d/lp2067071 << EOF
Package: libts0t64
Pin: release a=noble
Pin-Priority: -1
EOF
$ do-release-upgrade --proposed
Before the patch, that will lead to the same crash shown in this bug
report.
[Where problems could occur]
The patch is confined to the t64 replacement quirk. Any other issues
would be there. The fix is to simply make sure the replacement has a
candidate (i.e. replacement.candidate is not None) before accessing
more attributes.
[Original Description]
it crashes while calculating space - cannot proceed to package
downloading.
short from the logs:
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeCache.py", line 497, in pre_upgrade_rule
self.quirks.run("PreDistUpgradeCache")
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeQuirks.py", line 95, in run
func()
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeQuirks.py", line 191, in PreDistUpgradeCache
self._install_t64_replacement_packages()
File "/tmp/ubuntu-release-upgrader-4lhpwkx7/DistUpgrade/DistUpgradeQuirks.py", line 1845, in _install_t64_replacement_packages
if replacement.candidate._cand != ver:
^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute '_cand'
full logs attached as files.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-release-upgrader/+bug/2067071/+subscriptions
More information about the foundations-bugs
mailing list