Bug 70140 - [RCP] [Help] Help action fails silently if Help UI not installed
Summary: [RCP] [Help] Help action fails silently if Help UI not installed
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.7 M3   Edit
Assignee: Prakash Rangaraj CLA
QA Contact: Prakash Rangaraj CLA
URL:
Whiteboard:
Keywords: bugday, helpwanted
Depends on:
Blocks:
 
Reported: 2004-07-15 14:15 EDT by Doris Gammenthaler-Vivero CLA
Modified: 2010-10-26 04:45 EDT (History)
3 users (show)

See Also:


Attachments
Patch v01 (847 bytes, patch)
2010-08-03 04:41 EDT, Prakash Rangaraj CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Doris Gammenthaler-Vivero CLA 2004-07-15 14:15:33 EDT
If the dependencies

      <import plugin="org.eclipse.help"/>
      <import plugin="org.eclipse.help.ui"/>
      <import plugin="org.eclipse.help.webapp"/>
      <import plugin="org.eclipse.tomcat"/>

are not stated in plugin.xml, the help system won't work, there is no
explanation why it won't.
 
Reproduce by downloading Ed Burnett's org.eclipse.ui.tutorial.rcp.part3 and run
it according to his instructions in
http://dev.eclipse.org/viewcvs/index.cgi/%7echeckout%7e/org.eclipse.ui.tutorials.rcp.part3/html/tutorial3.html

Then delete the above mentioned entries in plugin.xml, do run - debug - plug-ins
and "deselect all", select "org.eclipse.ui.tutorials.rcp.part3" and "add
required plug-ins". There is no indication why help won't work now.

Without Ed's tutorial it is difficult to find out the needed dependencies (debug
the source code?).
Comment 1 Nick Edgar CLA 2004-07-22 12:55:19 EDT
The standard help action, HelpContentsAction (created by
ActionFactory.HELP_CONTENTS.create(...)) calls WorkbenchHelp.displayHelp().

This has no effect if no help UI is installed -- it currently fails silently.

We should log a message in this case, and bring up a dialog telling the user
that no help UI is installed.  However, it won't be able to provide more help
than this as to which plugins are missing, since the Help UI is pluggable -- you
can have different implementations of it.

I'll add an entry to the RCP FAQ indicating which plug-ins are required for the
default Help UI though.
Comment 2 Nick Edgar CLA 2004-07-22 13:04:53 EDT
Konrad, in Ed's tutorial part 3 (project org.eclipse.ui.tutorials.rcp.part3),
the plugin.xml brings in the Help UI using:

      <import plugin="org.eclipse.help.ui"/>
      <import plugin="org.eclipse.help.webapp"/>
      <import plugin="org.eclipse.tomcat"/>

Could you explain why it's necessary to include webapp and tomcat separately? 
Why aren't these included by help.ui?  Are these only needed if the help content
uses JSPs?  Is it possible to run Help UI without them?


Comment 3 Nick Edgar CLA 2004-07-22 13:05:31 EDT
Note that the tutorial includes these just for the benefit of making Add
Required Plugins work in PDE.  The tutorial does not refer to anything in these
plugins directly.
Comment 4 Konrad Kolosowski CLA 2004-07-22 13:28:31 EDT
Combination of optional/replacable requirements.

org.eclipse.help.ui is optional or replacable in RCP.
org.eclipse.help.ui assumes help is web based and requires an implementation.
org.eclipse.help.webapp is the default implementation contributed through 
extension point to org.eclipse.help.base.  It is replacable.
org.eclipse.help.webapp requires some server to run.
org.eclipse.tomcat is the default implementation contributed through extension 
point to org.eclipse.help.appserver.  The implementation is replacable.

From the above, org.eclipse.help.ui cannot require neither 
org.eclipse.help.webapp nor org.eclipse.tomcat.
The dependency cannot be added the other way either, because in stand-alone 
help or infocenter, org.eclipse.help.webapp and org.eclipse.tomcat need to run 
without org.eclipse.help.ui (with UI dependencies).
Comment 5 Nick Edgar CLA 2004-07-22 14:12:26 EDT
Great, thanks for the clarification/reminder.
Comment 6 Nick Edgar CLA 2005-06-08 20:04:43 EDT
Should still give a warning dialog if no help is installed.
Comment 7 Michael Van Meekeren CLA 2005-06-14 15:09:16 EDT
this should be noted in the RCP FAQ and fixed in 3.2
Comment 8 Nick Edgar CLA 2006-03-15 11:18:35 EST
Reassigning bugs in component areas that are changing ownership.
Comment 9 Boris Bokowski CLA 2006-05-23 12:31:22 EDT
Sorry, I did not have time to address this for 3.2.  At least, the RCP FAQ seems to be up to date regarding the list of plug-ins required for help to work.
Comment 10 Boris Bokowski CLA 2007-04-27 09:01:42 EDT
deferring
Comment 11 Boris Bokowski CLA 2009-11-26 16:14:55 EST
Prakash is now responsible for watching bugs in the [RCP] component area.
Comment 12 Prakash Rangaraj CLA 2010-08-03 04:41:48 EDT
Created attachment 175747 [details]
Patch v01
Comment 13 Prakash Rangaraj CLA 2010-09-28 13:27:31 EDT
Patch v01 released to HEAD. The error message is logged now.
Comment 14 Prakash Rangaraj CLA 2010-10-26 04:41:25 EDT
verified in I20101025-1800 via code inspection