ripe-kitchen-64238
09/29/2021, 10:22 PMException message: 1 Exception encountered:
ProcessExecutionFailure: Process 'Building requirements.pex with 3 requirements: pandas<2.0.0,>=1.3.3, pytz<2022.0.0,>=2021.1, requests<3.0.0,>=2.26.0' failed with exit code 1.
stdout:
stderr:
ERROR: Could not find a version that satisfies the requirement pandas<2.0.0,>=1.3.3
ERROR: No matching distribution found for pandas<2.0.0,>=1.3.3pandas 1.3.3 definitely exists, I'm not sure why specifically pandas and numpy are causing problems but doing the same thing for other dependencies is fine 🤔 Any suggestions on where to look for this? Thanks!
happy-kitchen-89482
09/29/2021, 10:34 PMbored-art-40741
09/29/2021, 10:36 PMripe-kitchen-64238
09/29/2021, 10:39 PMpython = ">=3.8,<3.11"the venv in pycharm has spun up 3.9.5 ..but weirdly:
============================= test session starts ==============================
platform linux -- Python 3.6.14, pytest-6.2.5, py-1.10.0, pluggy-1.0.0it looks like pants is trying to use 3.6? I am not sure where that could have even come from 🤔
ripe-kitchen-64238
09/29/2021, 10:42 PM[python-setup]
interpreter_constraints = ["CPython==3.8.*"]is complaining about things to do with 3.6 some more, I'll see if I can find where that could be coming from 🤔
ripe-kitchen-64238
09/29/2021, 10:44 PMripe-kitchen-64238
09/29/2021, 11:02 PMstderr:
Could not find a compatible interpreter.
Examined the following working interpreters:
1.) /home/mgeeves/.pyenv/versions/3.6.14/bin/python3.6 CPython==3.6.14
2.) /usr/bin/python3.9 CPython==3.9.5
Skipped the following broken interpreters:
1.) /home/mgeeves/.pyenv/shims/python3.6:
pyenv: python3.6: command not found
The `python3.6' command exists in these Python versions:
3.6.14I would have expected Pants to create the venv using the "system default" (or the venv currently in use even) - in this case 3.9.5 for both - over the pyenv one but maybe that's intentional? Let me know if that sounds odd and I can provide any info, otherwise I'll just remember to always specify the interpreter_constraints version and at some point take another look at pyenv 🤔
ripe-kitchen-64238
09/29/2021, 11:27 PMmgeeves@bearly:~$ pyenv versions
* system (set by /home/mgeeves/.pyenv/version)
3.6.14
mgeeves@bearly:~$ pyenv global
system
mgeeves@bearly:~$ python --version
Python 3.9.5
mgeeves@bearly:~$ pyenv install 3.9.5
Downloading Python-3.9.5.tar.xz...
-> https://www.python.org/ftp/python/3.9.5/Python-3.9.5.tar.xz
Installing Python-3.9.5...
Installed Python-3.9.5 to /home/mgeeves/.pyenv/versions/3.9.5
mgeeves@bearly:~$ pyenv versions
* system (set by /home/mgeeves/.pyenv/version)
3.6.14
3.9.5
mgeeves@bearly:~$ pyenv global 3.9.5
mgeeves@bearly:~$ pyenv versions
system
3.6.14
* 3.9.5 (set by /home/mgeeves/.pyenv/version)As far as pyenv is concerned, 3.6.14 isn't expected to be the one in use, however even with a .python-version file as well as the global being set to 3.9.5, if I don't specify interpreter_constraints I get:
pid 4150743 -> /home/mgeeves/.cache/pants/named_caches/pex_root/venvs/202fc486cd05d66fe2f93e6bcb0f03fb4a9fe241/83a29cf2dfb126e8fb81d2f6e6b8859e39535f04/pex --disable-pip-version-check --no-python-version-warning --exists-action a --isolated -q --cache-dir /home/mgeeves/.cache/pants/named_caches/pex_root --log /tmp/process-executionDzVB86/.tmp/tmpikiew1xj/pip.log download --dest /tmp/process-executionDzVB86/.tmp/tmpynwn177c/home.mgeeves..pyenv.versions.3.6.14.bin.python3.6 numpy<2.0.0,>=1.21.2 pandas<2.0.0,>=1.3.3 pytz<2022.0.0,>=2021.1 requests<3.0.0,>=2.26.0 --index-url https://pypi.org/simple/ --retries 5 --timeout 15I don't think it should be picking up 3.6 there 🤔 (again, fine for me now I know what to add, let me know if there's anything else useful I could look at etc)
ripe-kitchen-64238
09/29/2021, 11:56 PMhappy-kitchen-89482
09/30/2021, 3:29 AMhappy-kitchen-89482
09/30/2021, 3:32 AMhappy-kitchen-89482
09/30/2021, 3:33 AMhappy-kitchen-89482
09/30/2021, 3:33 AMhappy-kitchen-89482
09/30/2021, 3:34 AMhappy-kitchen-89482
09/30/2021, 3:40 AMhappy-kitchen-89482
09/30/2021, 3:41 AMhappy-kitchen-89482
09/30/2021, 3:42 AM["<PYENV>"]
means "the only interpreters Pants will use are pyenv interpreters, never mind what is on the PATH. But then to decide which of those pyenv interpreters to use, you set interpreter_constraints
happy-kitchen-89482
09/30/2021, 3:42 AMhappy-kitchen-89482
09/30/2021, 3:42 AMhappy-kitchen-89482
09/30/2021, 3:43 AMripe-kitchen-64238
09/30/2021, 7:38 AMbased on your configured interpreter constraintsMy problem was as a result of not configuring it, and the behaviour of the undefined default not being what I expected.
ripe-kitchen-64238
09/30/2021, 7:42 AMhappy-kitchen-89482
09/30/2021, 5:00 PM