Merge branch 'master' of git://git.assembla.com/fpdb-eric
This commit is contained in:
commit
6cb16df055
|
@ -77,10 +77,11 @@ class fpdb_db:
|
||||||
import MySQLdb
|
import MySQLdb
|
||||||
if use_pool:
|
if use_pool:
|
||||||
MySQLdb = pool.manage(MySQLdb, pool_size=5)
|
MySQLdb = pool.manage(MySQLdb, pool_size=5)
|
||||||
try:
|
# try:
|
||||||
self.db = MySQLdb.connect(host = host, user = user, passwd = password, db = database, use_unicode=True)
|
self.db = MySQLdb.connect(host = host, user = user, passwd = password, db = database, use_unicode=True)
|
||||||
except:
|
#TODO: Add port option
|
||||||
raise FpdbMySQLFailedError("MySQL connection failed")
|
# except:
|
||||||
|
# raise FpdbMySQLFailedError("MySQL connection failed")
|
||||||
elif backend==fpdb_db.PGSQL:
|
elif backend==fpdb_db.PGSQL:
|
||||||
import psycopg2
|
import psycopg2
|
||||||
import psycopg2.extensions
|
import psycopg2.extensions
|
||||||
|
|
Loading…
Reference in New Issue
Block a user