]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
safe annotate QueryableAttribute inside of join() condition
authorMike Bayer <mike_mp@zzzcomputing.com>
Thu, 10 Aug 2023 22:26:45 +0000 (18:26 -0400)
committerMike Bayer <mike_mp@zzzcomputing.com>
Fri, 11 Aug 2023 16:36:21 +0000 (12:36 -0400)
commit9e8b910c9a2b52de471c662caabb65e62cabf3c6
treee85fa07a4519f04e67233568c9f49689abd3e41c
parente398c894740f032131bcd28a2fd49dec3c3699d0
safe annotate QueryableAttribute inside of join() condition

Fixed fundamental issue which prevented some forms of ORM "annotations"
from taking place for subqueries which made use of :meth:`_sql.Select.join`
against a relationship target.  These annotations are used whenever a
subquery is used in special situations such as within
:meth:`_orm.PropComparator.and_` and other ORM-specific scenarios.

Fixes: #10223
Change-Id: I40f04265a6caa0fdcbc9f1b121a35561ab4b1fcf
(cherry picked from commit 6cfdc0743b7d1ebee3582f612a4f8acaa6ab42f9)
doc/build/changelog/unreleased_14/10223.rst [new file with mode: 0644]
lib/sqlalchemy/sql/annotation.py
test/orm/test_rel_fn.py
test/orm/test_relationship_criteria.py