6
pip install -r requirements.txt
does not populate requirements.txt
– it reads it as the source of names of packages to install. See https://pip.pypa.io/en/stable/user_guide/#requirements-files for further details.
To capture your current installed package list to a requirements.txt
, try pip freeze > requirements.txt
.
Source:stackexchange.com