ty Configurations
Tip
Official documentation for ty is available at https://github.com/astral-sh/ty
Info
ty is a fast type checker for Python built by Astral (the creators of uv and Ruff).
| ty.toml | |
|---|---|
1 2 3 | |
Configuration Options
- include: List of directories or files to include in type checking
-
Currently includes
tools/package,tests/directory, andnoxfile.py -
exclude: List of patterns to exclude from type checking
- Cache directories:
**/__pycache__,.pytest_cache,.ruff_cache - Virtual environment:
.venv
Adding New Directories
Danger
If you create new directories in the root directory that should be type-checked, you must add them to the include list in the ty.toml file.
Example:
1 2 3 | |