ty – fast Python type checker and language server

ty is a Python static type checker and language server. It uses a Rust implementation to provide responsive analysis of Python source code, with particular emphasis on interactive development workflows.

Static type checking helps identify inconsistencies in how variables, functions and objects are used without requiring the program to run. ty supports the gradual adoption of type checking, allowing developers to introduce stronger checks while continuing to work with partially annotated code.

Its language server shares the underlying analysis engine with the command-line tool. This approach helps provide consistent diagnostics while editing files and when checking an entire project. The software is intended to work alongside Ruff rather than replace its conventional linting and formatting functionality.

This is free and open source software.

Key Features

  • Uses fine-grained incremental analysis to update diagnostics when affected source files change.
  • Supports configurable diagnostic rules, severity levels and file-specific overrides.
  • Provides type inference, type narrowing, intersection types and reachability analysis.
  • Includes language server functionality for completion, navigation, hover information, auto-imports and code actions.
  • Supports inlay hints to show inferred information within compatible editors.
  • Recognises Python project environments and third-party type information.
  • Offers configuration through pyproject.toml and dedicated configuration files.
  • Allows developers to suppress specific findings through supported source comments.
  • Provides command-line checking suitable for editor tasks and automated validation.

Website: github.com/astral-sh/ty
Support:
Developer: Astral Software Inc.
License: MIT License

ty is written in Rust. Learn Rust with our recommended free books and free tutorials.


Related Software

Python Linters
RuffExtremely fast Python linter and code formatter
tyFast Python type checker
MypyStatic type checker for Python
BanditFind security issues in Python code
PylintStatic code analyser
wemake-python-styleguideFlake8 plugin
TachEnforces module dependencies and architectural boundaries
pycodestyleCheck Python code against style conventions in PEP 8
PyflakesChecks Python source files for errors
VultureFind dead code
PyreflyFast type checker and language server
Flake8Wrapper around PyFlakes and pycodestyle
BeartypeNear-real-time hybrid runtime-static type-checker
RadonComputes various metrics from Python code
PyrightFull-featured, standards-compliant static type checker
cython-lintLint Cython files
basedpyrightFork of pyright
RefurbModernize Python codebases
PylamaCode audit tool for Python
ProspectorBrings together the functionality of other Python analysis tools
deptryCheck for dependency issues
FixitHighly configurable linting framework
complexipyMeasures cognitive complexity in Python code
ZubanHigh-performance Python type checker and language server
PyromaRates how well a Python project compiles
pydoclintPython docstring linter
AridFast duplicate code detection for Python projects

Read our verdict in the software roundup.


Best Free and Open Source Software LinuxLinks helps you discover the best free and open source software for Linux. Explore our extensive collection of recommended applications, including alternatives to popular proprietary software.

We also publish software reviews, Linux tutorials, hardware reviews, free programming books and articles covering the wider open source community. Browse our Linux resources to discover more.

Know a useful free and open source Linux application we haven't covered? Suggest a program for inclusion.

Has your software been featured on LinuxLinks? Display one of our Featured on LinuxLinks badges on your website or GitHub README.
Subscribe

Please read our Comment Policy before commenting.

Notify of
guest
0 Comments
Oldest
Newest Most Voted