PEP517
PEP517
Posted May 23, 2025 1:48 UTC (Fri) by sam_c (subscriber, #139836)In reply to: PEP517 by geofft
Parent article: Recent disruptive changes from Setuptools
There's a lot of software that used `setup.py` as an entrypoint and relied on it being able to install to arbitrary locations on disk, often using it only because the software was written in Python and they felt it was natural that the build system also be in Python, despite it not needing to be.
It would also often (as the article covers) handle the testsuite but other administrative tasks, as well as "more elaborate" installation.
> The reason setup.py was able to do this is that it was just an ordinary Python script ...
Precisely.
> Is there a path forward where your setup.py script does not use setuptools (which is a Python-packaging-specific tool) but uses generic Python functionality like open("/lib/...", "w")?
Sure, that can be done - but if the software is installed via a wheel, that's not going to work, because there's no way to map extra data file locations in the wheel to real locations on the system. And none of the authors of these pieces of software relying on this functionality working ever seem to be aware of the problem.
i.e. All of it is solvable, it's just that it's a lot of work across a lot of different projects, and I don't think many of them are aware of the need to even do it. The software relying on this generally doesn't want to be installed as a wheel (it's usually "written in Python, not a library that should be imported"), they've just been piggybacking on setuptools and the setup.py entrypoint for years.
