main.log doesn't always report right version of python-apt

Bug #1306065 reported by Brian Murray
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ubuntu-release-upgrader (Ubuntu)
Fix Released
High
Brian Murray

Bug Description

This may actually be a bug with python-apt or apt but I noticed this when verifying bug 1286161.

"Strangely looking at main.log it shows the wrong version of apt being used but installed packages in the apt-clone file shows the correct version. Testing what the release upgrader uses exhibits the same behaviour."

Setting up apt (0.9.9.1~ubuntu3.1) ...
gpg: key 437D05B5: "Ubuntu Archive Automatic Signing Key <email address hidden>" not changed
gpg: key FBB75451: "Ubuntu CD Image Automatic Signing Key <email address hidden>" not changed
gpg: key C0B21F32: "Ubuntu Archive Automatic Signing Key (2012) <email address hidden>" not changed
gpg: key EFE21092: "Ubuntu CD Image Automatic Signing Key (2012) <email address hidden>" not changed
gpg: Total number processed: 4
gpg: unchanged: 4
(saucy-amd64)root@impulse:/home/bdmurray# python -c 'import apt; print apt.apt_pkg.VERSION'
0.9.9.1~ubuntu1

Tags: saucy xenial

Related branches

Changed in ubuntu-release-upgrader (Ubuntu):
importance: Undecided → High
tags: added: saucy
Changed in ubuntu-release-upgrader (Ubuntu):
assignee: nobody → Shafi Ur Rehman (shafi-khattak66)
status: New → Confirmed
Revision history for this message
Brian Murray (brian-murray) wrote :

This is actually because apt.apt_pkg.VERSION isn't always updated. Instead of using that we should query the cache to figure out what version of apt is installed.

Changed in ubuntu-release-upgrader (Ubuntu):
assignee: Shafi Ur Rehman (shafi-khattak66) → Brian Murray (brian-murray)
status: Confirmed → Triaged
Changed in ubuntu-release-upgrader (Ubuntu):
status: Triaged → In Progress
tags: added: xenial
Revision history for this message
Brian Murray (brian-murray) wrote :

This may be worth SRU'ing to Vivid since Trusty users may still be upgrading to that release.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntu-release-upgrader - 1:16.04.4

---------------
ubuntu-release-upgrader (1:16.04.4) xenial; urgency=medium

  * DistUpgrade/DistUpgradeMain.py: check the apt cache to see what version of
    apt is installed rather than using the apt VERSION string. (LP: #1306065)
  * test/test_sources_list.py: resolve test failures.
  * DistUpgrade/DistUpgradeCache.py: log packages which will be downgraded.
  * DistUpgrade/DistUpgradeNonInteractive.py: Ensure output when using
    is not garbled as single bytestream escaped characters. Thanks to
    Christopher Lee for the patch. (LP: #1538880)

 -- Brian Murray <email address hidden> Thu, 28 Jan 2016 15:39:09 -0800

Changed in ubuntu-release-upgrader (Ubuntu):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.