#273 Won't build in Koji with Epoch bump
Closed: Fixed 2 months ago by nphilipp. Opened 12 months ago by atim.

When bumping Epoch for package with rpmautospec Koji won't build even with forcing --skip-nvr-check:

❯ fedpkg build --skip-nvr-check

Could not execute build: Package python-pykeepass-4.0.3-1.fc38 has already been built
Note: You can skip this check with --skip-nvr-check. See help for more info.

Metadata Update from @nphilipp:
- Issue assigned to nphilipp

11 months ago

This bug is actually in the rpmautospec integration in fedpkg/rpkg (which I contributed there 😊):

         # See if this build has been done.  Does not check builds within
        # a chain, or if the %autorelease macro is used.
        if (nvr_check or self.uses_autorelease) and not scratch and not url.endswith('.src.rpm'):

The conditional clearly doesn’t implement what the comment above says. I'll submit a PR with rpkg.

NB: as I understand it, the only way Epoch contributes to your issue is that fedpkg/rpkg only checks if the same N-V-R already exists as a build in koji.

NB^2: You shouldn’t bump epoch to address incompatibilities introduced in a minor release, only if the package otherwise can’t be upgraded, see https://docs.fedoraproject.org/en-US/packaging-guidelines/#_use_of_epochs

I recommend removing the Epoch from the spec file (there doesn’t seem to be a built package with it yet), even though this will throw off the rpmautospec release counting algorithm. You can work around that by using %autorelease -b 2 (which starts counting releases from 2) and reverting that on the next version bump.

I've filed the pull request which should fix the issue as rpkg#640.

Metadata Update from @nphilipp:
- Issue tagged with: 3rd party, Bug

11 months ago

This has long since been merged.

Metadata Update from @nphilipp:
- Issue close_status updated to: Fixed
- Issue status updated to: Closed (was: Open)

2 months ago

Login to comment on this ticket.