I've this WIP branch, so putting here for discussion and refinement.
I suggest dropping the YUM code here entirely, as librepo (with Python bindings) is available all the way back to EL6.
This logic implies we prefer YUM. If we want to keep YUM code at all (which I think we shouldn't), we should flip this logic so it tries librepo first, and only if that fails, try yum.
librepo
yum
1 new commit added
fix runroot test
use librepo instead of yum where possible
You're right. I've deleted 'if yum_available' branch in that point. Nevertheless, dist-repo is still yum-dependent.
make librepo optional
fix typo
distrepo via dnf
Rather than writing a config file and going that route, you can set these options through Python directly with dnf.conf objects. You can see an example of this here: https://pagure.io/releng/blob/master/f/scripts/spam-o-matic
dnf.conf
I don't think you mean to use the dnf API for the yum implementation here?
rebased onto 1652442e6fef7c0ca855185aafa46a97791ad27a
This is more DNF API usage in the YUM functions...
Just a reminder YUM-3 is going away soon: https://pagure.io/fesco/issue/2064
rebased onto fc77341e41893f96221cca9a6668c99553854aa2
rebased onto cffff91b2f64b28c3a3a97c32a08af13007a878a
We shouldn't be using DNF APIs in the YUM function...
I concur. Perhaps this was a merge/rebase error along the way.
This change reverts that part, leaving it in line with the old yum code (apart from using koji.arch and with open().
koji.arch
with open()
https://github.com/mikem23/koji-playground/commits/pagure/pr/1117
@mikem The diff I see here looks good to me: https://github.com/mikem23/koji-playground/compare/pagure/pr/1117
At this point, I think it's good to merge.
2 new commits added
Fix unit tests
drop dnf from yum handler
:thumbsup:
@tkopecek This needs rebasing. It might be better to also clean up the commit history so that the changes are more logically separated and make sense.
Merging this with a manual rebase and two small fixes
Commit 4ad8a0ec fixes this pull-request
Pull-Request has been merged by mikem
@mikem Commit 96d3ee5f was somehow missed during merge.
I've this WIP branch, so putting here for discussion and refinement.