From f2568b9bdedd12427aaaed393c68dcf20691ea11 Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Tue, 10 Jan 2012 11:43:47 -0500 Subject: - Fixed regression from 0.6 whereby if "load_on_pending" relationship() flag were used where a non-"get()" lazy clause needed to be emitted on a pending object, it would fail to load. --- lib/sqlalchemy/sql/compiler.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'lib/sqlalchemy/sql/compiler.py') diff --git a/lib/sqlalchemy/sql/compiler.py b/lib/sqlalchemy/sql/compiler.py index aa744e0c1..724e7dc2a 100644 --- a/lib/sqlalchemy/sql/compiler.py +++ b/lib/sqlalchemy/sql/compiler.py @@ -305,18 +305,13 @@ class SQLCompiler(engine.Compiled): raise exc.InvalidRequestError( "A value is required for bind parameter %r" % bindparam.key) - elif bindparam.callable: - pd[name] = bindparam.callable() else: - pd[name] = bindparam.value + pd[name] = bindparam.effective_value return pd else: pd = {} for bindparam in self.bind_names: - if bindparam.callable: - pd[self.bind_names[bindparam]] = bindparam.callable() - else: - pd[self.bind_names[bindparam]] = bindparam.value + pd[self.bind_names[bindparam]] = bindparam.effective_value return pd params = property(construct_params, doc=""" -- cgit v1.2.1