From: Mike Bayer Date: Mon, 26 Jun 2006 20:15:54 +0000 (+0000) Subject: cursor() method on ConnectionFairy allows db-specific extension X-Git-Tag: rel_0_2_4~3 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=662bd40300e1f55a60cb5055293e96f7a50a78ea;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git cursor() method on ConnectionFairy allows db-specific extension arguments to be propigated [ticket:221] --- diff --git a/CHANGES b/CHANGES index 62b8a0dedc..1f94c6eee7 100644 --- a/CHANGES +++ b/CHANGES @@ -28,6 +28,8 @@ then returns its connection to the Queue via the the put() method, causing a reentrant hang unless threading.RLock is used. - postgres will not place SERIAL keyword on a primary key column if it has a foreign key constraint +- cursor() method on ConnectionFairy allows db-specific extension +arguments to be propigated [ticket:221] 0.2.3 - overhaul to mapper compilation to be deferred. this allows mappers diff --git a/lib/sqlalchemy/pool.py b/lib/sqlalchemy/pool.py index 0a5b5ca2a7..006328d7dc 100644 --- a/lib/sqlalchemy/pool.py +++ b/lib/sqlalchemy/pool.py @@ -141,8 +141,8 @@ class ConnectionFairy(object): self.connection.rollback() self.connection = None self.pool.return_invalid() - def cursor(self): - return CursorFairy(self, self.connection.cursor()) + def cursor(self, *args, **kwargs): + return CursorFairy(self, self.connection.cursor(*args, **kwargs)) def __getattr__(self, key): return getattr(self.connection, key) def checkout(self):