-
-
Notifications
You must be signed in to change notification settings - Fork 286
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix lock downloads to use all lock info. #2396
Conversation
Previously, the lock target systems and requires python configuration were left out, which could lead to critical Pip runtime patches being left off; causing downloads to fail when they should not. Fixes pex-tool#2395
complete_platform = data.path("platforms", "complete_platform_linux_x86-64_py11.json") | ||
pex = os.path.join(str(tmpdir), "pex") | ||
shutil.rmtree(pex_root) | ||
run_pex_command( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After the 1st commit this fails just like the reported repro case:
...
__________________________________________________________________________________ test_download_incompatible_python
...
E pex: Building pex :: Resolving distributions for requirements: pbipy==2.8.2 :: Resolving requirements from lock file /tmp/pytest-of-jsirois/pytest-8/test_download_incompatible_pyt0/lock.json :: Categorizing 8 downloaded artifacts
E There was 1 error downloading required artifacts:
E 1. pbipy 2.8.2 from http://0.0.0.0:41645/root/pypi/%2Bf/fc9/ff27ad81b2ee3/pbipy-2.8.2-py2.py3-none-any.whl
E ERROR: Package 'pbipy' requires a different Python: 3.9.13 not in '>=3.10'
testing/__init__.py:380: AssertionError
======================================================================================= short test summary info =======================================================================================
FAILED tests/integration/test_issue_2395.py::test_download_incompatible_python - AssertionError: integration test failed: return_code=1, output=, error=pex: Parsing lock /tmp/pytest-of-jsirois/pytest-8/test_download_incompatible_pyt0/lock.json
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Integration test makes sense to me and the fix also makes sense to me. I actually think I may have run into this before once.
Previously, the lock target systems and requires python configuration
were left out, which could lead to critical Pip runtime patches being
left off; causing downloads to fail when they should not.
Fixes #2395