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

Bug#69969: I can't figure out how to do what I want to do.



Package: dpkg-python
Version: 0.1-4


Hi there!  Thank you all very much for Debian, which is the best thing 
going due to its hard-working package maintainers and its sophisticated 
package tools!


I'm a developer of Mojo Nation, a new open source distributed file-
sharing system (http://mojohackers.org/).  I want to integrate our 
software with Debian, and I downloaded dpkg-python to that end, hoping to
find a method that takes a file as argument and returns a dict mapping 
from fieldname to value.


I read a lot of the dpkg-python code and experimented a bit, calling 
various `parse()' methods on my .deb files.  I couldn't find one that did
what I wanted, and there wasn't any README, example usage code, or 
in-line comments that I could find, so I gave up.


Hopefully dpkg-perl will have some doco indicating how to get the data 
that I want!  Then I'll mung it real quick to output something that looks
just like the repr() of a Python dict, which is the format I need.  :-)


Anyway, before I go look at dpkg-perl, I thought that I should submit a 
bug report.


Regards,

Zooko

P.S.  I really spent a long time on this.  I've tried many variations of
passing `dpkg_packages.read' as the second argument to `tar.parse_file()'
and other experiments.  And I'm not inexperienced with Python nor 
(usually) am I slow to understand.




Reply to: