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.
Sometimes, when typing quickly while editing HTML files, I get a several small error dialogs (NullPointerException) within one minute or so. I can continue working after closing each dialog, but it interrupts typing. I heard from two other guys, they were experiencing the same problem (one Sun, one community member). I don't know which OS they had or which type of file they were editing, but they said, quick typing even crashed the IDE in their case. (!) Sorry, none of us found a way to reproduce it, it happens sometimes and then I restart the IDE and it's gone for some days. Random additional info: - Possibly, I hit two keys at the same time, but that does not normally cause errors. - In the logs, I see NullPointerException and BadLocationException together with HTMLSyntaxSupport, HTMLFormatter, and HTMLFoldManager; I have not been using any code folding when the errors happened, if that is of any importance. - I was typing arrow keys when it happened, the others said they were repetitive ly using F3, backspace, and ctrl combinations. (Possibly, the bug can be caused by any key.)
Hold on -- I reproduced it! I go to the first line of an html file, make a newline before <DOCTYPE>, hold down shift and type "<>". I admit nobody adds a tag before <DOCTYPE> in real life, but I don't remember what the other cases really were. Everytime I do that, I get two error messages "NullPointerException: Please report this" and, when I click previous, "NullPointerException: However the system should continue working without further problems". Well, it does continue working -- but sometimes *I* can't continue working because I have to close these messages all the time... ;-) java.lang.NullPointerException at org.netbeans.editor.ext.html.HTMLFormatter.getReformatBlock(HTMLFormatter.java:259) at org.netbeans.editor.ext.ExtKit$ExtDefaultKeyTypedAction.checkIndentHotChars(ExtKit.java:860) at org.netbeans.editor.ext.ExtKit$ExtDefaultKeyTypedAction.actionPerformed(ExtKit.java:844) at org.netbeans.editor.BaseAction.actionPerformed(BaseAction.java:194) at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1571) at javax.swing.JComponent.processKeyBinding(JComponent.java:2763) at javax.swing.JComponent.processKeyBindings(JComponent.java:2798) at javax.swing.JComponent.processKeyEvent(JComponent.java:2726) at java.awt.Component.processEvent(Component.java:5265) at java.awt.Container.processEvent(Container.java:1966) at java.awt.Component.dispatchEventImpl(Component.java:3955) at java.awt.Container.dispatchEventImpl(Container.java:2024) at java.awt.Component.dispatchEvent(Component.java:3803) at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1810) at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:672) at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:920) at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:798) at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:636) at java.awt.Component.dispatchEventImpl(Component.java:3841) at java.awt.Container.dispatchEventImpl(Container.java:2024) at java.awt.Window.dispatchEventImpl(Window.java:1774) at java.awt.Component.dispatchEvent(Component.java:3803) [catch] at java.awt.EventQueue.dispatchEvent(EventQueue.java:463) at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149) at java.awt.EventDispatchThread.run(EventDispatchThread.java:110) java.lang.NullPointerException at org.netbeans.editor.ext.html.HTMLSyntaxSupport.getElementChain(HTMLSyntaxSupport.java:336) at org.netbeans.modules.html.editor.folding.HTMLFoldManager.generateFolds(HTMLFoldManager.java:175) at org.netbeans.modules.html.editor.folding.HTMLFoldManager.updateFolds(HTMLFoldManager.java:255) at org.netbeans.modules.html.editor.folding.HTMLFoldManager.access$200(HTMLFoldManager.java:58) at org.netbeans.modules.html.editor.folding.HTMLFoldManager$2.run(HTMLFoldManager.java:115) [catch] at java.lang.Thread.run(Thread.java:595)
Not able to reproduce this problem on NB 6.5. Closing as WORKSFORME. Reporter, please reopen if you still can reproduce on NB 6.5.
It's okay now, the bug disappered in later versions.