X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=dak%2Fdakdb%2Fupdate12.py;h=21d44a4598103ddc54b2912eb616660f6de74fd4;hb=368f71cb16139abf72d1c351b1fe64c5470365cf;hp=70a9e18e41df11ef751afeb523b61cbc97438c9f;hpb=48e5e5ee12f7c36e3272ec8d3dc0d6c43625d984;p=dak.git diff --git a/dak/dakdb/update12.py b/dak/dakdb/update12.py old mode 100755 new mode 100644 index 70a9e18e..21d44a45 --- a/dak/dakdb/update12.py +++ b/dak/dakdb/update12.py @@ -30,6 +30,7 @@ Adding a date field to the process-new notes import psycopg2 import time +from daklib.dak_exceptions import DBUpdateError ################################################################################ @@ -43,6 +44,6 @@ def do_update(self): c.execute("UPDATE config SET value = '12' WHERE name = 'db_revision'") self.db.commit() - except psycopg2.ProgrammingError, msg: + except psycopg2.ProgrammingError as msg: self.db.rollback() - raise DBUpdateError, "Unable to apply process-new update 12, rollback issued. Error message : %s" % (str(msg)) + raise DBUpdateError("Unable to apply process-new update 12, rollback issued. Error message : %s" % (str(msg)))