]> git.decadent.org.uk Git - dak.git/blobdiff - daklib/dbconn.py
daklib/dbconn.py: SQLAlchemy 0.9 is also fine.
[dak.git] / daklib / dbconn.py
index 7d5a7481723b360f3525d3727f8fbf96d4c3dfb7..988309361b3bef1fa2295c8184bedc8f60eddc31 100644 (file)
@@ -109,11 +109,11 @@ class DebVersion(UserDefinedType):
         return None
 
 sa_major_version = sqlalchemy.__version__[0:3]
-if sa_major_version in ["0.5", "0.6", "0.7", "0.8"]:
+if sa_major_version in ["0.5", "0.6", "0.7", "0.8", "0.9"]:
     from sqlalchemy.databases import postgres
     postgres.ischema_names['debversion'] = DebVersion
 else:
-    raise Exception("dak only ported to SQLA versions 0.5 to 0.8.  See daklib/dbconn.py")
+    raise Exception("dak only ported to SQLA versions 0.5 to 0.9.  See daklib/dbconn.py")
 
 ################################################################################
 
@@ -572,7 +572,6 @@ class DBBinary(ORMObject):
         @rtype: dict
         @return: fields of the control section as a dictionary.
         '''
-        import apt_pkg
         stanza = self.read_control()
         return apt_pkg.TagSection(stanza)