Bug 1702854

Summary: Tab completion attempts with dnf cause terminal to hang.
Product: [Fedora] Fedora Reporter: Lucious <malucious81>
Component: dnfAssignee: Marek Blaha <mblaha>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: high    
Version: 30CC: dmach, jmracek, jrohel, mblaha, mhatina, packaging-team-maint, pkratoch, rpm-software-management, vmukhame
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: dnf-4.2.7-2.fc30 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-07-30 01:14:43 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Lucious 2019-04-25 01:19:01 UTC
Description of problem:

If you attempt to 'dnf install /path/to/rpm" or "dnf install partial-program-name" the terminal session will hang, as soon as, you press TAB requiring a Ctrl-C to break the process. 

My guess is dnf is attempting to search the repos for tab completion but it never finishes. I tried this on fedora 29 Workstation, it still hangs but briefly, then proceeds to finish tab completing the rpm name. Or it will make a guess from the repos.

Version-Release number of selected component (if applicable):

dnf: 4.2.2
Fedora 30 Workstation Beta


How reproducible:

Happens every time.


Steps to Reproduce:
1. Download an rpm.
2. Attempt to install the rpm using dnf by tab-completing the name.

or

Htop example.
1. Type "sudo dnf install hto"; Press TAB



Actual results:

The tab-complete does not resolve a name. CPU spins up but nothing happens

Expected results:

I expect the rpm name or program name to complete.


Additional info:

I know it's not as common to work with individual rpms, but brother print/scan drivers require them. Also, if someone is packaging an application for fedora and wants to test install with dnf. 

rpm -i package.rpm 

Still works fine.

Comment 1 Marek Blaha 2019-04-30 08:49:33 UTC
PR https://github.com/rpm-software-management/dnf/pull/1390 fixes the hang.

Comment 2 Fedora Update System 2019-07-04 13:50:19 UTC
FEDORA-2019-58c2d3f1aa has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-58c2d3f1aa

Comment 3 Fedora Update System 2019-07-05 00:45:53 UTC
dnf-4.2.7-1.fc30, libdnf-0.35.1-1.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-58c2d3f1aa

Comment 4 Fedora Update System 2019-07-23 07:21:15 UTC
FEDORA-2019-672a74d688 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-672a74d688

Comment 5 Fedora Update System 2019-07-24 01:44:12 UTC
dnf-4.2.7-2.fc30, libdnf-0.35.1-2.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-672a74d688

Comment 6 Fedora Update System 2019-07-30 01:14:43 UTC
dnf-4.2.7-2.fc30, libdnf-0.35.1-2.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.