Fedora Account System
Red Hat Associate
Red Hat Customer
Typical use of the new provisional %pyproject_patch_dependency macro requires an explicit, manual BuildRequires: python3-devel or at least BuildRequires: pyproject-rpm-macros so that the macro will be defined in the %prep section. See https://src.fedoraproject.org/rpms/bidscoin/pull-request/1#request_diff for an example. We’ve been moving in the direction of advising that people shouldn’t feel the need for this kind of manual BR when BuildSystem: pyproject or %pyproject_buildrequires are in use, but this might push things back in the opposite direction if %pyproject_patch_dependency sees wide adoption. I mentioned this on Matrix, and Miro Hrončok wrote, “Also, BuildRequires: python3-devel will not be good enough on EL,” which is a good point. He also wrote, “we should move %pyproject_patch_dependency to srpm macros. it's implementation is oneliner (ok, 4 lines).” It does look like some macros would also be need to be migrated to the srpm macros in order to figure out where to write the dependency override file, though: # This is a backward-compatible suffix used in all pyproject-rpm-macros directories # For the main Python it's empty, for all others it's "-3.X" %_pyproject_files_pkgversion %{expr:"%{python3_pkgversion}" != "3" ? "-%{python3_pkgversion}" : ""} # We prefix all created files with this value to make them unique # Ideally, we would put them into %%{buildsubdir}, but that value changes during the spec # The used value is similar to the one used to define the default %%buildroot %_pyproject_files_prefix %{name}-%{version}-%{release}.%{_arch}%{_pyproject_files_pkgversion} %_pyproject_dep_overrides %{_builddir}/%{_pyproject_files_prefix}-pyproject-dep-overrides %pyproject_patch_dependency() %{expand:\\\ %{!?1:%{error:%%pyproject_patch_dependency requires an argument}}\\\ %{?2:%{error:%%pyproject_patch_dependency accepts exactly one argument per call}}\\\ echo '%1' >> %{_pyproject_dep_overrides} } Does this make sense? And is there a reasonable alternative?
Even with more lines to move, I think it's OK. No Python files, no external dependency needs to be added to the SRPM package. The size of the file is still effectivelly 4K.
(In reply to Miro Hrončok from comment #1) > Even with more lines to move, I think it's OK. No Python files, no external > dependency needs to be added to the SRPM package. The size of the file is > still effectivelly 4K. Can we rely on macros from pyproject-srpm-macros (macros.aaa-pyproject-srpm) in pyproject-rpm-macros (macros.pyproject), or do the definitions need to be duplicated in both places? Considering that pyproject-rpm-macros does not depend on its pyproject-srpm-macros subpackage, only enforce a version constraint if it is installed Requires: (pyproject-srpm-macros = %{?epoch:%{epoch}:}%{version}-%{release} if pyproject-srpm-macros) it looks like the latter to me, but perhaps I am missing something.
(In reply to Ben Beasley from comment #0) > Typical use of the new provisional %pyproject_patch_metadata macro requires This was a typo for %pyproject_patch_dependency. I’ve corrected the bug title as well.
I think it's better to make that a real Requires rather than duplicating the definition. Effectively, it will be installed anyway, so no need to play the if dance.
https://src.fedoraproject.org/rpms/pyproject-rpm-macros/pull-request/579
FEDORA-2026-daceb87a93 (pyproject-rpm-macros-1.20.1-1.fc45) has been submitted as an update to Fedora 45. https://bodhi.fedoraproject.org/updates/FEDORA-2026-daceb87a93
FEDORA-2026-daceb87a93 (pyproject-rpm-macros-1.20.1-1.fc45) has been pushed to the Fedora 45 stable repository. If problem still persists, please make note of it in this bug report.
FEDORA-2026-051d1b3285 (pyproject-rpm-macros-1.20.1-1.fc43) has been submitted as an update to Fedora 43. https://bodhi.fedoraproject.org/updates/FEDORA-2026-051d1b3285
FEDORA-2026-c50219cb79 (pyproject-rpm-macros-1.20.1-1.fc44) has been submitted as an update to Fedora 44. https://bodhi.fedoraproject.org/updates/FEDORA-2026-c50219cb79
FEDORA-2026-b365003f50 (pyproject-rpm-macros-1.20.1-1.fc42) has been submitted as an update to Fedora 42. https://bodhi.fedoraproject.org/updates/FEDORA-2026-b365003f50
FEDORA-2026-051d1b3285 has been pushed to the Fedora 43 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-051d1b3285` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-051d1b3285 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-b365003f50 has been pushed to the Fedora 42 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-b365003f50` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-b365003f50 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-c50219cb79 has been pushed to the Fedora 44 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-c50219cb79` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-c50219cb79 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-f83c29a149 has been pushed to the Fedora 43 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-f83c29a149` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-f83c29a149 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-0a10b4d589 has been pushed to the Fedora 42 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-0a10b4d589` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-0a10b4d589 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-f83c29a149 (pyproject-rpm-macros-1.21.0-1.fc43) has been pushed to the Fedora 43 stable repository. If problem still persists, please make note of it in this bug report.
FEDORA-2026-df48a8f3e0 (pyproject-rpm-macros-1.21.0-1.fc44) has been pushed to the Fedora 44 stable repository. If problem still persists, please make note of it in this bug report.
FEDORA-2026-aefbbc6b17 has been pushed to the Fedora 42 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-aefbbc6b17` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-aefbbc6b17 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2026-aefbbc6b17 (pyproject-rpm-macros-1.22.1-1.fc42) has been pushed to the Fedora 42 stable repository. If problem still persists, please make note of it in this bug report.