Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[runtime env] Use less common filename for internal
requirements.txt
(
#34022) Previously using the runtime env {'pip': "-r requirements.txt"} would result in an internal requirements.txt being created (here the name is hardcoded internally) and the file consists of the line -r requirements.txt, which causes virtualenv to go into an infinite loop during the install: 6 File "/tmp/ray/session_2023-04-03_12-39-24_206005_116/runtime_resources/pip/1147d1df72ebac68c6efd1b56214e947e9992c1a/virtualenv/lib/python3.10/site-packages/pip/_internal/req/req_file.py", line 327, in parse 27 yield from self._parse_and_recurse(filename, constraint) 28 File "/tmp/ray/session_2023-04-03_12-39-24_206005_116/runtime_resources/pip/1147d1df72ebac68c6efd1b56214e947e9992c1a/virtualenv/lib/python3.10/site-packages/pip/_internal/req/req_file.py", line 356, in _parse_and_recurse 29 yield from self._parse_and_recurse(req_path, nested_constraint) 30 File "/tmp/ray/session_2023-04-03_12-39-24_206005_116/runtime_resources/pip/1147d1df72ebac68c6efd1b56214e947e9992c1a/virtualenv/lib/python3.10/site-packages/pip/_internal/req/req_file.py", line 356, in _parse_and_recurse 31 yield from self._parse_and_recurse(req_path, nested_constraint) 32 File "/tmp/ray/session_2023-04-03_12-39-24_206005_116/runtime_resources/pip/1147d1df72ebac68c6efd1b56214e947e9992c1a/virtualenv/lib/python3.10/site-packages/pip/_internal/req/req_file.py", line 356, in _parse_and_recurse 33 yield from self._parse_and_recurse(req_path, nested_constraint) Note that requirements.txt is a very common name for requirements files. This PR changes the internal name to ray_runtime_env_pip_requirements.txt which makes name collisions less likely.
- Loading branch information