From: Luca Falavigna Date: Tue, 4 Oct 2011 09:26:20 +0000 (+0000) Subject: Fix traceback when given suite is not recognized X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=751e8fbc852d3810fc1588cba7677de78ba419db;p=dak.git Fix traceback when given suite is not recognized Signed-off-by: Luca Falavigna --- diff --git a/daklib/utils.py b/daklib/utils.py index 40e47c63..c144624a 100755 --- a/daklib/utils.py +++ b/daklib/utils.py @@ -1022,8 +1022,8 @@ def parse_args(Options): suite_ids_list = [] for suitename in split_args(Options["Suite"]): suite = get_suite(suitename, session=session) - if suite.suite_id is None: - warn("suite '%s' not recognised." % (suite.suite_name)) + if not suite or suite.suite_id is None: + warn("suite '%s' not recognised." % (suite and suite.suite_name or suitename)) else: suite_ids_list.append(suite.suite_id) if suite_ids_list: