Editing Poetry dependencies
Pin a sealed version in pyproject.toml using poetry add (direct dependencies only).
Direct dependencies
Poetry's manifest is pyproject.toml. The cleanest way to pin a sealed version is through the poetry add command, which writes both the version and the lockfile entry:
poetry add requests==2.31.0+sp1Run poetry install afterward to make sure the virtual environment matches.
To edit pyproject.toml by hand, the relevant block is:
[tool.poetry.dependencies]
python = "^3.10"
-requests = "2.31.0"
+requests = "2.31.0+sp1"Transitive dependencies
This page covers direct dependencies only. For overriding transitive dependencies in Poetry, work with your Seal account team to confirm the right pattern for your project's setup.
Related
Configuring Poetry: the package-manager setup that points Poetry at the Seal Artifact Server.
Editing pip dependencies: the pip equivalent, including the pin-as-direct mechanism for transitive overrides.
Last updated