Bug#413021: /usr/bin/apt-get: "apt-get source package" doesn't fetch the most recent available version
Package: apt
Version: 0.6.46.4-0.1
Severity: normal
File: /usr/bin/apt-get
I've looked through a list of apt-src related bugs and there might be the one
relevant (#377424) but not exactly the same (here we fetch wrong version
instead of simply failing), so I've decided to file a new one.
I have next deb-src lines:
,----------------------------------------------------------------------------------
| deb-src http://mentors.debian.net/debian unstable main
| deb-src file:///net/itanix.localnet/share/debmirror/debian/ sid main contrib
`---
when
,--------------------------------------
| $> apt-cache policy dicomnifti
| dicomnifti:
| Installed: 2.23-1
| Candidate: 2.23-1
| Version table:
| 2.24-1~etch.apsy0 0
| 500 file: etch/main Packages
| *** 2.23-1 0
| 990 file: sid/main Packages
| 100 /var/lib/dpkg/status
`---
,--------------------------------------------------------------------------------------------------------------------
| $> apt-cache showsrc dicomnifti
| Package: dicomnifti
| Binary: dicomnifti
| Version: 2.24-1~etch.apsy0
| Maintainer: Michael Hanke <michael.hanke@gmail.com>
| Build-Depends: debhelper (>= 5), ctn-dev (>> 3.0.6-9), libniftiio-dev, dpatch, autoconf, zlib1g-dev, autotools-dev
| Architecture: any
| Standards-Version: 3.7.2
| Format: 1.0
| Directory: dists/etch/main/source/science
| Files:
| 6984eb16b21852451c51e3a1c3f98551 677 dicomnifti_2.24-1~etch.apsy0.dsc
| 9ddbe5e15fbf90d10207e23350da2213 51970 dicomnifti_2.24.orig.tar.gz
| 6428215189a85bc61836de962d30039f 21797 dicomnifti_2.24-1~etch.apsy0.diff.gz
`---
trying to fetch the most recent source available from mentors:
,----------------------------------------------------------------
| apt-get source dicomnifti
| Reading package lists... Done
| Building dependency tree... Done
| Skipping already downloaded file 'dicomnifti_2.23-1.dsc'
| Skipping already downloaded file 'dicomnifti_2.23.orig.tar.gz'
| Skipping already downloaded file 'dicomnifti_2.23-1.diff.gz'
| Need to get 0B of source archives.
| Skipping unpack of already unpacked source in dicomnifti-2.23
`---
but works fine versioned:
,---------------------------------------------------------------------------------
| $> apt-get source dicomnifti=2.24-1
| Reading package lists... Done
| Building dependency tree... Done
| Need to get 74.5kB of source archives.
| Get:1 http://mentors.debian.net unstable/main dicomnifti 2.24-1 (dsc) [655B]
| Get:2 http://mentors.debian.net unstable/main dicomnifti 2.24-1 (tar) [52.0kB]
| Get:3 http://mentors.debian.net unstable/main dicomnifti 2.24-1 (diff) [21.9kB]
| Fetched 74.5kB in 0s (97.7kB/s)
| dpkg-source: extracting dicomnifti in dicomnifti-2.24
| dpkg-source: unpacking dicomnifti_2.24.orig.tar.gz
| dpkg-source: applying ./dicomnifti_2.24-1.diff.gz
`---
My guess would be that it uses a version of available/installed binary package
which diverges from apt-get man page:
,-------------------------------------------------------------------------
| source
| source causes apt-get to fetch source packages. APT will examine the
| available packages to decide which source package to fetch. It will
| then find and download into the current directory the *newest*
| available version of that source package. Source packages are
| tracked separately from binary packages via deb-src type lines in
| the sources.list(5) file. This probably will mean that you will not
| get the same source as the package you have installed or as you
`---
-- Package-specific info:
-- apt-config dump --
APT "";
APT::Architecture "i386";
APT::Build-Essential "";
APT::Build-Essential:: "build-essential";
APT::Default-Release "unstable";
Dir "/";
Dir::State "var/lib/apt/";
Dir::State::lists "lists/";
Dir::State::cdroms "cdroms.list";
Dir::State::userstatus "status.user";
Dir::State::status "/var/lib/dpkg/status";
Dir::Cache "var/cache/apt/";
Dir::Cache::archives "archives/";
Dir::Cache::srcpkgcache "srcpkgcache.bin";
Dir::Cache::pkgcache "pkgcache.bin";
Dir::Etc "etc/apt/";
Dir::Etc::sourcelist "sources.list";
Dir::Etc::sourceparts "sources.list.d";
Dir::Etc::vendorlist "vendors.list";
Dir::Etc::vendorparts "vendors.list.d";
Dir::Etc::main "apt.conf";
Dir::Etc::parts "apt.conf.d";
Dir::Etc::preferences "preferences";
Dir::Bin "";
Dir::Bin::methods "/usr/lib/apt/methods";
Dir::Bin::dpkg "/usr/bin/dpkg";
DPkg "";
DPkg::Pre-Install-Pkgs "";
DPkg::Pre-Install-Pkgs:: "if dpkg -s apt-listbugs | grep -q '^Status: .* ok installed'; then /usr/sbin/apt-listbugs apt || ( test $? -ne 10 || exit 10; echo 'Warning: apt-listbugs exited abnormally, hit enter key to continue.' 1>&2 ; read a < /dev/tty ); fi";
DPkg::Pre-Install-Pkgs:: "/usr/sbin/dpkg-preconfigure --apt || true";
DPkg::Post-Invoke "";
DPkg::Post-Invoke:: "if [ -x /usr/bin/debsums ]; then /usr/bin/debsums --generate=nocheck -sp /var/cache/apt/archives; fi";
-- (no /etc/apt/preferences present) --
-- /etc/apt/sources.list --
# See sources.list(5) for more information
deb-src http://mentors.debian.net/debian unstable main
# deb file:///net/itanix.localnet/share/rumba/dists/unstable/perspect/binary-i386/ ./
deb file:///net/itanix.localnet/share/debmirror/rumba/ sid local alianed perspect backport
#deb-src file:///net/itanix.localnet/share/debmirror/rumba/ sid local alianed perspect backport
# FSL
deb file:///net/itanix.localnet/share/debmirror/fsl/ etch main non-free contrib
#deb-src file:///net/itanix.localnet/share/debmirror/fsl/ etch main non-free
# .................... MAIN ....................
deb file:///net/itanix.localnet/share/debmirror/debian/ sid main contrib non-free
#deb ftp://ftp.debian.org/debian/ sid main contrib non-free
deb-src file:///net/itanix.localnet/share/debmirror/debian/ sid main contrib non-free
#deb file:///net/itanix.localnet/share/debmirror/debian-security/ etch/updates main contrib non-free
#deb-src file:///net/itanix.localnet/share/debmirror/debian-security/ etch/updates main contrib non-free
# we need to downgrade subversion-tools
#deb http://snapshot.debian.net/archive pool subversion
# od1n
#deb http://od1n.sourceforge.net/ ./
-- System Information:
Debian Release: 4.0
APT prefers unstable
APT policy: (990, 'unstable')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-1-686
Locale: LANG=ru_RU.koi8r, LC_CTYPE=ru_RU.koi8r (charmap=KOI8-R)
Versions of packages apt depends on:
ii debian-archive-keyring 2007.02.19 GnuPG archive keys of the Debian a
ii libc6 2.3.6.ds1-13 GNU C Library: Shared libraries
ii libgcc1 1:4.1.1-21 GCC support library
ii libstdc++6 4.1.1-21 The GNU Standard C++ Library v3
apt recommends no packages.
-- no debconf information
Reply to: