dal connection strigs now allo / in hostnames, thanks Babak

This commit is contained in:
Massimo Di Pierro
2012-05-28 12:29:19 -05:00
parent de07e0dfc1
commit 6411045b62
2 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -1 +1 @@
Version 2.00.0 (2012-05-27 17:51:38) dev
Version 2.00.0 (2012-05-28 12:28:07) dev
+3 -3
View File
@@ -2173,7 +2173,7 @@ class PostgreSQLAdapter(BaseAdapter):
self.srid = srid
self.find_or_make_work_folder()
library, uri = uri.split('://')[:2]
m = re.compile('^(?P<user>[^:@]+)(\:(?P<password>[^@]*))?@(?P<host>[^\:@/]+)(\:(?P<port>[0-9]+))?/(?P<db>[^\?]+)(\?sslmode=(?P<sslmode>.+))?$').match(uri)
m = re.compile('^(?P<user>[^:@]+)(\:(?P<password>[^@]*))?@(?P<host>[^\:@]+)(\:(?P<port>[0-9]+))?/(?P<db>[^\?]+)(\?sslmode=(?P<sslmode>.+))?$').match(uri)
if not m:
raise SyntaxError, "Invalid URI string in DAL"
user = credential_decoder(m.group('user'))
@@ -3490,7 +3490,7 @@ class SAPDBAdapter(BaseAdapter):
self.db_codec = db_codec
self.find_or_make_work_folder()
uri = uri.split('://')[1]
m = re.compile('^(?P<user>[^:@]+)(\:(?P<password>[^@]*))?@(?P<host>[^\:@/]+)(\:(?P<port>[0-9]+))?/(?P<db>[^\?]+)(\?sslmode=(?P<sslmode>.+))?$').match(uri)
m = re.compile('^(?P<user>[^:@]+)(\:(?P<password>[^@]*))?@(?P<host>[^\:@]+)(\:(?P<port>[0-9]+))?/(?P<db>[^\?]+)(\?sslmode=(?P<sslmode>.+))?$').match(uri)
if not m:
raise SyntaxError, "Invalid URI string in DAL"
user = credential_decoder(m.group('user'))
@@ -5142,7 +5142,7 @@ class IMAPAdapter(NoSQLAdapter):
db['_lastsql'] = ''
m = re.compile('^(?P<user>[^:]+)(\:(?P<password>[^@]*))?@(?P<host>[^\:@/]+)(\:(?P<port>[0-9]+))?$').match(uri)
m = re.compile('^(?P<user>[^:]+)(\:(?P<password>[^@]*))?@(?P<host>[^\:@]+)(\:(?P<port>[0-9]+))?$').match(uri)
user = m.group('user')
password = m.group('password')
host = m.group('host')