fedora-infra / mdapi

A simple and fast API for serving the metadata from the RPM repositories.
https://mdapi.fedoraproject.org/
GNU General Public License v3.0
8 stars 11 forks source link

Avoid skipping valid branches while indexing repos #302

Closed carlwgeorge closed 1 month ago

carlwgeorge commented 1 month ago

It looks like #296 introduced a subtle bug. Previously the list_branches function returned more branches than were needed (despite the clt_status param), so we needed to skip invalid branches. The skip condition accidentally always evaluated to true, so valid branches were being skipped too. With the switch to querying bodhi for current branches, we only get valid branches. That makes it so that the easiest fix is to just remove the skip condition.

gridhead commented 1 month ago

The PKGDB proxy turned out to be a static JSON file that was adjusted whenever new releases were branched out and hence passing the clt_status parameter to the https://admin.fedoraproject.org/pkgdb/api/collections location served no purpose. Removing the skip condition should broaden the criteria of branch selection from the stable section. While this was previously planned as a hotfix, it is now included in the sixth alpha of MDAPI v3.1.6.