diff options
| author | Mike Bayer <mike_mp@zzzcomputing.com> | 2022-04-16 11:40:13 -0400 |
|---|---|---|
| committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2022-04-16 11:41:48 -0400 |
| commit | c538f810bce57472c8960a0a6c4c61024b00f3ed (patch) | |
| tree | 87c50dd955a93fb535314501a96e47d7c2d17680 /lib | |
| parent | dd201d444e555c2940f85dbc1a3e2bc727f86690 (diff) | |
| download | sqlalchemy-c538f810bce57472c8960a0a6c4c61024b00f3ed.tar.gz | |
adapt_from_selectables is a set
aliasedclass setting this as a list, making all the containment
checks more expensive.
the presence of the collection also serves as a flag so it
has to stay optional.
Change-Id: Iafffbeb29d77441ca35ecd8048244ee6eed1232c
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/sqlalchemy/orm/util.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/sqlalchemy/orm/util.py b/lib/sqlalchemy/orm/util.py index 233085f30..4699781a4 100644 --- a/lib/sqlalchemy/orm/util.py +++ b/lib/sqlalchemy/orm/util.py @@ -744,11 +744,11 @@ class AliasedInsp( # make sure the adapter doesn't try to grab other tables that # are not even the thing we are mapping, such as embedded # selectables in subqueries or CTEs. See issue #6060 - adapt_from_selectables=[ + adapt_from_selectables={ m.selectable for m in self.with_polymorphic_mappers if not adapt_on_names - ], + }, ) if nest_adapters: |
