Cannot create repository version since there are newly added packages with the same name

Problem:
Hello,
i am getting that warning and can not sync a deb repo:
“Cannot create repository version since there are newly added packages with the same name, version, and architecture, but a different checksum. If the log level is DEBUG, you can find a list of affected packages in the Pulp log.”

Expected outcome:

Foreman and Proxy versions:

  • foreman-3.10.0-1.el8.noarch
    katello-4.12.0-1.el8.noarch

Foreman and Proxy plugin versions:

Distribution and version:
RHEL 8.8
Other relevant data:

What repo are you syncing (what are the sync options)?

The error means exactly what it says. The upstream repo you are syncing contains duplicate packages that should not exist within a single APT repo.

It is possible to find the duplicates and open an issue with the upstream repository maintainers.

It is also sometimes possible to work around this issue by restricting the sync to individual components (assuming the colliding duplicate packages are in different components of the upstream repository).

More background: The reason APT clients do not trip up on the inconsistent upstream repository is that they simply choose one of the duplicate packages at random at install time. But Katello/pulp_deb is syncing the entire upstream repository at once and has no principled way of choosing between the colliding duplicate packages. Hence the error.

I am syncing:
http://apt.puppetlabs.com/
Release: jammy

Release focal has no problem only jammy?

I am looking at the Release file for jammy, and see the following list of components:

Components: puppet puppet5 puppet6 puppet6-release puppet7 puppet8 puppet-release puppet-tools 

You can try syncing only a subset of these components (for example if you don’t need multiple puppet versions in a single repo). If the colliding packages are in different components this will allow you to sync.

I don’t have time to investigate right away where exactly the collisions are. I may get around to it at some point (in which case I can tell you whether splitting up specific components will help).