[Bug 1821308] Re: apt-get upgrade ignores pinning preferences since 1.0.1ubuntu2.22
larsen
1821308 at bugs.launchpad.net
Mon Mar 25 17:11:34 UTC 2019
I have enabled the "proposed" repository and installed apt
"1.0.1ubuntu2.23". Though, even after another "apt-get update", "apt-get
upgrade" still wants to downgrade my "burp" package.
It's noticeable that "policy's output" now contains a different
"Candidate" version number.
# dpkg -l apt
(snip)
ii apt 1.0.1ubuntu2.23
amd64 commandline package manager
# apt-cache policy burp
burp:
Installed: 2.0.54-1
Candidate: 1.3.48-4
Package pin: 2.0.54-1
Version table:
*** 2.0.54-1 1000
100 /var/lib/dpkg/status
1.3.48-4 1000
500 https://ftp-stud.hs-esslingen.de/ubuntu/ trusty/universe amd64
Packages
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to apt in Ubuntu.
https://bugs.launchpad.net/bugs/1821308
Title:
apt-get upgrade ignores pinning preferences since 1.0.1ubuntu2.22
Status in apt package in Ubuntu:
Invalid
Status in apt source package in Trusty:
Fix Committed
Bug description:
[Impact]
Pinning on local-only package versions is ignored, causing them to be upgraded.
[Test case]
The integration tests run in autopkgtest include an automated test case that contains a package called coolstuff in three versions. We are specifying a Pin for the installed one, set to 1000.
The bug caused 1.0 to become the candidate, as the existing pin was
ignored. The test checks that 2.0~bpo1 to remains the candidate, that
is, apt-cache policy looks like this:
coolstuff:
Installed: 2.0~bpo1
Candidate: 2.0~bpo1
Package pin: 2.0~bpo1
Version table:
2.0~bpo2 1000
100 file:${tmppath}/aptarchive/ backports/main i386 Packages
*** 2.0~bpo1 1000
100 ${tmppath}/rootdir/var/lib/dpkg/status
1.0 1000
500 file:${tmppath}/aptarchive/ stable/main i386 Packages
On the output of the autopkgtest we'll see:
Check that local-only versions can be pinned correctly (LP: #1821308)
Test for successful execution of apt-cache policy coolstuff … PASS
Test for correctness of file testsuccess.output … PASS
[Regression potential]
Other weird pinning bugs.
[Original bug report]
I have updated apt this morning:
Start-Date: 2019-03-22 09:36:18
Commandline: apt-get dist-upgrade
Upgrade: apt:amd64 (1.0.1ubuntu2.20, 1.0.1ubuntu2.22), ...
Afterwards, apt-get ignores my pinning preferences:
# apt-get --dry-run upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages will be DOWNGRADED:
burp
0 upgraded, 0 newly installed, 1 downgraded, 0 to remove and 0 not upgraded.
Inst burp [2.0.54-1] (1.3.48-4 Ubuntu:14.04/trusty [amd64])
Conf burp (1.3.48-4 Ubuntu:14.04/trusty [amd64])
# cat /etc/apt/preferences.d/burp.pref
Package: burp
Pin: version 2.0.54*
Pin-Priority: 1000
This might be caused by bug 1814727 as it's the only thing I can see
in the changelog regarding apt/pinning.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1821308/+subscriptions
More information about the foundations-bugs
mailing list