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.
Created attachment 136143 [details] One of the HTML files causing the problem I have added to my web project several HTML files generated by oXygen Developer (they are the xhtml documentation of some XSD file) and Netbeans reports several strange errors in them, including NullPointerException. I have tried to disable HTML validator in Tools/Options/Editor/Hints but nothing changed. Now in the Projects tree I have a lot of files marked with a red icon without any apparent reason and this is very annoying because it could hide real errors.
Reproducible, the error icon on your file is caused by JavaScript ( I think the closing --> is causing it) so reassigning to JS. I'm not sure about the null pointer error though, no idea where it comes from It could be a bit similar to issue 229637 Product Version: NetBeans IDE Dev (Build web-main-10878-on-20130622) Java: 1.7.0_25; Java HotSpot(TM) Client VM 23.25-b01 Runtime: Java(TM) SE Runtime Environment 1.7.0_25-b15 System: Linux version 3.2.0-45-generic-pae running on i386; UTF-8; en_US (nb)
I've tried to upgrade from v7.3 to v7.3.1 and the problem is still there, so I updated my bug report to the most recent version.
Reporter, according to [1] The comment marks should be preceded by JS comment marks, which in my case helped. Can you please try it? <script type="text/javascript"> //<!-- window.alert("Hello World!"); //--> </script> [1] https://developer.mozilla.org/en/docs/Writing_JavaScript_for_XHTML
Yes, adding JS comment marks solves the problem, thank you! I had to manually modify 29 machine-generated files but this is an acceptable workaround for now. I noted that the IDE became progressively slow while I was editing those files, so I decided to restart it after 20 files. I will report this defect to Oxygen too, hovewer I hope that this kind of JS will be handled better by next versions of Netbeans. Thank you, anyway.
You're welcome. I'm not sure if this is bug on NetBeans side, according to the link above, this is the correct way for XHTML files to use <!-- --> and since your sources were missing it, they were marked as incorrect. But I might be wrong. If you agree, I'd lower this issue to P3 as the NullPointerException appears only with 'incorrect' JavaScript syntax.
OK for lowering priority, however I think that some fix is needed: those NullPointerExceptions in "Action items" seem Netbeans internal errors that popped up that way. Also the slow-down of the IDE when editing those files suggests that something is going wrong. A collegue of mine that added the files to the webapp uses an older version of Netbeans (I'll ask him the version number ASAP) and he didn't get any error in "Action items".
Please, take some profiling snapshot (see [1]) when this slowdown occurs and file a new bug with this snapshot attached. [1] http://wiki.netbeans.org/FaqProfileMeNow
Should be fixed in web-main: http://hg.netbeans.org/web-main/rev/4eb03444b2b4
Integrated into 'main-golden', will be available in build *201306242301* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/4eb03444b2b4 User: Petr Pisl <ppisl@netbeans.org> Log: #231633 - "Action items" window shows NullPointerException in HTML files