Bug 545220 - "Command not found" behavior deviates from standard practices
Summary: "Command not found" behavior deviates from standard practices
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: PackageKit
Version: 13
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Richard Hughes
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 550954 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-12-07 21:36 UTC by David Zeuthen
Modified: 2013-03-06 04:00 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-06-27 14:40:01 UTC


Attachments (Terms of Use)

Description David Zeuthen 2009-12-07 21:36:03 UTC
There are two problems here

 1. You need to use stderr, not stdout
 2. You need a newline at the end

that may confuse existing scripts and practices as this behavior deviates from standard shell error reporting. In fact, 2. is pretty annoying given this behavior when logging in via ssh (e.g. not authorized to install software):

 [davidz@yamato ~]$ this-command-does-not-exist
 Command not found. [davidz@yamato ~]$ 

Anyway, FYI, in particular, I'm running into this problem with the udisks "D-Bus over TCP/IP over ssh tunnel" feature as there is no good way to report errors other than looking at stderr (e.g. can't check $?) - in this case the Palimpsest client writes "udisks-tcp-bridge -p <number>" and then reads stderr. Once there's a whole line of output from stderr, we check whether it's something expected (e.g. "udisks-tcp-bridge: Waiting for secret") or something else like "bash: udisks-tcp-bridge: command not found".

PackageKit-command-not-found obviously breaks this and makes my client hang if there is no udisks-tcp-bridge binary in the users $PATH on the machine being logged into.

I'm imagining there's a bunch of existing scripts that suffers from this too. Would probably be good to fix in F12 too.

Thanks for fixing this.

Comment 1 Richard Hughes 2009-12-08 10:14:20 UTC
(In reply to comment #0)
>  2. You need a newline at the end

This should be fixed with 0.5.5 in updates-testing already.

>  1. You need to use stderr, not stdout

This isn't fixed.

> I'm imagining there's a bunch of existing scripts that suffers from this too.
> Would probably be good to fix in F12 too.

commit 83046c937903e0af117c25d90122781ae3b20978
Author: Richard Hughes <richard@hughsie.com>
Date:   Tue Dec 8 10:12:42 2009 +0000

    cnf: ensure we send error messages to stderr, not stdout. Fxes rh#545220

I'll do a post-0.5.5 fixes rollup at the start of next week as there's another couple of little bugs that fell through the cracks for 0.5.5.

Comment 2 David Zeuthen 2009-12-08 16:01:45 UTC
(In reply to comment #1)
> I'll do a post-0.5.5 fixes rollup at the start of next week as there's another
> couple of little bugs that fell through the cracks for 0.5.5.  

Great, thanks for fixing this.

Comment 3 Richard Hughes 2010-01-05 09:40:07 UTC
*** Bug 550954 has been marked as a duplicate of this bug. ***

Comment 4 Fedora Update System 2010-01-05 11:03:49 UTC
PackageKit-0.5.6-1.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/PackageKit-0.5.6-1.fc12

Comment 5 Fedora Update System 2010-01-05 22:54:58 UTC
PackageKit-0.5.6-1.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update PackageKit'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F12/FEDORA-2010-0193

Comment 6 Fedora Update System 2010-01-12 23:52:47 UTC
PackageKit-0.5.6-1.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 7 Bug Zapper 2010-03-15 13:29:39 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 13 development cycle.
Changing version to '13'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 8 Mads Kiilerich 2010-05-05 15:20:01 UTC
PackageKit hooks in a place where shell users don't expect it to hook in, so I would really like if it told that PackageKit had been started and if the output was prefixed with PackageKit.

That (and other changes) would make the system much more explorable and less magic.

Comment 9 Bug Zapper 2011-06-02 17:10:20 UTC
This message is a reminder that Fedora 13 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 13.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '13'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 13's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 13 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 10 Bug Zapper 2011-06-27 14:40:01 UTC
Fedora 13 changed to end-of-life (EOL) status on 2011-06-25. Fedora 13 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.


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