billions-spring-9652
12/19/2021, 4:44 PMinterpreter_constraints = ["CPython==3.10.*"]
.
I'm on ubuntu 18.04 (bionic) and my python3.10 binary is from the deadsnakes ppa.
This is what I get:
ProcessExecutionFailure: Process 'Find interpreter for constraints: CPython==3.10.*' failed with exit code 102.
stdout:
stderr:
Could not find a compatible interpreter.
Examined the following interpreters:
1.) /usr/bin/python2.7 CPython==2.7.17
2.) /usr/bin/python3.6 CPython==3.6.9
3.) /usr/bin/python3.8 CPython==3.8.0
4.) /usr/bin/python3.9 CPython==3.9.9
(That 3.9.9 version is from deadsnakes as well. If I specify CPython==3.9.*, it's picked up and everything's fine).
So, is my python3.10 installation broken somehow, or not supported?fast-nail-55400
12/19/2021, 4:52 PMpants.toml
? From that output, it seems like Pants did not even find the python
binary.billions-spring-9652
12/19/2021, 4:56 PM["<PYENV>", "/usr/local/bin", "/usr/bin"]
earlier. Same effect.enough-analyst-54434
12/19/2021, 5:02 PMenough-analyst-54434
12/19/2021, 5:04 PMbillions-spring-9652
12/19/2021, 5:10 PMpants_version = "2.9.0rc0"
, and I get the same thing. I suppose there's something specific going on with my setup.billions-spring-9652
12/19/2021, 5:12 PMbillions-spring-9652
12/19/2021, 5:44 PMpython3 ./pex --interpreter-constraint $'CPython==3.10.*' -- -c 'print(42)'
gives the familiar constraint failure, but if I specifically invoke python3.10, that is:
python3.10 ./pex --interpreter-constraint $'CPython==3.10.*' -- -c 'print(42)'
, that works!enough-analyst-54434
12/19/2021, 6:20 PMenough-analyst-54434
12/19/2021, 6:24 PMenough-analyst-54434
12/19/2021, 6:27 PMenough-analyst-54434
12/19/2021, 8:07 PMbillions-spring-9652
12/19/2021, 8:07 PMbillions-spring-9652
12/19/2021, 8:26 PMbillions-spring-9652
12/19/2021, 9:06 PMenough-analyst-54434
12/19/2021, 9:06 PM$ cat Dockerfile
FROM ubuntu:18.04
RUN apt-get update && \
apt-get install -y software-properties-common && \
add-apt-repository -y ppa:deadsnakes/ppa
RUN apt-get update && \
apt-get install -y \
curl \
python \
python-dev \
python3.8 \
python3.8-dev \
python3.8-venv \
python3.8-distutils \
python3.9 \
python3.9-dev \
python3.9-venv \
python3.9-distutils \
python3.10 \
python3.10-dev \
python3.10-venv \
python3.10-distutils
$ docker build -t bionic:deadsnakes-310 .
Sending build context to Docker daemon 2.048kB
Step 1/3 : FROM ubuntu:18.04
---> 5a214d77f5d7
Step 2/3 : RUN apt-get update && apt-get install -y software-properties-common && add-apt-repository -y ppa:deadsnakes/ppa
---> Using cache
---> b1b5a578052e
Step 3/3 : RUN apt-get update && apt-get install -y curl python python-dev python3.8 python3.8-dev python3.8-venv python3.8-distutils python3.9 python3.9-dev python3.9-venv python3.9-distutils python3.10 python3.10-dev python3.10-venv python3.10-distutils
---> Using cache
---> 29464760100f
Successfully built 29464760100f
Successfully tagged bionic:deadsnakes-310
$ docker run --rm -it bionic:deadsnakes-310 bash -i
root@f4f52262c693:/# curl -sSL <https://github.com/pantsbuild/pex/releases/download/v2.1.56/pex> > pex-2.1.56
root@f4f52262c693:/# chmod +x pex-2.1.56
root@f4f52262c693:/# ./pex-2.1.56 --interpreter-constraint "==3.11.*"
Could not find a compatible interpreter.
Examined the following interpreters:
1.) /usr/bin/python2.7 CPython==2.7.17
2.) /usr/bin/python3.6 CPython==3.6.9
3.) /usr/bin/python3.8 CPython==3.8.12
4.) /usr/bin/python3.9 CPython==3.9.9
No interpreter compatible with the requested constraints was found:
Version matches ==3.11.*
root@f4f52262c693:/#
enough-analyst-54434
12/19/2021, 9:07 PMenough-analyst-54434
12/19/2021, 9:10 PMroot@f4f52262c693:/# rm -rf ~/.pex/
root@f4f52262c693:/# ./pex-2.1.56 -vvvvvvvvvv --interpreter-constraint "==3.11.*"
pex: Spawning a maximum of 16 parallel jobs to process:
/usr/bin/python
/usr/bin/python2
/usr/bin/python2.7
/usr/bin/python3
/usr/bin/python3.6
/usr/bin/python3.6m
/usr/bin/python3.8
/usr/bin/python3.9
pex: Hashing pex: 20.0ms
...
billions-spring-9652
12/19/2021, 9:11 PMenough-analyst-54434
12/19/2021, 9:11 PMbillions-spring-9652
12/19/2021, 9:12 PMenough-analyst-54434
12/19/2021, 9:12 PMbillions-spring-9652
12/19/2021, 9:15 PMenough-analyst-54434
12/19/2021, 9:15 PMbillions-spring-9652
12/19/2021, 9:18 PMenough-analyst-54434
12/19/2021, 9:23 PMbillions-spring-9652
12/19/2021, 9:32 PM