All settings involving pinning are of the first-come-first-serve level.
Adding an exception for the default-release setting to have an effect on
all packages from this release "maybe" is just complicating a feature in
usage, documentation and code which is already very complicated – and
what makes default-release be so special, why not for all of them…
(which can't be done because behavior changes are a no-no in general).

Or in other words: You are arguing that default-release should not
override pinnings of packages but that doesn't happen. It overrides the
pinning of releases. If it wouldn't be doing that, what would be the
point…

The usecase for this is your very own usecase – or how do you overrule
your preferences setting in case you occasionally don't want the PPA to
take the lead?

You can use globs and regexes in preferences btw.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apt in Ubuntu.
https://bugs.launchpad.net/bugs/1565782

Title:
  APT doesn't respect pin-priority when using APT::Default-Release
  option

Status in apt package in Ubuntu:
  Invalid

Bug description:
  I'm trying to pin packages from the proprietary graphics drivers PPA,
  and I want APT to use this PPA even if a newer version is available in
  a target release, so I put it at a pin-priority of 999

  --- /etc/apt/preferences.d/graphics-drivers-ppa-pin-999
  Package: *
  Pin: release o=LP-PPA-graphics-drivers
  Pin-Priority: 999
  ---

  If I test this with 'apt-cache policy', the priorities seems to be
  correct.

  ---
  $ apt-cache policy nvidia-346
  nvidia-346:
    Installerad: 346.96-0ubuntu0~gpu14.04.2
    Kandidat:    346.96-0ubuntu0~gpu14.04.2
    Versionstabell:
       352.63-0ubuntu0.14.04.1 0
          500 http://se.archive.ubuntu.com/ubuntu/ trusty-updates/restricted 
amd64 Packages
          500 http://security.ubuntu.com/ubuntu/ trusty-security/restricted 
amd64 Packages
   *** 346.96-0ubuntu0~gpu14.04.2 0
          999 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu/ trusty/main 
amd64 Packages
          100 /var/lib/dpkg/status
  ---

  But if I use the 'APT::Default-Release' configuration option, the
  priority gets lowered to 990, resulting in the wrong candidate.

  ---
  $ apt-cache -o 'APT::Default-Release=trusty' policy nvidia-346
  nvidia-346:
    Installerad: 346.96-0ubuntu0~gpu14.04.2
    Kandidat:    352.63-0ubuntu0.14.04.1
    Versionstabell:
       352.63-0ubuntu0.14.04.1 0
          990 http://se.archive.ubuntu.com/ubuntu/ trusty-updates/restricted 
amd64 Packages
          990 http://security.ubuntu.com/ubuntu/ trusty-security/restricted 
amd64 Packages
   *** 346.96-0ubuntu0~gpu14.04.2 0
          990 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu/ trusty/main 
amd64 Packages
          100 /var/lib/dpkg/status
  ---

  The same thing happens when using apt-get/aptitude's '-t' flag, i.e.
  the wrong version gets marked for installation. It seems the policy
  engine sets the priority to 990 if the package matches the target
  release, regardless of the previous (higher) value. I think this
  behavior is a bug and should be fixed so that a certain package's
  priority doesn't get lowered for belonging to the target release.

  ProblemType: Bug
  DistroRelease: Ubuntu 14.04
  Package: apt 1.0.1ubuntu2.11
  ProcVersionSignature: Ubuntu 3.13.0-83.127-generic 3.13.11-ckt35
  Uname: Linux 3.13.0-83-generic x86_64
  NonfreeKernelModules: nvidia
  ApportVersion: 2.14.1-0ubuntu3.19
  Architecture: amd64
  Date: Mon Apr  4 14:11:26 2016
  InstallationDate: Installed on 2014-08-08 (605 days ago)
  InstallationMedia: Ubuntu 14.04.1 LTS "Trusty Tahr" - Release amd64 
(20140722.2)
  ProcEnviron:
   TERM=xterm-256color
   SHELL=/bin/bash
   PATH=(custom, user)
   LANG=sv_SE.UTF-8
   XDG_RUNTIME_DIR=<set>
  SourcePackage: apt
  UpgradeStatus: No upgrade log present (probably fresh install)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1565782/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to     : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to