Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » Error on displaying Problem Marker in Problem View in Eclipse 3.2
Error on displaying Problem Marker in Problem View in Eclipse 3.2 [message #306405] Thu, 27 July 2006 22:49 Go to next message
Eclipse UserFriend
Originally posted by: zzhang.numericatech.com

Hi,

I put Problem Markers in my editor, and when I try to open the "Problem
View", an error dialog will pop up
showing
"An error has occured. See error log for more details."

And in the problem view, I can see the error message, but the node category
"error" has not text or icon.
the problem entry does have an icon (red square) though (insteadof a red
circle with white cross in Eclipse 3.1)

And this has been tested working for me in Eclipse 3.1.

The log file shows the stacktrace of

!ENTRY org.eclipse.jface 4 2 2006-07-27 15:26:03.859
!MESSAGE Problems occurred when invoking code from plug-in:
"org.eclipse.jface".
!STACK 0
org.eclipse.jface.util.Assert$AssertionFailedException: null argument;
at org.eclipse.jface.util.Assert.isNotNull(Assert.java:150)
at org.eclipse.jface.util.Assert.isNotNull(Assert.java:126)
at
org.eclipse.jface.resource.ResourceManager.createImage(Resou rceManager.java:93)
at
org.eclipse.ui.views.markers.internal.FieldSeverityAndMessag e.getImage(FieldSeverityAndMessage.java:65)
at
org.eclipse.ui.views.markers.internal.TableViewLabelProvider .getColumnImage(TableViewLabelProvider.java:49)
at org.eclipse.jface.viewers.TreeViewer.doUpdateItem(TreeViewer .java:310)
at
org.eclipse.jface.viewers.AbstractTreeViewer$UpdateItemSafeR unnable.run(AbstractTreeViewer.java:95)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
at org.eclipse.core.runtime.Platform.run(Platform.java:843)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:14 9)
at
org.eclipse.jface.viewers.AbstractTreeViewer.doUpdateItem(Ab stractTreeViewer.java:840)
at
org.eclipse.jface.viewers.StructuredViewer$UpdateItemSafeRun nable.run(StructuredViewer.java:465)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
at org.eclipse.core.runtime.Platform.run(Platform.java:843)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:14 9)
at
org.eclipse.jface.viewers.StructuredViewer.updateItem(Struct uredViewer.java:1955)
at
org.eclipse.jface.viewers.AbstractTreeViewer.createTreeItem( AbstractTreeViewer.java:744)
at
org.eclipse.jface.viewers.AbstractTreeViewer.updateChildren( AbstractTreeViewer.java:2427)
at
org.eclipse.jface.viewers.AbstractTreeViewer.internalRefresh Struct(AbstractTreeViewer.java:1640)
at
org.eclipse.jface.viewers.TreeViewer.internalRefreshStruct(T reeViewer.java:955)
at
org.eclipse.jface.viewers.AbstractTreeViewer.internalRefresh (AbstractTreeViewer.java:1616)
at
org.eclipse.jface.viewers.AbstractTreeViewer.internalRefresh (AbstractTreeViewer.java:1571)
at
org.eclipse.jface.viewers.StructuredViewer$8.run(StructuredV iewer.java:1415)
at
org.eclipse.jface.viewers.StructuredViewer.preservingSelecti on(StructuredViewer.java:1323)
at
org.eclipse.jface.viewers.StructuredViewer.refresh(Structure dViewer.java:1413)
at
org.eclipse.jface.viewers.StructuredViewer.refresh(Structure dViewer.java:1370)
at
org.eclipse.ui.views.markers.internal.MarkerView$UpdateJob.r unInUIThread(MarkerView.java:222)
at org.eclipse.ui.progress.UIJob$1.run(UIJob.java:94)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:3 5)
at
org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchr onizer.java:123)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.jav a:3325)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2971)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:1914)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1878)
at
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:419)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
at com.rcp.Application.run(Application.java:1
at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(Pl atformActivator.java:7
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:92)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:6
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:400)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:177)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336 )
at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
at org.eclipse.core.launcher.Main.run(Main.java:977)
at org.eclipse.core.launcher.Main.main(Main.java:952)


I also found a similar report from EclipsePluginCentral
http://www.eclipseplugincentral.com/PNphpBB2-printview-t-354 2-start-0.html

Is this a bug for Eclipse 3.2?

Any help is appreciated!!

Thanks.

Sincerely,
Stan
Re: Error on displaying Problem Marker in Problem View in Eclipse 3.2 [message #306438 is a reply to message #306405] Fri, 28 July 2006 14:36 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wharley.bea.com

"zzhang" <zzhang@numericatech.com> wrote in message
news:eabtvg$30f$1@utils.eclipse.org...
> Hi,
>
> I put Problem Markers in my editor, and when I try to open the "Problem
> View", an error dialog will pop up
> showing
> "An error has occured. See error log for more details."
>
> And in the problem view, I can see the error message, but the node
> category "error" has not text or icon.
> the problem entry does have an icon (red square) though (insteadof a red
> circle with white cross in Eclipse 3.1)
>
> And this has been tested working for me in Eclipse 3.1.
>
> The log file shows the stacktrace of
>
> !ENTRY org.eclipse.jface 4 2 2006-07-27 15:26:03.859
> !MESSAGE Problems occurred when invoking code from plug-in:
> "org.eclipse.jface".
> !STACK 0
> org.eclipse.jface.util.Assert$AssertionFailedException: null argument;
> at org.eclipse.jface.util.Assert.isNotNull(Assert.java:150)
> at org.eclipse.jface.util.Assert.isNotNull(Assert.java:126)
> at
> org.eclipse.jface.resource.ResourceManager.createImage(Resou rceManager.java:93)
> at
> org.eclipse.ui.views.markers.internal.FieldSeverityAndMessag e.getImage(FieldSeverityAndMessage.java:65)
> at
> org.eclipse.ui.views.markers.internal.TableViewLabelProvider .getColumnImage(TableViewLabelProvider.java:49)


Sounds like it is trying to get an icon to attach to the marker, and failing
to find it. Can you post a short excerpt of the code that you are using to
create the marker?
Re: Error on displaying Problem Marker in Problem View in Eclipse 3.2 [message #306440 is a reply to message #306438] Fri, 28 July 2006 15:39 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: zzhang.numericatech.com

Dear Walter,

Yes, you're right. I use debug, it seems the Eclipse failed to get
ImageDescriptor for this string
IDEInternalWorkbenchImages.IMG_ETOOL_PROBLEM_CATEGORY
while calling in FieldSeverityAndMessage.getImage
....
return
JFaceResources.getResources().createImage(IDEInternalWorkben chImages.getImageDescriptor(
IDEInternalWorkbenchImages.IMG_ETOOL_PROBLEM_CATEGORY)
.....

Below is the code I created Marker (again, it has no problem under Eclipse
3.1. It seems the introduction of the category caused the error).


Map<String, Object> map = new HashMap<String, Object>();
MarkerUtilities.setLineNumber(map, lineNumber);
MarkerUtilities.setMessage(map, e.getMessage());
map.put(IMarker.LOCATION, file.getFullPath().toString());
Integer charStart = new Integer(document.getLineOffset(lineNumber-1));
if (charStart != null)
map.put(IMarker.CHAR_START, charStart);

Integer charEnd = charStart;
charEnd = new Integer(document.getLineOffset(lineNumber)-2);
if (charEnd != null)
{
map.put(IMarker.CHAR_END, charEnd);
}
map.put(IMarker.SEVERITY, new Integer(IMarker.SEVERITY_ERROR));
map.put(IMarker.TRANSIENT, true);
MarkerUtilities.createMarker(file, map, IMarker.PROBLEM);


Thanks again.

Sincerely,
Stan



"Walter Harley" <wharley@bea.com> wrote in message
news:eadlft$bjm$1@utils.eclipse.org...
> "zzhang" <zzhang@numericatech.com> wrote in message
> news:eabtvg$30f$1@utils.eclipse.org...
>> Hi,
>>
>> I put Problem Markers in my editor, and when I try to open the "Problem
>> View", an error dialog will pop up
>> showing
>> "An error has occured. See error log for more details."
>>
>> And in the problem view, I can see the error message, but the node
>> category "error" has not text or icon.
>> the problem entry does have an icon (red square) though (insteadof a red
>> circle with white cross in Eclipse 3.1)
>>
>> And this has been tested working for me in Eclipse 3.1.
>>
>> The log file shows the stacktrace of
>>
>> !ENTRY org.eclipse.jface 4 2 2006-07-27 15:26:03.859
>> !MESSAGE Problems occurred when invoking code from plug-in:
>> "org.eclipse.jface".
>> !STACK 0
>> org.eclipse.jface.util.Assert$AssertionFailedException: null argument;
>> at org.eclipse.jface.util.Assert.isNotNull(Assert.java:150)
>> at org.eclipse.jface.util.Assert.isNotNull(Assert.java:126)
>> at
>> org.eclipse.jface.resource.ResourceManager.createImage(Resou rceManager.java:93)
>> at
>> org.eclipse.ui.views.markers.internal.FieldSeverityAndMessag e.getImage(FieldSeverityAndMessage.java:65)
>> at
>> org.eclipse.ui.views.markers.internal.TableViewLabelProvider .getColumnImage(TableViewLabelProvider.java:49)
>
>
> Sounds like it is trying to get an icon to attach to the marker, and
> failing to find it. Can you post a short excerpt of the code that you are
> using to create the marker?
>
Re: Error on displaying Problem Marker in Problem View in Eclipse 3.2 [message #306633 is a reply to message #306440] Thu, 03 August 2006 03:53 Go to previous message
Eclipse UserFriend
zzhang wrote:

>Dear Walter,
>
>Yes, you're right. I use debug, it seems the Eclipse failed to get
>ImageDescriptor for this string
> IDEInternalWorkbenchImages.IMG_ETOOL_PROBLEM_CATEGORY
>while calling in FieldSeverityAndMessage.getImage
>...
>return
> JFaceResources.getResources().createImage(IDEInternalWorkben chImages.getImageDescriptor(
> IDEInternalWorkbenchImages.IMG_ETOOL_PROBLEM_CATEGORY)
>....
>
>Below is the code I created Marker (again, it has no problem under Eclipse
>3.1. It seems the introduction of the category caused the error).
>
>
Well, you're doomed to fail: when using internal code you must expect to
be broken at any time.

Dani

>
> Map<String, Object> map = new HashMap<String, Object>();
> MarkerUtilities.setLineNumber(map, lineNumber);
> MarkerUtilities.setMessage(map, e.getMessage());
> map.put(IMarker.LOCATION, file.getFullPath().toString());
> Integer charStart = new Integer(document.getLineOffset(lineNumber-1));
> if (charStart != null)
> map.put(IMarker.CHAR_START, charStart);
>
> Integer charEnd = charStart;
> charEnd = new Integer(document.getLineOffset(lineNumber)-2);
> if (charEnd != null)
> {
> map.put(IMarker.CHAR_END, charEnd);
> }
> map.put(IMarker.SEVERITY, new Integer(IMarker.SEVERITY_ERROR));
> map.put(IMarker.TRANSIENT, true);
> MarkerUtilities.createMarker(file, map, IMarker.PROBLEM);
>
>
>Thanks again.
>
>Sincerely,
>Stan
>
>
>
>"Walter Harley" <wharley@bea.com> wrote in message
>news:eadlft$bjm$1@utils.eclipse.org...
>
>
>>"zzhang" <zzhang@numericatech.com> wrote in message
>>news:eabtvg$30f$1@utils.eclipse.org...
>>
>>
>>>Hi,
>>>
>>>I put Problem Markers in my editor, and when I try to open the "Problem
>>>View", an error dialog will pop up
>>>showing
>>>"An error has occured. See error log for more details."
>>>
>>>And in the problem view, I can see the error message, but the node
>>>category "error" has not text or icon.
>>>the problem entry does have an icon (red square) though (insteadof a red
>>>circle with white cross in Eclipse 3.1)
>>>
>>>And this has been tested working for me in Eclipse 3.1.
>>>
>>>The log file shows the stacktrace of
>>>
>>>!ENTRY org.eclipse.jface 4 2 2006-07-27 15:26:03.859
>>>!MESSAGE Problems occurred when invoking code from plug-in:
>>>"org.eclipse.jface".
>>>!STACK 0
>>>org.eclipse.jface.util.Assert$AssertionFailedException: null argument;
>>>at org.eclipse.jface.util.Assert.isNotNull(Assert.java:150)
>>>at org.eclipse.jface.util.Assert.isNotNull(Assert.java:126)
>>>at
>>> org.eclipse.jface.resource.ResourceManager.createImage(Resou rceManager.java:93)
>>>at
>>> org.eclipse.ui.views.markers.internal.FieldSeverityAndMessag e.getImage(FieldSeverityAndMessage.java:65)
>>>at
>>> org.eclipse.ui.views.markers.internal.TableViewLabelProvider .getColumnImage(TableViewLabelProvider.java:49)
>>>
>>>
>>Sounds like it is trying to get an icon to attach to the marker, and
>>failing to find it. Can you post a short excerpt of the code that you are
>>using to create the marker?
>>
>>
>>
>
>
>
>
Previous Topic:Markers and annotations, text not highlighted
Next Topic:Use Eclipse Search and Replace feature programatically from Ant?
Goto Forum:
  


Current Time: Tue May 06 06:01:22 EDT 2025

Powered by FUDForum. Page generated in 0.04399 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top