The python-ruamel-yaml rpms
- Related: rhbz#2323169
The problem this fixes is a bit complex.
It goes like this:
1. %pyproject_buildrequires runs for the first time.
There is no pyproject.toml, only setup.py, so a dependency on setuptools is generated.
A build dependency on wheel is not generated (as it is not needed on Fedora 42+).
2. %pyproject_buildrequires runs again.
There is no pyproject.toml, only setup.py, so it is used.
A build dependency on wheel is still not generated.
A build dependency on ruamel-yaml-clib is generated when building without bootstrap,
as it is a runtime dependency.
Here it comes: setup.py code creates a pyproject.toml file (with a dependency on wheel) 😱
3a. Without bootstrap, dnf installs ruamel-yaml-clib and %%pyproject_buildrequires runs once more.
It uses pyproject.toml (which now exists).
A build dependency on wheel is now generated and %pyproject_buildrequires runs once more,
dnf install wheel.
3b. With bootstrap, this step is skipped as there was no new dependency (on ruamel-yaml-clib) to trigger it.
4. The final (verification) %pyproject_buildrequires round uses pyproject.toml (which now exists).
Without bootstrap, all is fine, no new dependency is generated.
With bootstrap, the wheel dependency is generated for the first time,
but at this point, it fails rpmbuild (because missing dependencies now fail the build).
We see errors like this as a result:
error: Failed build dependencies:
python3dist(wheel) is needed by python-ruamel-yaml-0.18.6-2.fc42~bootstrap.noarch
Considering the wheel dependency is entirely unneeded I proposed removal for upstream.
An alternative solution is to rm -f pyproject.toml
before calling %pyproject_buildrequires in %generate_buildrequires.
But if upstream switches to a proper pyproject.toml, we might not notice that.
|
||
|---|---|---|
| .gitignore | ||
| 9.patch | ||
| 10.patch | ||
| changelog | ||
| python-ruamel-yaml.spec | ||
| sources | ||