-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Closed
Labels
auto-lockedOutdated issues that have been locked by automationOutdated issues that have been locked by automationtype: bugA confirmed bug or unintended behaviorA confirmed bug or unintended behavior
Milestone
Description
- Pip version: 10.0.0
- Python version: 3.6.5
- Operating system: Linux/Fedora
Description:
The requires
build dependency listings in pyproject.toml
doesn't appear to support PEP 508 environment markers.
Several projects appear to have expected pip would support this: pandas, scipy, pywt,
What I've run:
The following reproducer shell script
set -e -x
rm -rf mytest
mkdir mytest
cd mytest
python3 -mvenv env
./env/bin/pip install --upgrade 'pip>=10'
echo "assert False" > setup.py
cat <<EOF > pyproject.toml
[build-system]
requires = [
"wheel",
"setuptools",
"numpy==1.12.1;python_version<'3'",
"numpy==1.14.1;python_version>='3'",
]
EOF
./env/bin/pip wheel .
This prints
+ rm -rf mytest
+ mkdir mytest
+ cd mytest
+ python3 -mvenv env
+ ./env/bin/pip install --upgrade 'pip>=10'
Collecting pip>=10
Using cached pip-10.0.0-py2.py3-none-any.whl
Installing collected packages: pip
Found existing installation: pip 9.0.3
Uninstalling pip-9.0.3:
Successfully uninstalled pip-9.0.3
Successfully installed pip-10.0.0
+ echo 'assert False'
+ cat
+ ./env/bin/pip wheel .
Processing /home/pauli/tmp/foo2/mytest
Installing build dependencies ... error
Complete output from command /home/pauli/tmp/foo2/mytest/env/bin/python3 -m pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-5bwq_74_ https://pypi.python.org/packages/1b/d2/22cde5ea9af055f81814f9f2545f5ed8a053eb749c08d186b369959189a8/wheel-0.31.0-py2.py3-none-any.whl#md5=240d714477a715bcd90e94cb2c44f28c https://pypi.python.org/packages/20/d7/04a0b689d3035143e2ff288f4b9ee4bf6ed80585cc121c90bfd85a1a8c2e/setuptools-39.0.1-py2.py3-none-any.whl#md5=ca299c7acd13a72e1171a3697f2b99bc https://pypi.python.org/packages/b1/e2/884cfbfd4f21b2313210d1d2ea72ecc381b98826d1b7e6606929ac6c0a08/numpy-1.12.1-cp36-cp36m-manylinux1_x86_64.whl#md5=fbebdc68b7698e00c07bf4ddae0fb717 https://pypi.python.org/packages/de/7d/348c5d8d44443656e76285aa97b828b6dbd9c10e5b9c0f7f98eff0ff70e4/numpy-1.14.1-cp36-cp36m-manylinux1_x86_64.whl#md5=dd2321ea4590ec05d825d8c9a64fd64b:
Double requirement given: numpy==1.14.1 from https://pypi.python.org/packages/de/7d/348c5d8d44443656e76285aa97b828b6dbd9c10e5b9c0f7f98eff0ff70e4/numpy-1.14.1-cp36-cp36m-manylinux1_x86_64.whl#md5=dd2321ea4590ec05d825d8c9a64fd64b (already in numpy==1.12.1 from https://pypi.python.org/packages/b1/e2/884cfbfd4f21b2313210d1d2ea72ecc381b98826d1b7e6606929ac6c0a08/numpy-1.12.1-cp36-cp36m-manylinux1_x86_64.whl#md5=fbebdc68b7698e00c07bf4ddae0fb717, name='numpy')
----------------------------------------
Command "/home/pauli/tmp/foo2/mytest/env/bin/python3 -m pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-5bwq_74_ https://pypi.python.org/packages/1b/d2/22cde5ea9af055f81814f9f2545f5ed8a053eb749c08d186b369959189a8/wheel-0.31.0-py2.py3-none-any.whl#md5=240d714477a715bcd90e94cb2c44f28c https://pypi.python.org/packages/20/d7/04a0b689d3035143e2ff288f4b9ee4bf6ed80585cc121c90bfd85a1a8c2e/setuptools-39.0.1-py2.py3-none-any.whl#md5=ca299c7acd13a72e1171a3697f2b99bc https://pypi.python.org/packages/b1/e2/884cfbfd4f21b2313210d1d2ea72ecc381b98826d1b7e6606929ac6c0a08/numpy-1.12.1-cp36-cp36m-manylinux1_x86_64.whl#md5=fbebdc68b7698e00c07bf4ddae0fb717 https://pypi.python.org/packages/de/7d/348c5d8d44443656e76285aa97b828b6dbd9c10e5b9c0f7f98eff0ff70e4/numpy-1.14.1-cp36-cp36m-manylinux1_x86_64.whl#md5=dd2321ea4590ec05d825d8c9a64fd64b" failed with error code 1 in None
I would have expected it picks the a single appropriate numpy version based on the requirements markers, instead of trying to install two different versions and failing. (The test script will ultimately fail when it tries to run the setup.py --- in my real use I of course have a working setup.py but the behavior is the same).
alex, 9thbit and astrojuanlu
Metadata
Metadata
Assignees
Labels
auto-lockedOutdated issues that have been locked by automationOutdated issues that have been locked by automationtype: bugA confirmed bug or unintended behaviorA confirmed bug or unintended behavior