[Distutils] How to specify dependencies in Python

Nick Coghlan ncoghlan at gmail.com
Thu Jan 12 07:43:19 EST 2017


On 12 January 2017 at 22:04, Thomas Güttler
<guettliml at thomas-guettler.de> wrote:
> I came across a python library which has docs, which start like this:
>
> {{{
>
>  Quickstart
>
>  Include foolib in your requirements.txt file.
>
> }}}
>
> AFAIK dependencies should be specified via `install_requires` in `setup.py`.

Applications and services don't necessarily have a setup.py file -
setup.py is more for pip-installable libraries and frameworks (see
https://caremad.io/posts/2013/07/setup-vs-requirement/ for more on
that topic).

Since the section is titled "Quickstart", it seems reasonable to gloss
over the fact that there are options other than requirements.txt,
especially as folks that have already gone to the effort of learning
how to make their software pip-installable are also likely to have
worked out how that impacts where you specify your dependencies.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia


More information about the Distutils-SIG mailing list