summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/sql/annotation.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2021-03-25 08:40:16 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2021-03-25 08:45:32 -0400
commite3b09f65df5dd51f87515f115827dedba50e9dca (patch)
tree23b5b19e2d7423289ff0b5ef2e91851084ec4802 /lib/sqlalchemy/sql/annotation.py
parent5682b9a24d4174f429204638ec90622b52035cdc (diff)
downloadsqlalchemy-e3b09f65df5dd51f87515f115827dedba50e9dca.tar.gz
Accept **kw in annotated._clone() method
Fixed bug where combinations of the new "relationship with criteria" feature could fail in conjunction with features that make use of the new "lambda SQL" feature, including loader strategies such as selectinload and lazyload, for more complicated scenarios such as polymorphic loading. Fixes: #6131 Change-Id: I915dead6596866ae5fd1a7f593a90bce4b61d1af
Diffstat (limited to 'lib/sqlalchemy/sql/annotation.py')
-rw-r--r--lib/sqlalchemy/sql/annotation.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/sqlalchemy/sql/annotation.py b/lib/sqlalchemy/sql/annotation.py
index 23b5052a9..8e5cdf148 100644
--- a/lib/sqlalchemy/sql/annotation.py
+++ b/lib/sqlalchemy/sql/annotation.py
@@ -199,8 +199,8 @@ class Annotated(object):
def _constructor(self):
return self.__element._constructor
- def _clone(self):
- clone = self.__element._clone()
+ def _clone(self, **kw):
+ clone = self.__element._clone(**kw)
if clone is self.__element:
# detect immutable, don't change anything
return self