Patches item #1578414, was opened at 2006-10-16 22:32
Message generated for change (Comment added) made by phd
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=540674&aid=1578414&group_id=74338
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
>Resolution: Invalid
Priority: 5
Private: No
Submitted By: ptwobrussell (ptwobrussell)
>Assigned to: Oleg Broytmann (phd)
Summary: exception called b/c pgdb.Binary('') fails
Initial Comment:
Patch is located inline below. Apparently, you need to
specialize the check because no Binary() method exists
as of pgdb v3.6+ (possibly earlier too, I don't know).
dbconnection.orig is the original file and
dbconnection.py is the updated file that now works
--- dbconnection.py.orig 2006-10-16
14:09:01.000000000 -0400
+++ dbconnection.py 2006-10-16 14:10:58.000000000 -0400
@@ -213,7 +213,10 @@
self._pool = []
self._poolLock = threading.Lock()
DBConnection.__init__(self, **kw)
- self._binaryType = type(self.module.Binary(''))
+ if self.usePygresql:
+ self._binaryType = type(self.module.BINARY)
+ else:
+ self._binaryType =
type(self.module.Binary(''))
def _runWithConnection(self, meth, *args):
conn = self.getConnection()
----------------------------------------------------------------------
>Comment By: Oleg Broytmann (phd)
Date: 2006-11-10 17:18
Message:
Logged In: YES
user_id=4799
First, the patch is invalid. self.usePygresql is defined
only in PostgresConnection, hence that "if" will fail for
any other connection class.
Then, the absence of Binary() means Pygresql doesn't
implement DB API 2.0 specification properly.
Third, there are more calls to Binary() in the SQLObject.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=540674&aid=1578414&group_id=74338
|