If a spec file sets the release field to the %autorelease macro, don't even attempt to check if the build exists already, as using the macro ensures that a new release number is used.
Fixes: https://pagure.io/fedora-infra/rpmautospec/issue/109
Signed-off-by: Nils Philippsen nils@redhat.com
Which package provides rpmautospec module?
rpmautospec
It's in the python3-rpmautospec package we work on as part of the corresponding F35 Change: https://fedoraproject.org/wiki/Changes/rpmautospec
python3-rpmautospec
Sorry I didn't provide that context up-front.
Note, we have an open PR in rpmautospec (fedora-infra/rpmautospec#155) to expose a function doing the checksto 3rd parties, and we'll rework this PR to use it. Don't merge yet, thanks!
rebased onto fee44150e64a2088fb1b1cecc583fc7ee2343403
rebased onto 0c9233876b0a076dc7616f7b5e4849011a5da1f1
2 new commits added
Skip NVR check if the %autorelease macro is used
Don't access unset variable
The latest push uses the exposed function and adapts one test to make it aware of the new calls to load_nameverrel() -> Popen() introduced by the change. Please review, thanks!
@lsedlar is there anything missing from this PR before you or some other fedpkg/rpkg maintainer can do a review?
I like the design of the change. I have checked the code without locating an issue. It would work in RHEL where the new dependency (rpmautospec) is missing.
rebased onto 215d809233446c29646ca34dd860cb59b07642db
Pull-Request has been merged by onosek
If a spec file sets the release field to the %autorelease macro, don't
even attempt to check if the build exists already, as using the macro
ensures that a new release number is used.
Fixes: https://pagure.io/fedora-infra/rpmautospec/issue/109
Signed-off-by: Nils Philippsen nils@redhat.com