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: NetBeans IDE Dev (Build 20110815-c7e0dc802007) VM: Java HotSpot(TM) 64-Bit Server VM, 19.0-b09, Java(TM) SE Runtime Environment, 1.6.0_23-b05 OS: Linux User Comments: marfous: pressed enter in HEAD section after </script> tag Stacktrace: java.lang.AssertionError: token:> ts=JoinedTokenSequence[ContextDataTokenSequence[ts=TokenSequence for text/x-latte-template/text/html at tokenIndex=0. TokenList contains 1 tokens: *[0]: "<" <0,1> DECLARATION[14] ParT[1/2], IHC=376489243 ,virtual=false],ContextDataTokenSequence[CURRENT,ts=TokenSequence for text/x-latte-template/text/html at tokenIndex=3. TokenList contains 5 tokens: T[0]: "!DOCTYPE" <1,9> DECLARATION[14] ParT[2/2], la=1, st=State(hash=7683932,s=41,ss=0,es=0,tag=null,attr=null), IHC=835425291 T[1]: " " <9,10> WS[3] DefT, la=1, st=State(hash=6264075,s=24,ss=0,es=0,tag=null,attr=null), IHC=744781751 T[2]: "html" <10,14> DECLARATION[14] DefT, la=1, st=State(hash=6264075,s=24,ss=0,es=0,tag=null,attr=null), IHC=2012194341 *[3]: ">" <14,15> DECLARATION[14] DefT, st=State(hash=4259571,s=0,ss=0,es=0,tag=null,attr=null), IHC=377816231 T[4]: "\n" <15,16> TEXT[0] DefT, la=1, st=State(hash=4259571,s=0,ss=0,es=0,tag=null,attr=null), IHC=1995733885 ,virtual=false],ContextDataTokenSequence[ts=TokenSequence at org.netbeans.modules.web.indent.api.support.MarkupAbstractIndenter.getLineIndent(MarkupAbstractIndenter.java:473) at org.netbeans.modules.web.indent.api.support.AbstractIndenter.processLanguage(AbstractIndenter.java:1190) at org.netbeans.modules.web.indent.api.support.AbstractIndenter.calculateIndentation(AbstractIndenter.java:345) at org.netbeans.modules.web.indent.api.support.AbstractIndenter.reindent(AbstractIndenter.java:209) at org.netbeans.modules.html.editor.indent.HtmlIndentTask.reindent(HtmlIndentTask.java:74) at org.netbeans.modules.editor.indent.TaskHandler$MimeItem.runTask(TaskHandler.java:546)
Created attachment 109987 [details] stacktrace
*** Bug 200211 has been marked as a duplicate of this bug. ***
This exception happens only on Latte files. Should be filed for Nette plugin and evaluated there first.
NetBeans-PHP 201205200400 This error occurs when editing PHP files. exception report @ http://statistics.netbeans.org/analytics/exception.do?id=581981 reopened because: nothing to do with Latte..
(In reply to comment #4) > NetBeans-PHP 201205200400 also in nb 201205280002 To Reproduce: create new php file and paste: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <base href="<?php echo $baseref; ?>" /> Now try to hit enter at the trailing '/>'. It's worth noting that if the DOCTYPE was simply <!DOCTYPE html> this bug does not occur, interesting? ;)
Thanks for the test case. I have not had a time to try it but will early next week. Thanks.
I just wanted to ask (and bump a bit) if the status of this issue is being considered or even worked on. We have a serious problem with it in the Nette plugin but I am still not sure if it's related only to Latte files or it's a problem with HTML indenter (that's what the stacktrace shows). My case where the error comes up (with Nette plugin in a .latte file) is when pressing Enter right after this text <!DOCTYPE html>. Even this simple code throws exception. Regards. Nette plugin dev
Bump. David, did you have a time to look at this issue (as you promised almost a month ago)? Verified also on Linux. By the way, priority should be P2, not P3 since there is a workaround, but is really impractical and the bug is annoying. Thanks. PS: Any possibility to get this fixed in final 7.2?
Looking at it right! Too much work and too little time. I'm very sorry!
Fixed and unit test added. 75665a9f7caf Unfortunately it is too late for inclusion of this fix in 7.2 - 7.2 is in high resistance mode and only fixes of P1s or serious P2s are allowed to be integrated. It will be fixed in 7.2 Patch 1. A workaround for this problem it to structure the code in your test case like this: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <base href="<?php echo $baseref; ?>" /> -> notice a one more empty line I added between "href" definition. If there is enough demand I can build a patched version of org.netbeans.modules.web.indent.jar and attach it to this issued once NB7.2 is released which could be used as short time patch. As usual verification of the fix on daily dev build of NB 7.3 would be appreciated. Continual builder will append a build number here once the fix is part of a build.
Integrated into 'main-golden', will be available in build *201206220002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/75665a9f7caf User: David Konecny <dkonecny@netbeans.org> Log: #200967 - AssertionError: token:> ts=JoinedTokenSequence
regression see bug 214777
> regression see bug 214777 Must be a different way to trigger the same assertion.
unable to reproduce in trunk with given sample code and other snippets in reports => verified Product Version: NetBeans IDE Dev (Build 201208080001) Java: 1.7.0_06; Java HotSpot(TM) Client VM 23.2-b09 System: Linux version 3.0.0-23-generic running on i386; UTF-8; en_US (nb)
So changeset 75665a9f7caf should be transplanted to release72 branch for the 7.2 patch? If so, could you do that David? Thanks.
Transplanted to release72 branch as changeset 77321fe2823a.
Integrated into 'releases', will be available in build *201209010822* or newer. Wait for official and publicly available build. Changeset: http://hg.netbeans.org/releases/rev/77321fe2823a User: David Konecny <dkonecny@netbeans.org> Log: #200967 - AssertionError: token:> ts=JoinedTokenSequence
Unable to reproduce with given samples => verifying for patch Product Version: NetBeans IDE 7.2 (Build 201207171143) Java: 1.7.0_07; Java HotSpot(TM) Client VM 23.3-b01 System: Linux version 3.2.0-30-generic-pae running on i386; UTF-8; en_US (nb)