From 5d965c34b35048f8a8fab0a7a11f2943d833952d Mon Sep 17 00:00:00 2001 From: Alexander Reichle-Schmehl Date: Wed, 29 Sep 2010 11:04:10 +0000 Subject: [PATCH] Make the wnpp parse more robust for missing files --- daklib/utils.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/daklib/utils.py b/daklib/utils.py index 542ede51..4744f6a2 100755 --- a/daklib/utils.py +++ b/daklib/utils.py @@ -1548,7 +1548,14 @@ def parse_wnpp_bug_file(file = "/srv/ftp-master.debian.org/scripts/masterfiles/w returns a dict associating source package name with a list of open wnpp bugs (Yes, there might be more than one) """ - lines = open(file).readlines() + + line = [] + try: + f = open(file) + lines = f.readlines() + except IOerror, e: + print "Warning: Couldn't open %s; don't know about WNPP bugs, so won't close any." % file + lines = [] wnpp = {} for line in lines: -- 2.39.5