X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=daklib%2Fdbconn.py;h=4e01b610ce1789acffd9272d8559c34f86542795;hb=27e00376e81d1c37ff327ee0d39670b266418869;hp=1fa7974f5d0f5e2f2cdd4101c1621722bf86a731;hpb=4d86749d6633cdc13161fd04220207ca13bfda21;p=dak.git diff --git a/daklib/dbconn.py b/daklib/dbconn.py index 1fa7974f..4e01b610 100755 --- a/daklib/dbconn.py +++ b/daklib/dbconn.py @@ -81,6 +81,9 @@ import warnings warnings.filterwarnings('ignore', \ "The SQLAlchemy PostgreSQL dialect has been renamed from 'postgres' to 'postgresql'.*", \ SADeprecationWarning) +warnings.filterwarnings('ignore', \ + "Predicate of partial index .* ignored during reflection", \ + SAWarning) ################################################################################ @@ -815,7 +818,7 @@ class BuildQueue(object): Logger.log(["I: Removing %s from the queue" % o.fullpath]) os.unlink(o.fullpath) killdb = True - except OSError, e: + except OSError as e: # If it wasn't there, don't worry if e.errno == ENOENT: killdb = True @@ -3681,7 +3684,7 @@ class DBConn(object): self.__setuptables() self.__setupmappers() - except OperationalError, e: + except OperationalError as e: import utils utils.fubar("Cannot connect to database (%s)" % str(e))