[SQL-CVS] r4495 - SQLObject/trunk/sqlobject/postgres
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
|
From: <sub...@co...> - 2011-12-14 17:32:50
|
Author: phd
Date: Wed Dec 14 10:32:43 2011
New Revision: 4495
Log:
Set self._connectionNumbers for printDebug in _executeRetry.
Modified:
SQLObject/trunk/sqlobject/postgres/pgconnection.py
Modified: SQLObject/trunk/sqlobject/postgres/pgconnection.py
==============================================================================
--- SQLObject/trunk/sqlobject/postgres/pgconnection.py Wed Dec 14 10:12:28 2011 (r4494)
+++ SQLObject/trunk/sqlobject/postgres/pgconnection.py Wed Dec 14 10:32:43 2011 (r4495)
@@ -140,6 +140,11 @@
conn = self.module.connect(**self.dsn_dict)
except self.module.OperationalError, e:
raise OperationalError("%s; used connection string %r" % (e, self.dsn))
+
+ # For printDebug in _executeRetry
+ self._connectionNumbers[id(conn)] = self._connectionCount
+ self._connectionCount += 1
+
if self.autoCommit: self._setAutoCommit(conn, 1)
c = conn.cursor()
if self.schema:
|