When the upstream project requires: gast ~= 0.4.0 The runtime dependency generator converts it to: (python3.Xdist(gast) >= 0.4 with python3.Xdist(gast) < 0.5) But the %pyproject_buildrequires (pyproject-rpm-macros <= 0-41) converts it to: (python3dist(gast) >= 0.4 with python3dist(gast) < 1) The first seem to be behave like upstream. This may lead to incomplete run of %pyproject_buildrequires when gast 0.5 (or 0.6, 0.7...) is installed because requirements.check() will end the script (Python dependencies unsatisfied) but there will no more packages to install (RPM dependencies satisfied). This seem to be used by stripping the leading zeros (via canonicalize_version()) before sending the requirement to convert() and hence actually processing ~= 0.4 instead of ~= 0.4.0 which has a different meaning.
https://src.fedoraproject.org/rpms/pyproject-rpm-macros/pull-request/172