[Distutils] Static metadata using setup.cfg

Tarek Ziadé ziade.tarek at gmail.com
Fri Sep 11 16:23:53 CEST 2009


On Fri, Sep 11, 2009 at 4:03 PM, Chris Withers <chris at simplistix.co.uk> wrote:
> Tarek Ziadé wrote:
>>
>> The practice in the community is to create the long_description field
>> using a separate reStructuredText file
>> and reaching it in setup.py like this for example:
>>
>> long_description = open('README.txt').read()
>>
>> Having a callable that provides this feature in the template allows
>> writing:
>>
>> """
>> [setup.cfg]
>>
>> long_description: {$ long_description('README.txt') $}
>> """
>
> Exactly, so why have this complicated templating nonesense rather than just
> having:
>
> [setup.cfg]
>
> long_description_path: README.txt
>
>
>> long_description_path can't be added in the final PKG-INFO because
>> we want a self-contained metadata static file that doesn't require an
>> extra resource (like an external file)
>
> Why this requirement?

Where this external file would it be located ?
There's just *one* metadata file that contains everything.

People are injecting files in it when they build the distribution and sometime
don't even ship it with the archive.

If you put a path you can't be sure that the file behind this path
will be available
on the system that reads setup.cfg.

And it would break the idea that we can have static metadata without
further processing the package (by installing it or opening its files)


More information about the Distutils-SIG mailing list