This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 161014 - ClassCastException: org.netbeans.modules.web.core.syntax.gsf.JspGSFParser$JspFakeParserResult
Summary: ClassCastException: org.netbeans.modules.web.core.syntax.gsf.JspGSFParser$Jsp...
Status: RESOLVED DUPLICATE of bug 161033
Alias: None
Product: editor
Classification: Unclassified
Component: Parsing & Indexing (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jan Jancura
URL: http://statistics.netbeans.org/except...
Keywords:
Depends on:
Blocks:
 
Reported: 2009-03-24 12:48 UTC by spaquet
Modified: 2009-04-08 12:43 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 148164


Attachments
stacktrace (777 bytes, text/plain)
2009-03-24 12:48 UTC, spaquet
Details
stacktrace (849 bytes, text/plain)
2009-04-02 12:10 UTC, Oleg Khokhlov
Details
stacktrace (757 bytes, text/plain)
2009-04-08 12:02 UTC, rmatous
Details

Note You need to log in before you can comment on or make changes to this bug.
Description spaquet 2009-03-24 12:48:46 UTC
Build: NetBeans IDE Dev (Build 200903230201)
VM: Java HotSpot(TM) Client VM, 1.5.0_16-133, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_16-b06-284
OS: Mac OS X, 10.5.6, i386

User Comments:
spaquet: Just editing the java class associated with my VisualJSF page;
Actually I was working on the "Submit" button.



Stacktrace: 
java.lang.ClassCastException: org.netbeans.modules.web.core.syntax.gsf.JspGSFParser$JspFakeParserResult
        at org.netbeans.modules.html.editor.HtmlCaretAwareSourceTask.run(HtmlCaretAwareSourceTask.java:60)
        at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:681)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
        at java.util.concurrent.FutureTask.run(FutureTask.java:123)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
Comment 1 spaquet 2009-03-24 12:48:51 UTC
Created attachment 78741 [details]
stacktrace
Comment 2 Marek Fukala 2009-03-24 15:40:17 UTC
Cannot reproduce, but looks like a parsing.api bug. The HtmlCaretAwareSourceTask<HtmlParserResult> is registered for
text/html mimetype only. The JspGSFParser is registered via CSL to text/x-jsp and text/x-tag mimetypes. So I do not
understand why the TaskProcessor tries to call the run method on the HhtmlCaretAwareSourceTask with the
JspFakeParserResult instance.
Comment 3 Vitezslav Stejskal 2009-03-24 15:46:48 UTC
spaquet, can you reproduce this? Or was it a random failure? An isolated test case that would lead this exception would
be invaluable. Thanks
Comment 4 Oleg Khokhlov 2009-04-02 12:10:48 UTC
Build: NetBeans IDE Dev (Build 200903311400)
VM: Java HotSpot(TM) Client VM, 11.3-b02, Java(TM) SE Runtime Environment, 1.6.0_13-b02
OS: Windows XP, 5.1, x86

User Comments: 
opened jsp files

Stacktrace: 
java.lang.ClassCastException: org.netbeans.modules.web.core.syntax.gsf.JspGSFParser$JspFakeParserResult cannot be cast to org.netbeans.modules.html.editor.gsf.HtmlParserResult
        at org.netbeans.modules.html.editor.HtmlCaretAwareSourceTask.run(HtmlCaretAwareSourceTask.java:61)
        at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:681)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
Comment 5 Oleg Khokhlov 2009-04-02 12:10:59 UTC
Created attachment 79271 [details]
stacktrace
Comment 6 rmatous 2009-04-08 12:02:25 UTC
Build: NetBeans IDE Dev (Build 090406)
VM: Java HotSpot(TM) Client VM, 1.5.0_16-b02, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_16-b02
OS: Linux, 2.6.24-23-generic, i386

User Comments: 


Stacktrace: 
java.lang.ClassCastException: org.netbeans.modules.php.editor.parser.PHPParseResult
        at org.netbeans.modules.html.editor.HtmlCaretAwareSourceTask.run(HtmlCaretAwareSourceTask.java:61)
        at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:681)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
        at java.util.concurrent.FutureTask.run(FutureTask.java:123)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
Comment 7 rmatous 2009-04-08 12:02:35 UTC
Created attachment 79716 [details]
stacktrace
Comment 8 Jan Jancura 2009-04-08 12:43:53 UTC

*** This issue has been marked as a duplicate of 161033 ***