SIGN IN SIGN UP
astral-sh / ruff UNCLAIMED

An extremely fast Python linter and code formatter, written in Rust.

0 0 41 Rust

[ty] Ignore and reject annotations on non-name targets (#25324)

## Summary

Like Mypy and Pyright, we now ignore annotations on non-name (i.e.,
subscript and attribute) targets, and emit a diagnostic for the invalid
annotation -- with the exception of annotated assignments on `self` and
class attributes (i.e., receivers).

Closes https://github.com/astral-sh/ty/issues/509.
C
Charlie Marsh committed
2428fca93267fe46340a850b105dc0d1681b9291
Parent: 7c55833
Committed by GitHub <noreply@github.com> on 5/27/2026, 1:59:49 PM