-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
locker: handle nested extras requirement
Previously, when using locked repository, incorrect dependency instance was created when a dependency's extra requirement activated a nested extra. This change ensures that these are correctly loaded. As part of this change new lock files write PEP 508 serialised form of extra dependencies in order to reuse core logic to parse specification of extra requirement. Resolves: #3224
- Loading branch information
Showing
5 changed files
with
222 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
tests/installation/fixtures/with-dependencies-nested-extras.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
[[package]] | ||
name = "A" | ||
version = "1.0" | ||
description = "" | ||
category = "main" | ||
optional = false | ||
python-versions = "*" | ||
|
||
[package.dependencies] | ||
B = {version = "^1.0", optional = true, extras = ["C"]} | ||
|
||
[package.extras] | ||
B = ["B[C] (>=1.0,<2.0)"] | ||
|
||
[[package]] | ||
name = "B" | ||
version = "1.0" | ||
description = "" | ||
category = "main" | ||
optional = false | ||
python-versions = "*" | ||
|
||
[package.dependencies] | ||
C = {version = "^1.0", optional = true} | ||
|
||
[package.extras] | ||
C = ["C (>=1.0,<2.0)"] | ||
|
||
[[package]] | ||
name = "C" | ||
version = "1.0" | ||
description = "" | ||
category = "main" | ||
optional = false | ||
python-versions = "*" | ||
|
||
[metadata] | ||
python-versions = "*" | ||
lock-version = "1.1" | ||
content-hash = "123456789" | ||
|
||
[metadata.files] | ||
"A" = [] | ||
"B" = [] | ||
"C" = [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters