Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 187345

Summary: [ErrorHandling] Blank error dialog for runtime error during UIJob
Product: [Eclipse Project] Platform Reporter: Nick Edgar <n.a.edgar>
Component: UIAssignee: Szymon Brandys <Szymon.Brandys>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P3 CC: celek, krzysztof.daniel, Tod_Creasey
Version: 3.3Keywords: helpwanted
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Screen shot of error dialog none

Description Nick Edgar CLA 2007-05-16 14:39:30 EDT
3.3 M6

- hit a WID exception during a UIJob.runInUIThread
- this brought up a jobs error dialog showing simply "Error" as the message (and the name of the job as the title); the Details button was disabled
- although the log had the full exception, the feedback from the error dialog should be improved

This is apparently due to the following code in UIJob.run:
                } finally {
                    // ...               
                    if (result == null) {
						result = new Status(IStatus.ERROR,
                                PlatformUI.PLUGIN_ID, IStatus.ERROR,
                                ProgressMessages.Error,
                                null);
					}
                    // ...               
                }

Since the try block failed with a runtime exception, result was null.
It would be better to catch RuntimeException (and perhaps Error) and construct a more details Status object from the exception.  The exception would be rethrown, and the status passed to job.done(...).
Comment 1 Nick Edgar CLA 2007-05-16 14:41:27 EDT
Created attachment 67476 [details]
Screen shot of error dialog
Comment 2 Krzysztof Daniel CLA 2008-08-14 08:18:59 EDT
I have just spot this bug. I have created patch for this issue in bug 244145. Sorry for the mess.

Szymon, will you close this bug as duplicate of 244145?
Comment 3 Szymon Brandys CLA 2008-08-27 06:07:06 EDT

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