Bug#502860: reportbug: Gets wrong maintainer for no longer installed packages

2008-10-21 Thread Sandro Tosi
retitle 502860 use python-apt instead of dpkg for pkgs info
thanks

On Mon, Oct 20, 2008 at 16:52, Raphael Hertzog [EMAIL PROTECTED] wrote:
 On Mon, 20 Oct 2008, Sandro Tosi wrote:
 Hello Ansgar,

 On Mon, Oct 20, 2008 at 13:23, Ansgar Burchardt [EMAIL PROTECTED] wrote:
  Reportbug sometimes looks up the wrong maintainer for packages that have
  been removed from the system.
 
  The output from dpkg --print-avail can be wrong if the package is no 
  longer
  installed.  Reportbug should not use this information for these packages.  
  For
  example on my system I get this:

 But isn't it a bug in dpkg then? I can feel like --print-avail should
 print only available package, and nntp was no longer available on
 your system. I can't think an easy way to fix this if not switching to
 apt-cache or some other tool.

 Don't use dpkg --print-avail it reports only outdated information in
 most cases as the available file is only a left-over from dselect
 and as such it's almost guaranteed to not be up-to-date. There's a warning
 in the man page in the git repository documenting this limitation already.

 Use apt-cache is my suggestion.

Thanks Raphael for highlight this to me; maybe the best solution is to
replace all the code that exec dpkg + parse output to python-apt
(even if this interface really needs a better documentation than now)

Cheers,
Sandro

-- 
Sandro Tosi (aka morph, Morpheus, matrixhasu)
My website: http://matrixhasu.altervista.org/
Me at Debian: http://wiki.debian.org/SandroTosi



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Bug#502860: reportbug: Gets wrong maintainer for no longer installed packages

2008-10-20 Thread Ansgar Burchardt
Package: reportbug
Version: 3.45
Severity: minor

Hi,

Reportbug sometimes looks up the wrong maintainer for packages that have
been removed from the system.

The output from dpkg --print-avail can be wrong if the package is no longer
installed.  Reportbug should not use this information for these packages.  For
example on my system I get this:

% dpkg --print-avail nntp
Package: nntp
Priority: extra
Section: news
Installed-Size: 244
Maintainer: Hamish Moffatt [EMAIL PROTECTED]
Architecture: i386
Version: 1.5.12.1-8
Depends: libc6 (= 2.1), cnews
Conflicts: inn
Filename: dists/potato/main/binary-i386/news/nntp_1.5.12.1-8.deb
Size: 69226
MD5sum: a8c09d9a778c50ebd9cdbf8b6f741c23
Description: A NNTP server for use with C News.

Note that the output still refers to potato, and the maintainer information is
wrong since 2003.

Regards,
Ansgar

-- System Information:
Debian Release: lenny/sid
  APT prefers testing
  APT policy: (900, 'testing'), (600, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)

Kernel: Linux 2.6.26-1-686 (SMP w/1 CPU core)
Locale: LANG=C, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages reportbug depends on:
ii  apt   0.7.14+b1  Advanced front-end for dpkg
ii  python2.5.2-2An interactive high-level object-o
ii  python-central0.6.8  register and build utility for Pyt

reportbug recommends no packages.

Versions of packages reportbug suggests:
ii  debconf-utils 1.5.22 debconf utilities
pn  debsums   none (no description available)
pn  dlocate   none (no description available)
ii  file  4.26-1 Determines file type using magic
ii  gnupg 1.4.9-3GNU privacy guard - a free PGP rep
ii  postfix [mail-transport-agent 2.5.5-1.1  High-performance mail transport ag
pn  python-urwid  none (no description available)

-- no debconf information



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Bug#502860: reportbug: Gets wrong maintainer for no longer installed packages

2008-10-20 Thread Sandro Tosi
Hello Ansgar,

On Mon, Oct 20, 2008 at 13:23, Ansgar Burchardt [EMAIL PROTECTED] wrote:
 Reportbug sometimes looks up the wrong maintainer for packages that have
 been removed from the system.

 The output from dpkg --print-avail can be wrong if the package is no longer
 installed.  Reportbug should not use this information for these packages.  For
 example on my system I get this:

But isn't it a bug in dpkg then? I can feel like --print-avail should
print only available package, and nntp was no longer available on
your system. I can't think an easy way to fix this if not switching to
apt-cache or some other tool.

I'm open to suggestions, in particular from dpkg guys.

Cheers,
Sandro

-- 
Sandro Tosi (aka morph, Morpheus, matrixhasu)
My website: http://matrixhasu.altervista.org/
Me at Debian: http://wiki.debian.org/SandroTosi



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Bug#502860: reportbug: Gets wrong maintainer for no longer installed packages

2008-10-20 Thread Raphael Hertzog
On Mon, 20 Oct 2008, Sandro Tosi wrote:
 Hello Ansgar,
 
 On Mon, Oct 20, 2008 at 13:23, Ansgar Burchardt [EMAIL PROTECTED] wrote:
  Reportbug sometimes looks up the wrong maintainer for packages that have
  been removed from the system.
 
  The output from dpkg --print-avail can be wrong if the package is no 
  longer
  installed.  Reportbug should not use this information for these packages.  
  For
  example on my system I get this:
 
 But isn't it a bug in dpkg then? I can feel like --print-avail should
 print only available package, and nntp was no longer available on
 your system. I can't think an easy way to fix this if not switching to
 apt-cache or some other tool.

Don't use dpkg --print-avail it reports only outdated information in
most cases as the available file is only a left-over from dselect
and as such it's almost guaranteed to not be up-to-date. There's a warning
in the man page in the git repository documenting this limitation already.

Use apt-cache is my suggestion.

Cheers,
-- 
Raphaël Hertzog

Le best-seller français mis à jour pour Debian Etch :
http://www.ouaza.com/livre/admin-debian/



--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]