[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#573592: absent debian revision is not considered equivalent to 0



Package: apt
Version: 0.7.25.3
Severity: normal

According to Policy 5.6.12 the absence of a debian revision should be
considered equivalent to the presence of a debian revision of 0 (this
was clarified somewhere in 2008). 

dpkg apparently works this way but apt does not:
$ python
Python 2.5.5 (r255:77872, Feb  2 2010, 00:25:36) 
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import apt_pkg
>>> apt_pkg.init() 
>>> apt_pkg.VersionCompare("1.0", "1.0-0")
-1
>>> 

(python-apt's VersionCompare is just a python wrapper around apt's
actual implementation)

-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-trunk-amd64 (SMP w/4 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/bash

Versions of packages apt depends on:
ii  debian-archive-keyring  2009.01.31       GnuPG archive keys of the Debian a
ii  libc6                   2.11-0exp6       Embedded GNU C Library: Shared lib
ii  libgcc1                 1:4.5-20100227-1 GCC support library
ii  libstdc++6              4.5-20100227-1   The GNU Standard C++ Library v3

apt recommends no packages.

Versions of packages apt suggests:
pn  apt-doc                       <none>     (no description available)
ii  aptitude                      0.6.1.5-2  terminal-based package manager (te
ii  bzip2                         1.0.5-4    high-quality block-sorting file co
ii  dpkg-dev                      1.15.5.6   Debian package development tools
ii  lzma                          4.43-14    Compression method of 7z format in
ii  python-apt                    0.7.94     Python interface to libapt-pkg
ii  synaptic                      0.63.1     Graphical package manager

-- no debconf information



Reply to: