Bug 1352130 - dnf should not report errors to stdout, it's mildly dangerous
Summary: dnf should not report errors to stdout, it's mildly dangerous
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf
Version: 23
Hardware: All
OS: Linux
low
unspecified
Target Milestone: ---
Assignee: rpm-software-management
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-07-01 17:18 UTC by Oliver Henshaw
Modified: 2016-08-27 10:22 UTC (History)
5 users (show)

Fixed In Version: dnf-1.1.10-1.fc24 dnf-1.1.10-1.fc23 dnf-1.1.10-1.fc25
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-08-19 19:52:07 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Oliver Henshaw 2016-07-01 17:18:08 UTC
Description of problem:

dnf writes to stdout when invoked with an argument it doesn't recognise.

$ dnf repomanageeeee
No such command: repomanageeeee. Please use /usr/bin/dnf --help
It could be a DNF plugin command, try: "dnf install 'dnf-command(repomanageeeee)'
$ dnf repomanageeeee 1> /dev/null
No such command: repomanageeeee. Please use /usr/bin/dnf --help
$ dnf repomanageeeee 2> /dev/null
It could be a DNF plugin command, try: "dnf install 'dnf-command(repomanageeeee)'"

This causes problems when you do something like:

$ TO_REMOVE=`dnf repomanageeeee`
No such command: repomanageeeee. Please use /usr/bin/dnf --help
$ echo $TO_REMOVE 
It could be a DNF plugin command, try: "dnf install 'dnf-command(repomanageeeee)'"
$ ls $TO_REMOVE
...

which I stumbled across after moving from F22 to F23 and the dnf python plugins moved from python 2 > python 3 and I was now missing the repomanage plugin. Luckily I didn't delete anything, but the wrong word in the stdout message could have been dangerous.

(I've now added a check against $? to my script but this shouldn't have happened.)

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

dnf-1.1.9-2.fc23.noarch

Comment 1 Honza Silhan 2016-07-04 11:34:10 UTC
"It could be a DNF plugin command,..." message shoudl be reported to stderr as well.

Comment 3 Fedora Admin XMLRPC Client 2016-07-08 09:40:17 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 4 Igor Gnatenko 2016-07-21 10:23:45 UTC
Fixed in upcoming DNF 2.0 release.

Comment 5 Fedora Update System 2016-08-18 15:20:00 UTC
dnf-1.1.10-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-267f843cda

Comment 6 Fedora Update System 2016-08-18 15:21:05 UTC
dnf-1.1.10-1.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2016-8caa619a9e

Comment 7 Fedora Update System 2016-08-18 15:22:05 UTC
dnf-1.1.10-1.fc24 dnf-plugins-core-0.1.21-3.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-878284e0d3

Comment 8 Fedora Update System 2016-08-18 16:53:16 UTC
dnf-1.1.10-1.fc25, dnf-plugins-core-0.1.21-4.fc25 has been pushed to the Fedora 25 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-2016-8caa619a9e

Comment 9 Fedora Update System 2016-08-19 00:23:00 UTC
dnf-1.1.10-1.fc23, dnf-plugins-core-0.1.21-3.fc23 has been pushed to the Fedora 23 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-2016-267f843cda

Comment 10 Fedora Update System 2016-08-19 00:58:10 UTC
dnf-1.1.10-1.fc24, dnf-plugins-core-0.1.21-3.fc24 has been pushed to the Fedora 24 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-2016-878284e0d3

Comment 11 Fedora Update System 2016-08-19 19:51:05 UTC
dnf-1.1.10-1.fc24, dnf-plugins-core-0.1.21-3.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 12 Fedora Update System 2016-08-23 15:20:14 UTC
dnf-1.1.10-1.fc23, dnf-plugins-core-0.1.21-3.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 13 Fedora Update System 2016-08-27 10:21:16 UTC
dnf-1.1.10-1.fc25, dnf-plugins-core-0.1.21-4.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report.


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