ty¶
footman._stubs.ty.Ty
¶
Bases: Tool
check
¶
check(
*args: str,
add_ignore: _Flag = ...,
color: Literal["auto", "always", "never"]
| Sequence[Literal["auto", "always", "never"]]
| None = ...,
config: _Value = ...,
config_file: _Value = ...,
error: _Value = ...,
error_on_warning: _Flag = ...,
exclude: _Value = ...,
exit_zero: _Flag = ...,
exit_zero_on_warning: _Flag = ...,
extra_search_path: _Value = ...,
fix: _Flag = ...,
force_exclude: _Flag = ...,
ignore: _Value = ...,
no_progress: _Flag = ...,
output_format: Literal[
"full", "concise", "gitlab", "github", "junit"
]
| Sequence[
Literal[
"full", "concise", "gitlab", "github", "junit"
]
]
| None = ...,
project: _Value = ...,
python: _Value = ...,
python_platform: _Value = ...,
python_version: Literal[
"3.7",
"3.8",
"3.9",
"3.10",
"3.11",
"3.12",
"3.13",
"3.14",
"3.15",
]
| Sequence[
Literal[
"3.7",
"3.8",
"3.9",
"3.10",
"3.11",
"3.12",
"3.13",
"3.14",
"3.15",
]
]
| None = ...,
quiet: _Flag = ...,
respect_ignore_files: _Flag = ...,
typeshed: _Value = ...,
verbose: _Flag = ...,
warn: _Value = ...,
watch: _Flag = ...,
**flags: Any,
) -> Result
Check a project for type errors
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
add_ignore
|
_Flag
|
Adds |
...
|
color
|
Literal['auto', 'always', 'never'] | Sequence[Literal['auto', 'always', 'never']] | None
|
Control when colored output is used. |
...
|
config
|
_Value
|
A TOML |
...
|
config_file
|
_Value
|
The path to a |
...
|
error
|
_Value
|
Treat the given rule as having severity 'error'. May be repeated: a list emits the flag once per item. |
...
|
error_on_warning
|
_Flag
|
Use exit code 1 if there are any warning-level diagnostics. |
...
|
exclude
|
_Value
|
Glob patterns for files to exclude from type checking. |
...
|
exit_zero
|
_Flag
|
Always use exit code 0, even when there are error-level diagnostics. |
...
|
exit_zero_on_warning
|
_Flag
|
Use exit code 0 if there are no error-level diagnostics. |
...
|
extra_search_path
|
_Value
|
Additional path to use as a module-resolution source (can be passed multiple times). May be repeated: a list emits the flag once per item. |
...
|
fix
|
_Flag
|
Apply fixes to resolve errors. |
...
|
force_exclude
|
_Flag
|
Enforce exclusions, even for paths passed to ty directly
on the command-line. |
...
|
ignore
|
_Value
|
Disables the rule. May be repeated: a list emits the flag once per item. |
...
|
no_progress
|
_Flag
|
Hide all progress outputs. |
...
|
output_format
|
Literal['full', 'concise', 'gitlab', 'github', 'junit'] | Sequence[Literal['full', 'concise', 'gitlab', 'github', 'junit']] | None
|
The format to use for printing diagnostic messages. |
...
|
project
|
_Value
|
Run the command within the given project directory. |
...
|
python
|
_Value
|
Path to your project's Python environment or interpreter. |
...
|
python_platform
|
_Value
|
Target platform to assume when resolving types. |
...
|
python_version
|
Literal['3.7', '3.8', '3.9', '3.10', '3.11', '3.12', '3.13', '3.14', '3.15'] | Sequence[Literal['3.7', '3.8', '3.9', '3.10', '3.11', '3.12', '3.13', '3.14', '3.15']] | None
|
Python version to assume when resolving types. |
...
|
quiet
|
_Flag
|
Use quiet output (or |
...
|
respect_ignore_files
|
_Flag
|
Respect file exclusions via |
...
|
typeshed
|
_Value
|
Custom directory to use for stdlib typeshed stubs. |
...
|
verbose
|
_Flag
|
Use verbose output (or |
...
|
warn
|
_Value
|
Treat the given rule as having severity 'warn'. May be repeated: a list emits the flag once per item. |
...
|
watch
|
_Flag
|
Watch files for changes and recheck files related to the changed files. |
...
|