Hacker News new | past | comments | ask | show | jobs | submit login

Pip supports constraints files. https://pip.pypa.io/en/stable/user_guide/#constraints-files :

> Constraints files are requirements files that only control which version of a requirement is installed, not whether it is installed or not. Their syntax and contents is nearly identical to Requirements Files. There is one key difference: Including a package in a constraints file does not trigger installation of the package.

> Use a constraints file like so:

  python -m pip install -c constraints.txt



What does that command do? Does it install dependencies, or simply verify the versions of the installed dependencies?


It just gives you an error:

  ERROR: You must give at least one requirement to install (see "pip help install")
So it seems like a strange choice of usage example. You have to provide both requirements and constraints for it to do anything useful (applying the version constraints to the requirements and their dependencies).




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: