Skip to content

Explore alternatives to setuptools #2530

@vytas7

Description

@vytas7

We have been hit by multiple problems related to using Setuptools as our PEP 517 backend, the latest one being the SPDX licence expression saga (see #2451, pypa/setuptools#4903, PEP 639).

Although the migration issues seem to partially stem from the recommendations in PEP 639 itself, we are more hit by a very harsh deprecation timeline from Setuptools. The minimum version that supports the new shiny expressions is 77.0.3, and the old way will be dropped mid-Feb 2026. 77.0.3 was released mid-March, so the whole deprecation window is just 11 months (!).

@bwoodsend mentioned on Python discussions that other PEP 517 backends like Hatchling were more permissive wrt unknown/old fields, effectively affording easier transition.
I have some experience with PDM, and I know that its plugins can even dynamically rewrite pyproject.toml under the process (probably even violating the spirit of PEP 517) of building targets.

Unfortunately, it seems that Cython is still heavily integrated with Setuptools, as even its cythonize command seems to call Setuptools under the hood (at least I'm seeing the familiar warnings).
Cython plugins for other package managers seem to create a minimal pseudo-package under the hood, and still build it with Setuptools. Such a roundabout way may introduce more trouble than good for downstream packaging.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions