[New-bugs-announce] [issue33388] Support PEP 566 metadata in dist.py
report at bugs.python.org
Sun Apr 29 14:51:59 EDT 2018
New submission from Robert Bricheno <python at ambrosia.org.uk>:
PEP 566 added the metadata fields 'Description-Content-Type' and 'Provides-Extra':
Currently dist.py in CPython distutils will warn if they are set, e.g.:
`dist.py:261: UserWarning: Unknown distribution option: 'long_description_content_type'`
The warnings are emitted when using setuptools to build a wheel (say) if either of the fields are defined. They seem spurious (I can still build wheels even if I see this warning...). But they looked a bit scary to me as a new user.
There are a few possible ways to fix this. Long-term they should be fully supported by distutils I suppose. In the short term, there are a few different ways to make these warnings go away.
My preferred option would be to simply declare fields for these variables in dist.py (as per setuptools). By declaring these variables, the warnings are no longer displayed. long_description_content_type, at least, is being used in the wild since:
pypa/sampleproject at 5be0970
nosy: dstufft, eric.araujo, rbricheno
title: Support PEP 566 metadata in dist.py
versions: Python 3.8
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce