[ty] Fix false-positive unsupported-operator for "symmetric" TypeVars by charliermarsh · Pull Request #22756 · astral-sh/ruff (original) (raw)
added bug
Something isn't working
Multi-file analysis & type inference
labels
charliermarsh changed the title
[ty] Fix false-positive unsupported-operator for constrained TypeVars [ty] Fix false-positive unsupported-operator for symmetric TypeVars
charliermarsh changed the title
[ty] Fix false-positive [ty] Fix false-positive unsupported-operator for symmetric TypeVarsunsupported-operator for "symmetric" TypeVars
This was referenced
Jan 23, 2026
Union the return types
Add more tests
Also support unary
Limit to symmetric typevar
Simplfiy tests
carljm added a commit that referenced this pull request
- main: (62 commits)
[
refurb] Do not addabc.ABCif already present (FURB180) (#22234) [ty] Add a newassert-type-unspellable-subtypediagnostic (#22815) [ty] Avoid duplicate syntax errors forawaitoutside functions (#22826) [ty] Fix unary operator false-positive for constrained TypeVars (#22783) [ty] Fix binary operator false-positive for constrained TypeVars (#22782) [ty] Fix false-positiveunsupported-operatorfor "symmetric" TypeVars (#22756) [pydocstyle] Clarify which quote styles are allowed (D300) (#22825) [ty] Use distributed versions of AND and OR on constraint sets (#22614) [ty] Add support for dict literals and dict() calls as default values for parameters with TypedDict types (#22161) Document-stdin convention in CLI help text (#22817) [ty] Makeinfer_subscript_expression_typesa method onType(#22731) [ty] SimplifyOverloadLiteral::spansandOverloadLiteral::parameter_span(#22823) [ty] Require both*argsand**kwargswhen calling aParamSpeccallable (#22820) [ty] Handle tagged errors in conformance (#22746) Add--colorcli option to force colored output (#22806) Identify notebooks by LSP didOpen instead of.ipynbfile extension (#22810) [ty] Fix docstring rendering for literal blocks after doctests (#22676) [ty] Update salsa to fix out-of-order query validation (#22498) [ty] Inline cycle initial and recovery functions (#22814) [ty] Pass the generic context through the decorator (#22544) ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})