← 返回命令列表

Linux command

poetry-check 命令

文本

复制后可按需替换文件名、目录或参数。

常用示例

Check pyproject.toml validity

poetry check

Check with lock file validation

poetry check --lock

说明

poetry check validates the structure and content of the pyproject.toml file, ensuring that required fields are present and properly formatted. It catches configuration errors before they cause problems during install or build operations. The --lock option additionally verifies that the poetry.lock file is consistent with pyproject.toml and up-to-date. This is useful in CI pipelines to ensure the lock file hasn't drifted.

参数

--lock
Also validate poetry.lock file.

FAQ

What is the poetry-check command used for?

poetry check validates the structure and content of the pyproject.toml file, ensuring that required fields are present and properly formatted. It catches configuration errors before they cause problems during install or build operations. The --lock option additionally verifies that the poetry.lock file is consistent with pyproject.toml and up-to-date. This is useful in CI pipelines to ensure the lock file hasn't drifted.

How do I run a basic poetry-check example?

Run `poetry check` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does --lock do in poetry-check?

Also validate poetry.lock file.