[Distutils] How to declare optional dependencies?

Brett Cannon brett at python.org
Fri Feb 5 13:52:26 EST 2016

Maybe I'm totally overlooking something or misreading the docs, but I can't
find a way to say in a requirements.txt file that a dependency is optional
and its failure to install is okay. E.g., aiohttp supports using cchardet
as an accelerator of chardet (
http://aiohttp.readthedocs.org/en/stable/#library-installation). I would
like to be able to specify in my requirements.txt that I would like
cchardet to be installed if possible, but it not being available -- which
it might be as it doesn't have any Python 3.5 wheels ATM -- is fine and not
the end of the world.

I'm also happy to push a patch upstream if there is something aiohttp
should be setting in their setup.py instead (I thought maybe extras, but
those seem to be hard requirements as well).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/distutils-sig/attachments/20160205/c1b439af/attachment.html>

More information about the Distutils-SIG mailing list