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.
[ BUILD # : beta 2 ] [ JDK VERSION : 1.4.2_xx ] The following exception is thrown when pasting a lurge chunk of code: java.util.NoSuchElementException at java.util.TreeMap$SubMapEntryIterator.next(TreeMap.java:1076) at java.util.AbstractMap$2.next(AbstractMap.java:382) at java.util.AbstractCollection.toArray(AbstractCollection.java:174) at org.netbeans.modules.editor.structure.api.DocumentModel.getParent(DocumentModel.java:594) at org.netbeans.modules.editor.structure.api.DocumentElement.getParentElement(DocumentElement.java:203) at org.netbeans.modules.xml.text.folding.XmlFoldManager.checkElement2FoldConsistency(XmlFoldManager.java:199) at org.netbeans.modules.xml.text.folding.XmlFoldManager.documentElementAdded(XmlFoldManager.java:138) at org.netbeans.modules.editor.structure.api.DocumentModel.fireDocumentModelEvent(DocumentModel.java:641) at org.netbeans.modules.editor.structure.api.DocumentModel.access$1100(DocumentModel.java:94) at org.netbeans.modules.editor.structure.api.DocumentModel$DocumentModelModificationTransaction.addDE(DocumentModel.java:935) at org.netbeans.modules.editor.structure.api.DocumentModel$DocumentModelModificationTransaction.commit(DocumentModel.java:872) at org.netbeans.modules.editor.structure.api.DocumentModel$DocumentModelModificationTransaction.access$100(DocumentModel.java:757) at org.netbeans.modules.editor.structure.api.DocumentModel.updateModel(DocumentModel.java:417) at org.netbeans.modules.editor.structure.api.DocumentModel.access$400(DocumentModel.java:94) at org.netbeans.modules.editor.structure.api.DocumentModel$2.run(DocumentModel.java:391) at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:471) [catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:904)
Do you have a reproducible testcase? Do you know what and exactly where you pasted the text? Could you attach the original file/pasted text/the position? It would help me much - without this I am affraid I cannot fix it much...
I had a three line build script. I selected it all and pasted a 1000-line-long Ant build code. Does it help?
Aha, so it is likely a duplicate of Issue #63348 ([50cat][navigator] Replacing whole document screws up its tree). The issue doesn't talk about any exception hoever I remember there were some similar when I was fixing it. The issue is fixed now so please try a latest daily build. I am closing the issue as duplicate. If you can still reproduce (btw: is that reproducible?) on a recent build please reopen. Thanks for your report! *** This issue has been marked as a duplicate of 63348 ***
Verifying as duplicate then ...