bumpy-fireman-59234
12/08/2023, 2:52 PMsearch_path = ["<ASDF>"]
in pants.toml. I have python 3.11.6 and 3.12.0 installed with asdf, but set the version locally in the directory of the pants workspace to be 3.11.6.
• In my pants workspace, I have a venv that uses 3.11.6, and I activated it.
• But when I do a pants run
it some how latches on to 3.12.0 and gave me the following error:
09:49:00.10 [ERROR] 1 Exception encountered:
Engine traceback:
in `run` goal
ProcessExecutionFailure: Process 'Find interpreter for constraints: CPython<=3.12,>=3.11' failed with exit code 102.
stdout:
stderr:
Could not find a compatible interpreter.
Interpreters were found but they all appear to be broken:
1.) /Users/joe/.asdf/installs/python/3.12.0/bin/python3.12:
Traceback (most recent call last):
File "<string>", line 4, in <module>
File "/Users/joe/.cache/pants/named_caches/pex_root/isolated/3754108aac57ec0c996f3414782585924aee601c/pex/atomic_directory.py", line 23, in <module>
from pex.third_party import attr
ImportError: cannot import name 'attr' from 'pex.third_party' (/Users/joe/.cache/pants/named_caches/pex_root/isolated/3754108aac57ec0c996f3414782585924aee601c/pex/third_party/__init__.py)
(See <https://github.com/pantsbuild/pex/issues/1027> for a list of known breaks and workarounds.)
late-advantage-75311
12/08/2023, 3:20 PMlate-advantage-75311
12/08/2023, 3:22 PMlate-advantage-75311
12/08/2023, 3:32 PMlate-advantage-75311
12/08/2023, 3:44 PMbumpy-fireman-59234
12/08/2023, 4:24 PM[GLOBAL]
pants_version = "2.17.0"
backend_packages = [
"pants.backend.build_files.fmt.black",
"pants.backend.python",
"pants.backend.python.lint.autoflake",
"pants.backend.python.lint.black",
"pants.backend.python.lint.flake8",
"pants.backend.python.lint.docformatter",
"pants.backend.python.lint.isort",
"pants.backend.python.typecheck.mypy",
]
[source]
root_patterns = ["/"]
[python]
interpreter_constraints = [">=3.11,<=3.12"]
enable_resolves = true
default_resolve = "reqs"
[python.resolves]
reqs = "3rdparty/python/python-default.lock"
[python-bootstrap]
search_path = ["<ASDF>"]
[python-infer]
string_imports = true
use_rust_parser = true
[pytest]
install_from_resolve = "reqs"
[mypy]
install_from_resolve = "reqs"
interpreter_constraints = [">=3.10,<=3.12"]
bumpy-fireman-59234
12/08/2023, 4:25 PMbumpy-fireman-59234
12/08/2023, 4:26 PMbroad-processor-92400
12/08/2023, 8:43 PM<=
, do you maybe mean <3.12
to restrict to only 3.11.x
versions?bumpy-fireman-59234
12/08/2023, 9:03 PM