#519 Traceback when more than one SRPM was found
Opened 2 years ago by frostyx. Modified 5 months ago

Originally reported for Fedora Review Service:
https://github.com/FrostyX/fedora-review-service/issues/47

Snippet from the fedora-review.log

05-11 08:30 root         INFO     Getting .spec and .srpm Urls from : Local files in /var/lib/copr-rpmbuild/results
05-11 08:30 root         DEBUG    ReviewError: 'More than one srpm found for: /var/lib/copr-rpmbuild/results/kfreestyle2d*.src.rpm'
Traceback (most recent call last):
  File "/usr/lib/python3.12/site-packages/FedoraReview/review_helper.py", line 236, in run
    self._do_run(outfile)
  File "/usr/lib/python3.12/site-packages/FedoraReview/review_helper.py", line 226, in _do_run
    self._do_report(outfile)
  File "/usr/lib/python3.12/site-packages/FedoraReview/review_helper.py", line 83, in _do_report
    if not self.bug.find_urls():
           ^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/FedoraReview/abstract_bug.py", line 202, in find_urls
    raise fre
  File "/usr/lib/python3.12/site-packages/FedoraReview/abstract_bug.py", line 194, in find_urls
    self.find_srpm_url()
  File "/usr/lib/python3.12/site-packages/FedoraReview/name_bug.py", line 58, in find_srpm_url
    raise self.BugError("More than one srpm found for: " + pattern)
FedoraReview.abstract_bug.AbstractBug.BugError: 'More than one srpm found for: /var/lib/copr-rpmbuild/results/kfreestyle2d*.src.rpm'
05-11 08:30 root         ERROR    ERROR: 'More than one srpm found for: /var/lib/copr-rpmbuild/results/kfreestyle2d*.src.rpm'

The error is (IMHO) expected but the traceback shouldn't be there.


The error is (IMHO) expected

Or maybe isn't? The Fedora Review Service ticket mentions using forge macros as a possible cause.

Attaching a specfile so that anyone can debug this:
kfreestyle2d.spec

yeah , I got the same problem with one spec with forge macros

WARNING Package stepmania-5.1.0~gitd55acb1-5.fc41 not built
when it was built stepmania-5.1.0~20250110gitd55acb1-5.fc42.src.rpm

running [1], we quickly see the bug , get_package_nvr return version without the date

[1]
fedora-review --url https://bugzilla.rpmfusion.org/show_bug.cgi?id=7146 -m fedora-41-x86_64-rpmfusion_free -c --no-build

with https://pagure.io/FedoraReview/pull-request/532

fedora-review -b 2279495 finish without any exception

Log in to comment on this ticket.

Metadata
Attachments 1
Attached 2 years ago View Comment
Related Pull Requests
  • #532 Last updated 2 months ago