π οΈ TroubleshootingΒΆ
pip install fails with FileNotFoundErrorΒΆ
When using a project that uses local_dependencies: [../not/current/dir] in the requirements.yaml file:
local_dependencies:
# File in a different directory than the pyproject.toml file
- ../common-requirements.yaml
You might get an error like this when using a pip version older than 22.0:
$ pip install /path/to/your/project/using/unidep
...
File "/usr/lib/python3.8/pathlib.py", line 1222, in open
return io.open(self, mode, buffering, encoding, errors, newline,
File "/usr/lib/python3.8/pathlib.py", line 1078, in _opener
return self._accessor.open(self, flags, mode)
FileNotFoundError: [Errno 2] No such file or directory: '/tmp/common-requirements.yaml'
The solution is to upgrade pip to version 22.0 or newer:
pip install --upgrade pip