Check poetry.lock for vulnerable dependencies
Upload or paste your poetry.lock. We check every Python package version in it
against OSV.dev and email you the
vulnerable ones, the version that fixes them and the Poetry command to upgrade. Free, and no account needed.
About poetry.lock
poetry.lock is written by Poetry next to pyproject.toml. It records the exact version of every package Poetry resolved, direct and indirect, so it is the file to check, not pyproject.toml.
To write or refresh it:
poetry lock
Commit it with pyproject.toml so every machine and CI run installs the same versions.
Good to know
- pyproject.toml alone cannot be checked: it has version constraints, not the installed versions.
- Development dependencies (test and lint tools) are in the lockfile too and are checked: they run on developer machines and in CI.
- A stale lockfile (older than pyproject.toml) shows what was locked, not what you meant to install. Run poetry lock after changing pyproject.toml.
Fixing a vulnerable package
The report gives the fixed version for each vulnerable package (FIXED below). With Poetry:
# Upgrade within your constraints
poetry update package
# Or raise the constraint to the fixed version
poetry add "package@^FIXED"
For an indirect dependency, poetry update with the package name also works when the parent package allows the fixed version; otherwise upgrade the parent package.
Then run your tests and commit the updated poetry.lock.
pip-audit on an exported requirements file and this check
Poetry has no built-in audit command; pip-audit can check an exported requirements file. This check reads poetry.lock directly, with nothing to install or export.
Other lockfiles
Questions
Do I need to export my lockfile first?
No. Paste or upload poetry.lock as it is: we read the package names and versions from it.
Related free tools
GitHub repo vulnerability check
Paste a public GitHub repo URL. We find every lockfile, check each package version against OSV.dev and email you the fixes. Free, no account.
Dependency vulnerability check
Check requirements.txt, package-lock.json, poetry.lock and more against OSV.dev. Free report by email with fix commands. No account needed.
Last updated .