]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
re.match to re.search
authorScott Schaefer <sschaefer@vmware.com>
Sat, 7 Sep 2013 00:14:26 +0000 (18:14 -0600)
committerScott Schaefer <sschaefer@vmware.com>
Sat, 7 Sep 2013 00:14:26 +0000 (18:14 -0600)
Convert to re.search to eliminate the restriction on only matching the
beginning of the string

lib/sqlalchemy/dialects/postgresql/base.py

index 8938b3193c1ad13de0db37f59b7e74e788e1272c..01bf6a8293156a4d19b997d0657f8c1e5c73af1c 100644 (file)
@@ -1543,7 +1543,7 @@ class PGDialect(default.DefaultDialect):
 
     def _get_server_version_info(self, connection):
         v = connection.execute("select version()").scalar()
-        m = re.match(
+        m = re.search(
             '(?:PostgreSQL|EnterpriseDB) '
             '(\d+)\.(\d+)(?:\.(\d+))?(?:\.\d+)?(?:devel)?',
             v)