DNF autocompletion is too slow

I did a fresh install of Fedora 36 on my laptop and what bothers me is that dnf’s autocompletion is just really slow, forcing me to type whole names of options/packages instead of hitting tab.

Is there any workaround for this? I am using Ubuntu 20.04 on my desktop and the autocompletion of apt is a lot faster. It should be noted that other than dnf, autocomplete works flawlessly on Fedora 36.

Which shell do you use and what is the output of:

dnf --version

I am using the bash shell and the version of dnf is 4.13.0.

Hello @asarikas and welcome to the community.
Yes, dnf autocompletion is slow. Personally I don’t care, but I read somewhere that using zsh instead of bash is more responsive.
In addition dnf 5 is on the work, and hopefully this new release will be faster.

1 Like

Ok I will wait for dnf 5 then. What is the reason that causes this problem?

Do you have sqlite installed?

dnf 4.13.0, includes bash-completion: use sqlite cache when available (BZ: 1815895) by rjarry · Pull Request #1817 · rpm-software-management/dnf · GitHub which should have made it comparable.

zsh was noticeably faster because it queried the sql cache first.