ruff
ffa26592 - [ty] Avoid relation queries during cycle recovery (#26335)

Commit
129 days ago
[ty] Avoid relation queries during cycle recovery (#26335) ## Summary Union construction during Salsa cycle recovery already skips the final full-reduction block, but literal insertion and grouped-literal reduction could still ask semantic type-relation questions. Comparing a literal with a runtime-checkable protocol instance could therefore resolve protocol members, re-enter the expression inference query being recovered, and panic with a new Salsa cycle. This skips relation-based simplification throughout cycle-recovery union construction. The regression coverage reproduces the Python 3.14 crash and separately protects widening for integer, string, bytes, and enum literals. Closes https://github.com/astral-sh/ty/issues/3851.
Author
Parents
Loading