Release Notes
Released on 2026-06-03.
Bug fixes
- Don't inject
Unknownfrom non-callable elements of intersection call (#25538) - Don't needlessly disambiguate the same type alias (#25563)
- Fix variance inference for nested type aliases (#25567)
- Ignore rejected member annotations for synthesized bindings (#25427)
- Normalize dynamic class literals in cycle recovery (#25558)
- Register file roots for first-party search paths (#25522)
- Treat union-bound typevars like unions for
possibly-missing-attribute(#25561)
LSP server
- Suppress importable completions that are already in scope (#25479)
Performance
- Avoid retaining duplicate function signatures (#25609)
- Compact retained definition inference results (#25593)
- Compact retained definition kinds (#25610)
- Compact retained definitions by node (#25498)
- Consolidate AST ID reverse lookup (#25455)
- Consolidate retained use-def definition maps (#25499)
- Omit redundant definitions-by-node entries (#25501)
- Reuse common protocol constraints for TypedDict unions (#25598)
Diagnostics
- Improve error context for not-iterable diagnostics (#24944)
Core type checking
- Detect disjointness due to incompatible generic specializations (#24822)
- Distinguish
typing.Callablefromcollections.abc.Callable(#24954) - Include nested
global/nonlocalbindings in type inference (#25387) - Optional lower/upper bounds in individual constraints (#25435)
- Preserve slice-bound types in subscript inference (#25446)
- Reject
Selfin type aliases (#25529) - Require literal booleans for TypedDict flags (#25594)
- Support narrowing on lengths (#25347)
- Synthesize precise
__len__methods for literals (#25600) - Use callable type context to implicitly specialize generic class (#25471)
- expand type aliases inside type context unions (#25553)
Contributors
Install ty 0.0.43
Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://releases.astral.sh/github/ty/releases/download/0.0.43/ty-installer.sh | shInstall prebuilt binaries via powershell script
powershell -ExecutionPolicy Bypass -c "irm https://releases.astral.sh/github/ty/releases/download/0.0.43/ty-installer.ps1 | iex"Download ty 0.0.43
Verifying GitHub Artifact Attestations
The artifacts in this release have attestations generated with GitHub Artifact Attestations. These can be verified by using the GitHub CLI:
gh attestation verify <file-path of downloaded artifact> --repo astral-sh/tyYou can also download the attestation from GitHub and verify against that directly:
gh attestation verify <file-path of downloaded artifact> --bundle <file-path of downloaded attestation>