mirror of
https://github.com/django/django.git
synced 2025-10-26 15:16:09 +00:00
This issue started manifesting itself when nesting a combined subquery relying on exclude() since8593e162c9but sql.Query.combine never properly handled subqueries outer refs in the first place, see QuerySetBitwiseOperationTests.test_subquery_aliases() (refs #27149). Thanks Raffaele Salmaso for the report. Backport of6d0cbe42c3from main