-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5017 from pypa/potential-subdir-fix
Subdirectory vcs installs are never passing the subdirectory in requirementslib which is now required by setuptools
- Loading branch information
Showing
11 changed files
with
134 additions
and
30 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Environment variables were not being loaded when the `--quiet` flag was set |
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 @@ | ||
Adds missing unit test coverage for recent bug fixes. |
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,4 @@ | ||
It would appear that ``requirementslib`` was not fully specifying the subdirectory to ``build_pep517`` and | ||
and when a new version of ``setuptools`` was released, the test ``test_lock_nested_vcs_direct_url`` | ||
broke indicating the Pipfile.lock no longer contained the extra dependencies that should have been resolved. | ||
This regression affected ``pipenv>=2021.11.9`` but has been fixed by a patch to ``requirementslib``. |
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
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
30 changes: 30 additions & 0 deletions
30
tasks/vendoring/patches/vendor/requirementslib-subdir-fix.patch
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,30 @@ | ||
diff --git a/pipenv/vendor/requirementslib/models/setup_info.py b/pipenv/vendor/requirementslib/models/setup_info.py | ||
index 772a4d81..dc001f36 100644 | ||
--- a/pipenv/vendor/requirementslib/models/setup_info.py | ||
+++ b/pipenv/vendor/requirementslib/models/setup_info.py | ||
@@ -13,7 +13,7 @@ import sys | ||
from collections.abc import Iterable, Mapping | ||
from functools import lru_cache, partial | ||
from pathlib import Path | ||
-from urllib.parse import urlparse, urlunparse | ||
+from urllib.parse import parse_qs, urlparse, urlunparse | ||
from weakref import finalize | ||
|
||
import pipenv.vendor.attr as attr | ||
@@ -1230,8 +1230,15 @@ build-backend = "{1}" | ||
) | ||
) | ||
need_delete = True | ||
+ | ||
+ parsed = urlparse(str(self.ireq.link)) | ||
+ subdir = parse_qs(parsed.fragment).get('subdirectory', []) | ||
+ if subdir: | ||
+ directory = f"{self.base_dir}/{subdir[0]}" | ||
+ else: | ||
+ directory = self.base_dir | ||
result = build_pep517( | ||
- self.base_dir, | ||
+ directory, | ||
self.extra_kwargs["build_dir"], | ||
config_settings=self.pep517_config, | ||
dist_type="wheel", |
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
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