Cannot upgrade to 15.10 using alternate AMD64 ISO
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ubuntu-release-upgrader (Ubuntu) |
Fix Released
|
Medium
|
Brian Murray | ||
Wily |
Invalid
|
Medium
|
Unassigned |
Bug Description
# lsb_release -rd
Description: Ubuntu 15.10
Release: 15.10
# apt-cache policy python3-distupgrade
python3-
Installed: 1:15.10.14.4
Candidate: 1:15.10.14.4
Version table:
*** 1:15.10.14.4 0
500 http://
100 /var/lib/
1:15.10.13 0
500 http://
I am a Lubuntu AMD64 user. I was on Lubuntu 14.10 and needed to upgrade. After successfully upgrading to vivid/15.04, I then tried to upgrade to wily/15.10. In both cases, I used the alternate ISO.
First, I downloaded the ISO file and mounted it to my local file system:
# sudo mount -o loop ~/Desktop/
Second, I executed the upgrade script and chose the 'no network' option:
# sudo /mnt/cdromupgrade
But it failed early in the sequence of events. The relevant part of the /var/log/
2016-02-28 12:19:17,788 ERROR not handled exception:
Traceback (most recent call last):
File "/tmp/tmp.
sys.
File "/tmp/tmp.
if app.run():
File "/tmp/tmp.
return self.fullUpgrade()
File "/tmp/tmp.
not self.aptcdrom.
File "/usr/lib/
res = self._doAdd()
File "/usr/lib/
if self._verifyRel
File "/usr/lib/
sum = apt_pkg.
TypeError: invalid file: <_io.TextIOWrapper name='/
After some detective work, I was able to upgrade to wily by removing the 'open' call in line 227:
sum = apt_pkg.
An important step in the detective work was to inspect the changes to the DistUpgradeAptC
(http://
There, we can see that the line:
sum = apt_pkg.
was changed to:
with open(f) as fp:
sum = apt_pkg.
The end result is that a call to open() was changed to use a with/as statement, as part of a substantial commit to improve the robustness of the code. But for this line, it introduced two open calls instead of just one, and that is clearly wrong, as the first open call will return a File object, and the second will try to open the consequent File object, which will result in a Type error.
Revision 2859 was done about a year ago, and refers to LP #1409555, which seems to indicate that the fix was added in 15.04. It explains why I was able to upgrade to 15.04 but not to 15.10.
Related branches
Changed in ubuntu-release-upgrader (Ubuntu): | |
status: | New → Triaged |
importance: | Undecided → Medium |
assignee: | nobody → Brian Murray (brian-murray) |
Changed in ubuntu-release-upgrader (Ubuntu Wily): | |
status: | New → Triaged |
importance: | Undecided → Medium |
Changed in ubuntu-release-upgrader (Ubuntu Wily): | |
status: | Triaged → Invalid |
Thanks for the investigative work! I'll get this fixed shortly.