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 231007 - JSP editing not possible at all.
Summary: JSP editing not possible at all.
Status: RESOLVED INCOMPLETE
Alias: None
Product: javaee
Classification: Unclassified
Component: JSP (show other bugs)
Version: 7.4
Hardware: PC Windows 7
: P2 normal (vote)
Assignee: Martin Fousek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-10 06:00 UTC by stwr
Modified: 2013-06-12 07:31 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description stwr 2013-06-10 06:00:06 UTC
Product Version = NetBeans IDE Dev (Build nbms-and-javadoc-11079-on-20130605)
Operating System = Windows 7 version 6.1 running on amd64
Java; VM; Vendor = 1.7.0_21
Runtime = Java HotSpot(TM) 64-Bit Server VM 23.21-b01

Got following exception while editing a JSP file. In a fact the JSP editing isn't possible at all in this build.

java.lang.NullPointerException
	at org.netbeans.modules.web.core.syntax.parser.JspSyntaxParser.parseDocument(JspSyntaxParser.java:277)
	at org.netbeans.modules.web.core.syntax.parser.JspSyntaxParser.parse(JspSyntaxParser.java:80)
	at org.netbeans.modules.web.core.syntax.gsf.JspGSFParser.parse(JspGSFParser.java:63)
	at org.netbeans.modules.parsing.impl.TaskProcessor.callParse(TaskProcessor.java:598)
	at org.netbeans.modules.parsing.impl.SourceCache.getResult(SourceCache.java:236)
[catch] at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:720)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
	at java.util.concurrent.FutureTask.run(FutureTask.java:166)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:722)
Comment 1 Vladimir Riha 2013-06-10 10:23:11 UTC
Could you please try newer build? I tried some editing and no NPE but I might be missing some steps. Thanks
Comment 2 David Konecny 2013-06-12 04:48:10 UTC
Any chance this is related to your changes Martin?
Comment 3 Martin Fousek 2013-06-12 06:08:32 UTC
(In reply to comment #2)
> Any chance this is related to your changes Martin?

No, it shouldn't be. Parser upgrades were done 2-3 months ago. In any case this is still only one report we got and I'm afraid that we don't have enough of information for the cause detection. I'll take care but not much to do here now. It looks that the lexer could be somehow wrongly initialized since the TokenHierarchy was null.

Reported please, does it happen regularly to you (are you able to reproduce it)? Could you attach also your messages log?
http://wiki.netbeans.org/FaqLogMessagesFile
Comment 4 stwr 2013-06-12 06:38:44 UTC
I got it just once (together with Issue #231007). After I restarted the IDE the NPE was gone and I can't reproduce it longer.
The messages log does not contain the stack trace so I guess it has been overwritten already.
As far I will get the exception again I will report.
Comment 5 Martin Fousek 2013-06-12 07:31:22 UTC
(In reply to comment #4)
> I got it just once (together with Issue #231007). After I restarted the IDE the
> NPE was gone and I can't reproduce it longer.
> The messages log does not contain the stack trace so I guess it has been
> overwritten already.
> As far I will get the exception again I will report.

Thanks for quick reply. The issue #231006 looks to have the same symptoms as this one. It looks that the lexer wasn't ready yet so the TH was null. It's possible to fix it but I think that it will be better to wait for the messages.log since it can show serious issue in JSP lexer or similarly. I'm closing this as incomplete for now and feel free to reopen any time you would get to the messages.log with the exception.

By the way, inside your userdir could be placed messages.log.<integer_suffix> with older message logs so you can take a look. Otherwise I would recommend to wait for the next report, the NPE can be fixed easily anytime (but I don't want to hide another possible issue by the fix).

Thanks a lot.