]> git.decadent.org.uk Git - dak.git/commitdiff
dominate: convert to str
authorAnsgar Burchardt <ansgar@debian.org>
Sun, 10 Jun 2012 14:20:57 +0000 (16:20 +0200)
committerAnsgar Burchardt <ansgar@debian.org>
Thu, 14 Jun 2012 08:33:19 +0000 (10:33 +0200)
apt_pkg.Configuration does only allow str values; trying to assign a
unicode object raises a TypeError.

dak/dominate.py

index be8c52203958486c8ae229a300149efa22f09351..a6be1b035adc841f35fec7d83f6ac3c8e015e94b 100755 (executable)
@@ -134,8 +134,9 @@ def main():
         usage()
     if 'Suite' not in Options:
         query_suites = DBConn().session().query(Suite)
-        suites = [suite.suite_name for suite in query_suites.all()]
-        cnf['Obsolete::Options::Suite'] = ','.join(suites)
+        suites = [suite.suite_name for suite in query_suites]
+        cnf['Obsolete::Options::Suite'] = str(','.join(suites))
+
     Logger = daklog.Logger("dominate")
     session = DBConn().session()
     for suite_name in utils.split_args(Options['Suite']):