Bug 1347105 - dnf repoquery returns no results by default with --whatrequires
Summary: dnf repoquery returns no results by default with --whatrequires
Status: CLOSED DUPLICATE of bug 1343880
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf-plugins-core
Version: 23
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Packaging Maintenance Team
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2016-06-16 04:47 UTC by bryant
Modified: 2016-06-20 12:02 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2016-06-20 12:02:32 UTC
Type: Bug

Attachments (Terms of Use)

Description bryant 2016-06-16 04:47:55 UTC
Description of problem:
I've noticed that sometimes new packages are installed during regular system updates and I wanted to see why that was. I was pointed to the dnf repoquery --whatrequires PACKAGE command to look at package dependencies. But by default this doesn't return anything useful:

$ dnf repoquery --whatrequires double-conversion
Last metadata expiration check: 0:11:59 ago on Wed Jun 15 21:31:33 2016.

That output is problematic as it doesn't give any useful output and also doesn't tell the user how to get useful output. I've found that rerunning the command with the --alldeps option gives the proper output:

$ dnf repoquery --whatrequires double-conversion --alldeps
Last metadata expiration check: 0:13:01 ago on Wed Jun 15 21:31:33 2016.

Now the documentation for the --alldeps option is terse and doesn't actually help at all (see http://dnf-plugins-core.readthedocs.io/en/latest/repoquery.html). Not only is there no discoverability for this, there's no way to understand why this works just from the docs.

So my suggestion is to change the default behavior of --whatrequires to output meaningful data by default and then to also proper output when there are no results such that a user can refine their query. I understand the output of this command is supposed to be easily machine-readable, but there's gotta be a better way for this command to work then to just display nothing until an effectively undocumented flag is set and then do the right thing.

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

Comment 1 Jaroslav Mracek 2016-06-20 12:02:32 UTC
The default behavior was changed but fix is under review.

*** This bug has been marked as a duplicate of bug 1343880 ***

Note You need to log in before you can comment on or make changes to this bug.