cool-easter-32542
09/06/2023, 1:47 AMrun_against_entire_lockfile=true.
With example-python add
diff --git a/pants.toml b/pants.toml
index 59bdbc4..254667f 100644
--- a/pants.toml
+++ b/pants.toml
@@ -30,6 +30,7 @@ root_patterns = ["/"]
# This can be a range, such as [">=3.8,<3.11"], but it's usually recommended to restrict
# to a single minor version.
interpreter_constraints = ["==3.9.*"]
+run_against_entire_lockfile = true
# Enable the "resolves" mechanism, which turns on lockfiles for user code. See
# <https://www.pantsbuild.org/docs/python-third-party-dependencies>. This also adds the
$ pants run helloworld/main.py
21:29:25.32 [INFO] Completed: Installing python-default.lock for the resolve `python-default`
21:29:27.90 [INFO] Completed: Building lib.pex from python-default.lock
Привет, pantsbuild!
$ rm -rf ~/.cache/pants/named_caches/
$ pants run helloworld/main.py
Traceback (most recent call last):
File "/home/ecsb/.cache/nce/2b6e146234a4ef2a8946081fc3fbfffe0765b80b690425a49ebe40b47c33445b/cpython-3.9.16+20230507-x86_64-unknown-linux-gnu-install_only.tar.gz/python/lib/python3.9/runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/home/ecsb/.cache/nce/2b6e146234a4ef2a8946081fc3fbfffe0765b80b690425a49ebe40b47c33445b/cpython-3.9.16+20230507-x86_64-unknown-linux-gnu-install_only.tar.gz/python/lib/python3.9/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/tmp/pants-sandbox-js4dCT/./lib.pex/__main__.py", line 92, in <module>
__venv_dir__ = __maybe_run_venv__(
File "/tmp/pants-sandbox-js4dCT/./lib.pex/__main__.py", line 37, in __maybe_run_venv__
venv_dir = venv_dir(
File "/tmp/pants-sandbox-js4dCT/lib.pex/.bootstrap/pex/variables.py", line 803, in venv_dir
File "/tmp/pants-sandbox-js4dCT/lib.pex/.bootstrap/pex/variables.py", line 801, in add_pex_path_items
File "/tmp/pants-sandbox-js4dCT/lib.pex/.bootstrap/pex/pex_info.py", line 82, in from_pex
FileNotFoundError: [Errno 2] No such file or directory: 'python-default_lockfile.pex/PEX-INFO'
Pants version
2.170
OS
Linux
pantsbuild/pants