- attached patch
deferred() does not work with ShardedSession
Issue #771
resolved
If I declare a field as "deferred()", and use it within a ShardedSession, it blows up when trying to access the field.
I am pretty sure this is because the get_bind() method in ShardedSession does not accept a keyword parameter named "clause". But the superclass's method, Session.get_bind(), does take such a parameter.
This is easy to reproduce by taking examples/sharding/attribute_shard.py and applying the attached patch to it.
- Terry Weissman terry at weissman.org trw in #sqlalchemy
Comments (2)
-
Account Deleted -
repo owner - changed status to resolved
fc753a06475c2fa571d09d73d3169b66c272c8d6 . take a look over there, I've also added an extra kwarg to shard_chooser "clause", which is the ClauseElement passed to session.execute(), for clients which use that feature. Otherwise it'll be None.
- Log in to comment
Patch to reproduce bug