great-river-11779
11/01/2023, 5:34 AMStep 3/10 : RUN PEX_TOOLS=1 /usr/local/bin/python3.11 /binary.pex venv --scope=deps --compile /bin/app
---> Running in e9df5526d509
Failed to find compatible interpreter on path /usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin.
Examined the following interpreters:
1.) /usr/local/bin/python3.11 CPython==3.11.6
No interpreter compatible with the requested constraints was found:
A distribution for aiohttp could not be resolved for /usr/local/bin/python3.11.
Found 1 distribution for aiohttp that do not apply:
1.) The wheel tags for aiohttp 3.9.0b0 are cp311-cp311-macosx_10_9_x86_64 which do not match the supported tags of /usr/local/bin/python3.11:
cp311-cp311-manylinux_2_36_aarch64
... 562 more ...
What would be the best way to get around this issue?enough-analyst-54434
11/01/2023, 5:41 AMgreat-river-11779
11/01/2023, 5:54 AMhappy-kitchen-89482
11/01/2023, 10:45 AMhappy-kitchen-89482
11/01/2023, 10:47 AMhappy-kitchen-89482
11/01/2023, 10:49 AMcomplete_platforms
, but this requires that all transitive third-party dependencies are available in binary wheel form, and this may not be the case for your deps, unless you build them yourself and put them in a pypi-like artifact repository for Pants to resolve from.curved-manchester-66006
11/01/2023, 2:21 PMyou build them yourself and put them in a pypi-like artifact repository for Pants to resolve from.FWIW We have a lot of mac users and more or less follow the guide in https://github.com/pantsbuild/pants/discussions/18756 with
complete_platforms
Concretely in pants.toml
we set
[python.resolves_to_only_binary]
default = [":all:"]
And have some pipeline with https://cibuildwheel.readthedocs.io/en/stable/ configured to build wheels for PyPI packages. This makes things smooth for mac user (and really with glibc versions Linux users eventually need this to) albeit at the cost of shifting some of the burden to a centralized "deal with annoying 3rdparty stuff" team.great-river-11779
11/01/2023, 6:45 PMenough-analyst-54434
11/01/2023, 8:09 PMenough-analyst-54434
11/01/2023, 9:46 PMgreat-river-11779
11/02/2023, 12:55 AMgreat-river-11779
11/02/2023, 2:11 AMgreat-river-11779
11/02/2023, 2:11 AMpython_requirements(name="requirements")
docker_environment(
name="linux",
image="python:3.11-slim",
fallback_environment="local"
)
local_environment(name="local")
__defaults__(all=dict(environment="linux"))