juhp / koji-tool

Koji buildsystem CLI tool to query tasks, install build rpms, and check buildlog sizes
https://hackage.haskell.org/package/koji-tool
Other
11 stars 0 forks source link

Prefer dnf-3 instead of dnf-5 being the default package manager #5

Closed rivenirvana closed 1 year ago

rivenirvana commented 1 year ago

With koji-tool v1.1 and commit bdd3265 specifically, the WIP dnf-5 is now identified and preferred over dnf-3 if it is installed in the system as the package manager to be used.

However, I'd like to propose the opposite instead for now and prefer dnf-3 in the meantime, for the following reasons:

juhp commented 1 year ago

Hi, thanks for the report. Sorry for the disruption.

At least once dnf5 is no longer installed by default it should fix the issue for most general users. For now you can use --dnf3 to avoid dnf5 if it is installed, but you might be right (this news took me a little by surprise), so I could perhaps change to defaulting to dnf-3. Though I rather like the speed of dnf5 and it mostly works well for me actually now, with a few wrinkles, so I feel some people may want to install dnf5 and continue to use it as their "daily driver": for such users preferring dnf5 makes sense though IMHO - people who only want to test dnf5 should probably do so in a container/toolbox or vm, or other test environment.

Otherwise a config option could be in order - until now I have largely avoided static config in most of my tools.

juhp commented 1 year ago

(For your 2nd bullet, why not just use rpm -q (rpmquery) to check installed packages, I think it is also faster)

Note that dnf5 is only chosen if it is installed (at least that is the intention) - if that is not the case then it is a bug. :-)

juhp commented 1 year ago

One more idea: dunno if there is some way to detect if dnf5 is in active use: eg update-to-date cache etc. That could be used a criteria for choosing dnf5.

rivenirvana commented 1 year ago

Thanks for the quick response. After thinking about it a bit more and considering your replies, I have decided to retract my proposal and conclude that this as a non-issue personally. You are right in that:

Besides that, koji-tool only uses a small subset of features from dnf5 that already works well and could be considered feature complete or having feature parity with dnf3. Thus, I am marking this as a non-issue, and will be deferring to you for any decisions on improvements/changes in the future. Thanks again for this awesome tool!

juhp commented 1 year ago

Okay, thank you - glad you like koji-tool :-)

Anyway I am still considering your suggestion - let's see how dnf5 progress settles, after F39 branching etc.