fresh-cat-90827
11/01/2021, 8:17 PM2.7.0
or 2.7.1
instead of 2.6.1
. It may be related to https://pantsbuild.slack.com/archives/C046T6T9U/p1634120386065100?thread_ts=1634114532.062500&cid=C046T6T9U.fresh-cat-90827
11/01/2021, 8:17 PM./pants package my-project::
(both on a MacOS and Linux device):
UndefinedEnvironmentName: 'platform_machine' does not exist in evaluation environment.
pid 30314 -> /Users/username/.cache/pants/named_caches/pex_root/venvs/1d2a3f1b3961efbfba4c4373717c72d09d116d95/6a77fa4c4cb26ace625186dd39a1df03b7dc2d73/pex --disable-pip-version-check --no-python-version-warning --exists-action a --use-feature 2020-resolver --isolated -q --cache-dir /Users/username/.cache/pants/named_caches/pex_root --log /private/var/folders/k0/3nssm8v15r5b08k1k1wyhs2r0000gp/T/process-executionr3ZLCK/.tmp/tmpPQBi1j/pip.log download --dest /private/var/folders/k0/3nssm8v15r5b08k1k1wyhs2r0000gp/T/process-executionr3ZLCK/.tmp/tmpcD5DZQ/linux_x86_64-cp-38-cp38 --platform manylinux2014_x86_64 --platform linux_x86_64 --implementation cp --python-version 38 --abi cp38 --only-binary :all: --constraint constraints.txt dataclasses==0.6 pandas>=1.0 requests>=2.22 --index-url <https://my-hosted-pypi/pypi/simple> --extra-index-url <https://pypi.python.org/simple> --retries 5 --timeout 15 exited with 2 and STDERR:
None
I have experimented removing some of the requirements, but the error keeps manifesting with other packages, this seems to be arbitrary (I wasn’t able to tie it to a particular PyPI package, and SQLAlchemy has been removed as well).
What information would one want to see to understand the problem better?fresh-cat-90827
11/01/2021, 9:05 PMpython2.7
in outputs of PEX before (it’s not Pants 2.7, right?):
stderr:
ERROR: Exception:
Traceback (most recent call last):
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_internal/cli/base_command.py", line 223, in _main
status = self.run(options, args)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_internal/cli/req_command.py", line 180, in wrapper
return func(self, options, args)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_internal/commands/download.py", line 131, in run
reqs, check_supported_wheels=True
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/resolver.py", line 122, in resolve
requirements, max_rounds=try_to_avoid_resolution_too_deep,
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/resolvelib/resolvers.py", line 453, in resolve
state = resolution.resolve(requirements, max_rounds=max_rounds)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/resolvelib/resolvers.py", line 347, in resolve
failure_causes = self._attempt_to_pin_criterion(name, criterion)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/resolvelib/resolvers.py", line 207, in _attempt_to_pin_criterion
criteria = self._get_criteria_to_update(candidate)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/resolvelib/resolvers.py", line 198, in _get_criteria_to_update
for r in self._p.get_dependencies(candidate):
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/provider.py", line 172, in get_dependencies
for r in candidate.iter_dependencies(with_requires)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_internal/resolution/resolvelib/candidates.py", line 247, in iter_dependencies
requires = self.dist.requires() if with_requires else ()
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 2736, in requires
dm = self._dep_map
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 3023, in _dep_map
self.__dep_map = self._compute_dependencies()
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 3040, in _compute_dependencies
common = frozenset(reqs_for_extra(None))
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/pkg_resources/__init__.py", line 3037, in reqs_for_extra
if not req.marker or req.marker.evaluate({'extra': extra}):
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/packaging/markers.py", line 328, in evaluate
return _evaluate_markers(self._markers, current_environment)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/packaging/markers.py", line 244, in _evaluate_markers
lhs_value = _get_env(environment, lhs.value)
File "/Users/username/.cache/pants/named_caches/pex_root/venvs/short/a09ac147/lib/python2.7/site-packages/pip/_vendor/packaging/markers.py", line 225, in _get_env
"{0!r} does not exist in evaluation environment.".format(name)
UndefinedEnvironmentName: 'platform_machine' does not exist in evaluation environment.
...
enough-analyst-54434
11/02/2021, 12:25 AMplatform_machine
fix that went into Pex 2.1.52 here soon in 2.7.2rc0 and 2.8.0rc2: https://github.com/pantsbuild/pex/releases/tag/v2.1.52fresh-cat-90827
11/02/2021, 7:30 AMenough-analyst-54434
11/04/2021, 2:37 AMfresh-cat-90827
11/04/2021, 7:43 AMfresh-cat-90827
11/16/2021, 8:12 PMplatform_machine
error in 2.8.0rc5
! Thanks a ton for fixing this, @enough-analyst-54434