[Distutils] PEP: Build system abstraction for pip/conda etc

Paul Moore p.f.moore at gmail.com
Wed Feb 10 08:43:06 EST 2016


On 10 February 2016 at 13:23, Nick Coghlan <ncoghlan at gmail.com> wrote:
> On 10 February 2016 at 20:53, Paul Moore <p.f.moore at gmail.com> wrote:
>> We don't have to solve the whole "sdist 2.0" issue right now. Simply
>> saying that in order to publish pypa.json-based source trees you need
>> to zip up the source directory, name the file "project-version.zip"
>> and upload to PyPI, would be sufficient as a short-term answer
>> (assuming that this *would* be a viable "source file" that pip could
>> use - and I must be clear that I *haven't checked this*!!!) until
>> something like Nathaniel's source distribution proposal, or a
>> full-blown sdist-2.0 spec, is available. We'd need to support whatever
>> stopgap proposal we recommend for backward compatibility in those new
>> proposals, but that's a necessary cost of not wanting to delay the
>> current PEP on those other ones.
>
> One of the reasons I went ahead and created the specifications page at
> https://packaging.python.org/en/latest/specifications/ was to let us
> tweak interoperability requirements as needed, without wasting
> people's time with excessive PEP wrangling by requiring a separate PEP
> for each interface affected by a proposal.
>
> In this case, the build system abstraction PEP should propose some
> additional text for
> https://packaging.python.org/en/latest/specifications/#source-distribution-format
> defining how to publish source archives containing a pypa.json file
> and the setup.py shim. At that point, it will effectively become the
> spec for sdist 1.0, since that's never previously been officially
> defined.
>
> The key difference from setuptools is that the setup.py shim will be a
> standard one that flit (and other source archive creation tools) can
> inject when building the sdist, rather than needing to be a custom
> file stored in each project's source repository.

Neat! That sounds like a sensible approach, and if the build system
abstraction PEP adds this, then that addresses my remaining
objections.

Paul


More information about the Distutils-SIG mailing list