mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-30 13:51:16 +00:00
[ty] Update docs for Python version inference (#18397)
This commit is contained in:
parent
88866f0048
commit
b390b3cb8e
2 changed files with 5 additions and 6 deletions
|
@ -82,10 +82,10 @@ pub(crate) struct CheckCommand {
|
|||
/// type definitions of first- and third-party modules that are conditional on the Python version.
|
||||
///
|
||||
/// By default, the Python version is inferred as the lower bound of the project's
|
||||
/// `requires-python` field from the `pyproject.toml`, if available. Otherwise, the latest
|
||||
/// stable version supported by ty is used, which is currently 3.13.
|
||||
///
|
||||
/// ty will not infer the Python version from the Python environment at this time.
|
||||
/// `requires-python` field from the `pyproject.toml`, if available. Otherwise, if a virtual
|
||||
/// environment has been configured or detected and a Python version can be inferred from the
|
||||
/// virtual environment's metadata, that version will be used. If neither of these applies, ty
|
||||
/// will fall back to the latest stable Python version supported by ty (currently 3.13).
|
||||
#[arg(long, value_name = "VERSION", alias = "target-version")]
|
||||
pub(crate) python_version: Option<PythonVersion>,
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue