Bug 120322 - Konsole sessions die immediately when binaries not present, diagnostic missing
Summary: Konsole sessions die immediately when binaries not present, diagnostic missing
Status: RESOLVED FIXED
Alias: None
Product: konsole
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: unspecified All
: NOR wishlist
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
: 146506 146786 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-01-17 16:39 UTC by Peter Rockai
Modified: 2008-03-19 18:13 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Rockai 2006-01-17 16:39:01 UTC
Konsole ships with several predefined session types, eg "Midnight    
Commander". However, when mc binary is not present, trying to open this type of   
session makes a tab appear and disappear without useful hint what went wrong.   
  
The wish is to either show some useful diagnostic (the easier solution) or to 
not list sessions with missing binaries (quite hard solution).
Comment 1 Kurt Hindenburg 2006-01-30 18:13:22 UTC
In KDE 3.5.x, if the Exec= command is not valid, the session is removed from the menu.  A warning is displayed if you run konsole from another terminal. 

Here, my system doesn't have mc installed:

konsole: WARNING: Unable to use /opt/KDEDIRS/branches/3.5/share/apps/konsole/mc.desktop
konsole: WARNING: Unable to use /opt/KDEDIRS/branches/3.5/share/apps/konsole/sumc.desktop


If you remove mc and try using the mc session in an already open Konsole, perhaps a popup message?  This would have to wait for KDE4 anyway.
Comment 2 Peter Rockai 2006-01-30 19:11:07 UTC
Ah, thanks, i managed to not notice it. I would say this is more than sufficient, so unless you specifically want to implement the popup message and have this bug remind you about it, feel free to close the report, i have no more wishes in this respect than what you describe. Thanks again.
Comment 3 Robert Knight 2007-06-08 22:10:51 UTC
*** Bug 146506 has been marked as a duplicate of this bug. ***
Comment 4 Robert Knight 2007-06-17 01:15:05 UTC
*** Bug 146786 has been marked as a duplicate of this bug. ***
Comment 5 Robert Knight 2007-06-17 01:16:31 UTC
Update - Konsole still gives the same pty error regardless of what causes the session to fail to start.  Better diagnostics are needed.
Comment 6 Robert Knight 2008-01-03 20:32:02 UTC
KDE 4.0.  All of the default profiles (mc,root,python etc.) found in earlier Konsoles have been removed so people will hopefully not be tripped up so easily by this.  However the basic problem about a lack of diagnostic messages is still present.
Comment 7 Robert Knight 2008-03-19 18:13:41 UTC
SVN commit 787709 by knight:

Display a warning message in the terminal in red if starting the session
fails because the binary does not exist or if the shell crashes or exits
with a non-zero status code.

In these cases, also prevent the tab from being closed automatically.

If the binary for the session cannot be found, display a warning and try
to fall back to $SHELL or as a last attempt, /bin/sh.  This should mean
that users should always be given a semi-functional basic environment
if their profiles get messed up, the shell program gets uninstalled etc.

BUG: 120322


 M  +70 -22    Session.cpp  
 M  +7 -0      Session.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=787709