Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"FileNotFoundError: [Errno 2] No such file or directory" in pex #11091

Closed
asherf opened this issue Nov 2, 2020 · 2 comments
Closed

"FileNotFoundError: [Errno 2] No such file or directory" in pex #11091

asherf opened this issue Nov 2, 2020 · 2 comments

Comments

@asherf
Copy link
Member

asherf commented Nov 2, 2020

Engine traceback:
  in select
  in pants.core.goals.typecheck.typecheck
  in pants.backend.python.typecheck.mypy.rules.mypy_typecheck
  in pants.backend.python.typecheck.mypy.rules.mypy_typecheck_partition
  in pants.backend.python.util_rules.pex.create_pex
  in pants.backend.python.util_rules.pex.find_interpreter (CPython<3.9,<4,>=3.7,>=3.8)
  in pants.engine.process.fallible_to_exec_result_or_raise
Traceback (most recent call last):
  File "/home/toolchain/.*****/pants/setup/bootstrap-Linux-x86_64/2.1.0.dev0_py38/lib/python3.8/site-packages/pants/engine/process.py", line 241, in fallible_to_exec_result_or_raise
    raise ProcessExecutionFailure(
pants.engine.process.ProcessExecutionFailure: Process 'Find interpreter for constraints: CPython<3.9,<4,>=3.7,>=3.8' failed with exit code 1.
stdout:

stderr:
Traceback (most recent call last):
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.bootstrap/pex/pex.py", line 443, in execute
    exit_code = self._wrap_coverage(self._wrap_profiling, self._execute)
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.bootstrap/pex/pex.py", line 375, in _wrap_coverage
    return runner(*args)
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.bootstrap/pex/pex.py", line 406, in _wrap_profiling
    return runner(*args)
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.bootstrap/pex/pex.py", line 494, in _execute
    return self.execute_entry(self._pex_info.entry_point)
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.bootstrap/pex/pex.py", line 596, in execute_entry
    return runner(entry_point)
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.bootstrap/pex/pex.py", line 612, in execute_pkg_resources
    return runner()
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.deps/pex-2.1.20-py2.py3-none-any.whl/pex/bin/pex.py", line 994, in main
    pex_builder.freeze(bytecode_compile=options.compile)
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.deps/pex-2.1.20-py2.py3-none-any.whl/pex/pex_builder.py", line 505, in freeze
    self._prepare_bootstrap()
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.deps/pex-2.1.20-py2.py3-none-any.whl/pex/pex_builder.py", line 463, in _prepare_bootstrap
    vendor.vendor_runtime(
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.deps/pex-2.1.20-py2.py3-none-any.whl/pex/vendor/__init__.py", line 166, in vendor_runtime
    chroot.copy(src, dest, label)
  File "/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.deps/pex-2.1.20-py2.py3-none-any.whl/pex/common.py", line 512, in copy
    shutil.copy(src, os.path.join(self.chroot, dst))
  File "/usr/local/lib/python3.8/shutil.py", line 415, in copy
    copyfile(src, dst, follow_symlinks=follow_symlinks)
  File "/usr/local/lib/python3.8/shutil.py", line 261, in copyfile
    with open(src, 'rb') as fsrc, open(dst, 'wb') as fdst:
FileNotFoundError: [Errno 2] No such file or directory: '/home/toolchain/.*****/pants/named_*****s/pex_root/unzipped_pexes/d7ed954089c1232b9c1a001845a5a384366d3669/.deps/pex-2.1.20-py2.py3-none-any.whl/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/__py*****__/pyparsing.cpython-37.pyc.140210639452464'


@stuhood
Copy link
Member

stuhood commented Nov 2, 2020

It sounded like @jsirois thought that this was a pex issue in the same vein as pex-tool/pex#1080.

@jsirois
Copy link
Contributor

jsirois commented Nov 6, 2020

Closing this in favor of pex-tool/pex#1098 over in Pex. Thanks for the report @asherf.

@jsirois jsirois closed this as completed Nov 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants