From 0708400a8775dc847856de8ccf4a9fa6e9d2863d Mon Sep 17 00:00:00 2001 From: Filippo Giunchedi Date: Tue, 9 Dec 2008 23:16:03 +0100 Subject: [PATCH] use python-debian for .changes parsing --- queue_rss.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/queue_rss.py b/queue_rss.py index 6e5c2407..c312b25b 100755 --- a/queue_rss.py +++ b/queue_rss.py @@ -15,6 +15,8 @@ from optparse import OptionParser import PyRSS2Gen +from debian_bundle.deb822 import Changes + inrss_filename = "changes_in.rss" outrss_filename = "changes_out.rss" db_filename = "status.db" @@ -66,12 +68,7 @@ def parse_changes(fname): Return {fname: parsed} """ - p = HeaderParser() - - try: - m = p.parse(open(fname), True) - except IOError: - sys.stderr.write("Unable to parse %s\n" % fname) + m = Changes(open(fname)) wanted_fields = set(['Source', 'Version', 'Architecture', 'Distribution', 'Date', 'Maintainer', 'Description', 'Changes']) -- 2.39.5