Your message dated Thu, 04 Aug 2011 06:18:03 +0000
with message-id <[email protected]>
and subject line Bug#627058: fixed in python-debian 0.1.21
has caused the Debian Bug report #627058,
regarding python-debian: deb822.GpgInfo.from_file is all broken
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
627058: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=627058
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: python-debian
Version: 0.1.18
Severity: normal
Tags: patch
Two problems with GpgInfo:
1. from_file calls from_sequence instead of GpgInfo.from_sequence,
resulting in:
File "/usr/lib/pymodules/python2.6/debian/deb822.py", line 685, in from_file
return from_sequence(file(target), *args)
NameError: global name 'from_sequence' is not defined
2. from_sequence wants non-\n-terminated lines in the sequence, otherwise
it sends bogus data to gpgv (thanks to the "\n".join(sequence) sent to
the pipe). the sequence returned by file(foo) has \n at the end of
each line.
Works a lot better with:
diff --git a/lib/debian/deb822.py b/lib/debian/deb822.py
index a0cad69..163fc5f 100644
--- a/lib/debian/deb822.py
+++ b/lib/debian/deb822.py
@@ -682,7 +682,7 @@ class GpgInfo(dict):
@staticmethod
def from_file(target, *args):
"""Create a new GpgInfo object from the given file, calls
from_sequence(file(target), *args)"""
- return from_sequence(file(target), *args)
+ return GpgInfo.from_sequence(file(target).read(), *args)
###
Although you might want to fix from_sequence instead.
Incidentally it would be nice to be able to pass a list of keyrings to
Deb822.get_gpg_info().
Cheers,
Julien
-- System Information:
Debian Release: 6.0.1
APT prefers stable
APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.32-5-amd64 (SMP w/8 CPU cores)
Locale: LANG=C, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages python-debian depends on:
ii python 2.6.6-3+squeeze6 interactive high-level object-orie
ii python-chardet 2.0.1-1 universal character encoding detec
ii python-support 1.0.10 automated rebuilding support for P
Versions of packages python-debian recommends:
ii python-apt 0.7.100.1 Python interface to libapt-pkg
Versions of packages python-debian suggests:
ii gpgv 1.4.10-4 GNU privacy guard - signature veri
-- no debconf information
--- End Message ---
--- Begin Message ---
Source: python-debian
Source-Version: 0.1.21
We believe that the bug you reported is fixed in the latest version of
python-debian, which is due to be installed in the Debian FTP archive:
python-debian_0.1.21.dsc
to main/p/python-debian/python-debian_0.1.21.dsc
python-debian_0.1.21.tar.gz
to main/p/python-debian/python-debian_0.1.21.tar.gz
python-debian_0.1.21_all.deb
to main/p/python-debian/python-debian_0.1.21_all.deb
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
John Wright <[email protected]> (supplier of updated python-debian package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Format: 1.8
Date: Wed, 03 Aug 2011 23:07:17 -0700
Source: python-debian
Binary: python-debian
Architecture: source all
Version: 0.1.21
Distribution: unstable
Urgency: low
Maintainer: Debian python-debian Maintainers
<[email protected]>
Changed-By: John Wright <[email protected]>
Description:
python-debian - Python modules to work with Debian-related data formats
Closes: 597120 597249 625672 627058 627060 627063 631392 632306
Changes:
python-debian (0.1.21) unstable; urgency=low
.
[ Tshepang Lekhonkhobe ]
* test_changelog.py: Close open files. (Closes: #625672)
.
[ John Wright ]
* deb822: Allow ':' as the first character of a value.
(Closes: #597249)
* deb822: Avoid dumping unparseable data. (Closes: #597120)
* Clean up deb822.GpgInfo implementation:
- Change several @staticmethod decorated methods to @classmethod,
since they call the class constructor.
- from_sequence now can accept both sequences of newline-terminated
strings and the output of str.splitlines().
- from_file now actually calls the from_sequence method.
(Closes: #627058)
- from_sequence now makes a copy of the initial args list before
extending it. (Closes: #627060)
- Keyrings are no longer checked for accessibility, since gpgv can
accept keyring arguments that are under the GnuPG home directory,
regardless of the current directory. (Closes: #627063)
* deb822.Deb822.gpg_info takes an optional keyrings argument.
* deb822: Don't interpret lines starting with '#'. (Closes: #632306)
.
[ Colin Watson ]
* Use dh_python2 instead of python-support. (Closes: #631392)
Checksums-Sha1:
d55cecd66ac8dd41ede6f7e65b9d89896c9a02ca 1227 python-debian_0.1.21.dsc
a4216be3f1a8855e5d5784aa9faa08f74a80beb2 184663 python-debian_0.1.21.tar.gz
28a7477ea774592e8341c4c7dfdc1ed276dc5f5e 61300 python-debian_0.1.21_all.deb
Checksums-Sha256:
bdc7c07e18593be4f64fca45fa8a563836980058b0ac3700cc3c9177917bc46a 1227
python-debian_0.1.21.dsc
0ca7bf4808e2a056853319122e5f17cea0f62492cb23a7ef910f314f54476dac 184663
python-debian_0.1.21.tar.gz
59e38e88cec8d4f9d7432061d1e4f6352913290d14f01e7f21646f4d65b2a774 61300
python-debian_0.1.21_all.deb
Files:
c67928ca46db93ecc378e72082786c51 1227 python optional python-debian_0.1.21.dsc
dcbf7f8294108f179509c822d1d57caa 184663 python optional
python-debian_0.1.21.tar.gz
4886dca98fc3ad8fc84098c9bd44162b 61300 python optional
python-debian_0.1.21_all.deb
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iEYEARECAAYFAk46N+4ACgkQ0UIZh3p4ZWEYegCeJk3BYi8o6ttRv8LHYJx+AXBB
GhkAn335mDkjGRTvmikYGVtibSk4HsWU
=j4Jx
-----END PGP SIGNATURE-----
--- End Message ---