Skip to content

chore(deps): update dependency ty to v1.1.0 - #1965

Open
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/ty-1.x
Open

renovate[bot] wants to merge 1 commit into
mainfrom
renovate/ty-1.x

Conversation

@renovate

@renovate renovate Bot commented Dec 3, 2026

Copy link
Copy Markdown
Contributor

This PR contains the following updates:

Package Change Age Confidence
ty (changelog) ==1.0.0 → ==1.1.0 age confidence

Release Notes

astral-sh/ty (ty)

v1.1.0

Compare Source

Released on 2026-12-03.

Bug fixes
  • Report invalid-assignment for unsupported item or slice assignments even after a check such as out is not None narrows an object. (#​30011)
  • Check assignments to a Django model instance’s pk using the underlying field’s write type, including Django expressions where the field accepts them. On the model class, pk has type property, so accessing a primary-key value attribute such as Book.pk.hex reports missing-attribute. (#​31269)
  • Infer the stored ID type for a Django relation’s <field>_id when to_field names another relation. If the field is also the primary key, pk gets the same ID type. (#​31268)
  • Preserve the NewType when a protocol uses a method whose return annotation is Self. For example, ExitStack.enter_context now returns the wrapped context manager’s NewType when its __enter__ returns Self. (#​31211)
  • Preserve attribute types when a NewType wraps a class, including enum values, attributes supplied by a metaclass, and assignment types from dataclass field converters. Protocol checks use those types too. (#​31234)
  • Infer enum members’ name and value attributes using Python’s override rules, including cases where an inherited enum.property supplies the value or a bare annotation leaves the generated property in place. (#​31234)
  • Recognize that a NewType based on object can hold unhashable values, including through nested NewTypes. The negative branch of an isinstance(value, Hashable) check remains reachable, and unions with Hashable retain both alternatives. (#​31232)
  • Report cyclic-class-definition for every class that participates in overlapping inheritance cycles, regardless of the order of its base classes. (#​31298)
  • Report invalid-type-form when an IPython escape command such as !pwd appears where a type is expected in a notebook, preventing a crash. (#​31238)
  • Fix false slot conflicts and missing-attribute errors when a lambda in a class-body loop uses := to bind a local variable with the same name as a slot. (#​31150)
  • Highlight references only in the requested notebook cell so references in other cells don’t highlight unrelated code. (#​31243)
  • Limit notebook document outlines to symbols defined in the requested cell. (#​31243)
  • Fade the correct code in each notebook cell when an unreachable region spans multiple cells. (#​31248)
LSP server
  • Offer completions for generated attributes and methods on Django model classes and instances, including inherited members such as foreign-key IDs, choice display methods, and date navigation methods. (#​31272)
  • Distinguish escape sequences in semantic highlighting for strings, bytes, and the literal parts of f-strings and t-strings. Backslashes in raw strings retain ordinary string highlighting. (#​31239)
  • Fix Expand Selection in notebooks so it includes intermediate expressions and stops at the current cell’s contents. (#​31241)
  • Restore code folding for import blocks that end at a notebook cell boundary. (#​31241)
  • Reduce the work needed for semantic highlighting, reference highlighting, code folding, and document outlines by reusing source text and line positions within each request. (#​30669)
CLI
  • Show file counts as ty check --fix and ty check --add-ignore apply edits and recheck the project, with a separate indicator while writing changes. (#​31147)
  • Make completed and remaining work easier to distinguish in progress bars when checking files or syncing script dependencies. (#​31200)
Diagnostic improvements
  • Add autofixes for mismatched-*-name diagnostics that make the supplied name match the assignment target. ty check --fix applies fixes marked safe. Fixes for enums, named tuples, and sentinels are always marked unsafe. (#​30628)
Performance improvements
  • Reduce work when opening or closing unchanged files with diagnosticMode set to openFilesOnly by reusing prior analysis. ty continues to report diagnostics only for open files. (#​31252)
  • Reduce memory use when looking up a method on a large union of unrelated subclasses that inherit the same method. (#​31288)
  • Resolve calls with multiple matching overloads faster when ty can rule out later overloads without building unions of the parameter types. (#​31250)
  • Specialize nested generic types such as dict[str, list[T]] faster by skipping ParamSpec work for types without callable signatures. (#​31195)
  • Specialize generic types faster by reusing declared variance, such as the invariance of list’s type parameter. (#​31173)
  • Analyze try blocks faster by skipping repeated work to determine what values can reach an except handler when assignments and narrowing conditions are unchanged. (#​31260)
Memory usage improvements
  • Reduce peak memory while analyzing files with many independent scopes, such as stubs with hundreds of methods. (#​31171)
  • Use less memory to track which assignments and declarations can reach a given point in the code, especially when there is only one possible definition. (#​31168)
  • Use less memory when simplifying unions by storing each pair of types once when checking redundancy in both directions. (#​31182)
  • Reuse unchanged parameter lists when specializing callable types, as when Callable[[int], T] becomes Callable[[int], str]. (#​31161)
Core type checking
  • Resolve imports across legacy namespace packages that set __path__ at module scope using from pkgutil import extend_path, including aliases for extend_path or pkgutil. (#​31274)
  • Infer the tuple length and element types returned by struct.unpack_from from a known format string. For example, struct.unpack_from("<I?", buf) returns tuple[int, bool]. (#​31230)
  • Infer more precise TypedDict.get results for unions of known literal keys when the fields have identical declared types and are either all required or all optional. For optional fields, ty also uses the shared field type to infer defaults such as {}. (#​30897)
  • Resolve inherited method signatures correctly when checking mutually importing files in parallel and a protocol method’s return type refers back to the protocol through Self. (#​29818)
Other changes
  • Explain how to install third-party stubs when migrating from Pyright, with uv add --dev types-PyYAML as an example, and how ty automatically uses stub packages already installed for mypy. (#​5207)
Contributors

Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Enabled.

♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate Bot added the dependencies Third-party library dependencies. label Dec 3, 2026
@renovate
renovate Bot enabled auto-merge (rebase) December 3, 2026 21:15

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Third-party library dependencies.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants