Last Updated: February 25, 2016
· scott2b

PyPi packages as dependency requirements in

If you are creating a for your Python project, you might have a requires property, like:

requires = [ 'some-pypi-package' ]

Trouble is, requires is designed for Python module dependencies, not installation dependencies. And with the dashes in the PyPi package name, you get the very unhelpful error:

ValueError: expected parenthesized list

The fix is to use install_requires, which supports PyPi packages as dependencies:

install_requires = [ 'some-pypi-package' ]