#431087: Packages iteration return dictionaries
John Wright
john at movingsucks.org
Sun Jul 1 01:29:52 UTC 2007
On Sat, Jun 30, 2007 at 07:11:11PM +0200, Stefano Zacchiroli wrote:
> On Sat, Jun 30, 2007 at 04:35:16PM +0100, John Wright wrote:
> > This is implemented in the deb822 module, which is currently in unstable
> > as python-deb822, but will be integrated in with python-debian at some
> > point. (A slightly outdated version of the source is in python-debian
>
> AOL on Reinhard's question ...
Please see James's reply and my reply to it.
> > already; I need to figure out the best way to either transition from it
> > being a "top-level" package to one under the "debian" package, or else
> > make the python-debian source build the python-deb822 binary...)
> >
> > In particular, see the deb822.Packages.iter_paragraphs method. deb822
> > preserves case and order when "dumping" back out to RFC822 format and
> > also provides case-insensitive dictionary-like access.
>
> Ok, cool. But still: what's the advantage of having the list of tuples
> version of such a method? I don't see it. Hence I would go for applying
> my patch and still wait for the merge with deb822 (hopefully happening
> soon).
I didn't mean to discourage you! Indeed, there is no reason not to
include your patch -- I was just pointing out that what you wanted was
already implemented, including handling things like case-insensitivity
and order-preservation. Unfortunately, as you have seen, there is some
overlap in the functionality of the modules in this bundle, since they
were mostly developed independently...
--
John Wright
More information about the pkg-python-debian-discuss
mailing list