From cf3b0c0d118053fc55ee7ec722169481c4606f1c Mon Sep 17 00:00:00 2001 From: KotlinIsland Date: Sun, 12 Feb 2023 19:32:34 +1000 Subject: [PATCH] docs: mention the different types of exact specifications and pep440 --- docs/dependency-specification.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/dependency-specification.md b/docs/dependency-specification.md index 3e7f55f755f..85521383b87 100644 --- a/docs/dependency-specification.md +++ b/docs/dependency-specification.md @@ -79,11 +79,15 @@ Multiple version requirements can also be separated with a comma, e.g. `>= 1.2, You can specify the exact version of a package. -`==1.2.3` is an example of an exact version specification. +`1.2.3` is an example of an exact version specification. This will tell Poetry to install this version and this version only. If other dependencies require a different version, the solver will ultimately fail and abort any install or update procedures. +Exact versions can also be specified with `==` according to [PEP 440](https://peps.python.org/pep-0440/). + +`==1.2.3` is an example of this. + ### Using the `@` operator When adding dependencies via `poetry add`, you can use the `@` operator.