From 460bed7cfd8a6dd035caff5f5b1b33edf96fa3bb Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Fri, 28 May 2021 08:29:24 -0400 Subject: Fix adaption in AnnotatedLabel; repair needless expense in coercion Fixed regression involving clause adaption of labeled ORM compound elements, such as single-table inheritance discriminator expressions with conditionals or CASE expressions, which could cause aliased expressions such as those used in ORM join / joinedload operations to not be adapted correctly, such as referring to the wrong table in the ON clause in a join. This change also improves a performance bump that was located within the process of invoking :meth:`_sql.Select.join` given an ORM attribute as a target. Fixes: #6550 Change-Id: I98906476f0cce6f41ea00b77c789baa818e9d167 --- lib/sqlalchemy/sql/traversals.py | 1 - 1 file changed, 1 deletion(-) (limited to 'lib/sqlalchemy/sql/traversals.py') diff --git a/lib/sqlalchemy/sql/traversals.py b/lib/sqlalchemy/sql/traversals.py index e64eff6a4..35f2bd62f 100644 --- a/lib/sqlalchemy/sql/traversals.py +++ b/lib/sqlalchemy/sql/traversals.py @@ -737,7 +737,6 @@ class HasCopyInternals(object): continue if obj is not None: - result = meth(attrname, self, obj, **kw) if result is not None: setattr(self, attrname, result) -- cgit v1.2.1