The following code used to work


define mainResponsive() {
includeHead(rendertemplate(rssLink()))

}

define rssLink() { } // default definition

template wikilayout(w: Wiki) {
define rssLink() { // local override
<link rel=“alternate” type=“application/rss+xml” title=“RSS” href=navigate(feed(“wiki”)) >
}
mainResponsive { … }
}

but now causes this error:


java.lang.ArrayIndexOutOfBoundsException: 0
at webdsl.generated.templates.wikilayoutWiki_rssLink0$l$Wiki_Template.storeArguments(wikilayoutWiki_rssLink0$l$Wiki_Template.java:40)
at utils.TemplateServlet.tryInitializeTemplate(TemplateServlet.java:179)
at utils.TemplateServlet.render(TemplateServlet.java:93)
at utils.AbstractPageServlet.executeTemplatePhase(AbstractPageServlet.java:169)
at utils.AbstractPageServlet.renderTemplate(AbstractPageServlet.java:151)
at webdsl.generated.templates.mainResponsive_Template.renderInternal(mainResponsive_Template.java:220)
at utils.TemplateServlet.render(TemplateServlet.java:101)
at webdsl.generated.templates.wikilayoutWiki_Template.renderInternal(wikilayoutWiki_Template.java:196)
at utils.TemplateServlet.render(TemplateServlet.java:101)
at webdsl.generated.templates.wiki_Template.renderInternal(wiki_Template.java:310)
at utils.TemplateServlet.render(TemplateServlet.java:101)
at webdsl.generated.templates.WikiPage.render(WikiPage.java:237)
at webdsl.generated.templates.WikiPage.serve(WikiPage.java:161)
at utils.DispatchServletHelper.handlePage(DispatchServletHelper.java:680)
at utils.DispatchServletHelper.doServe(DispatchServletHelper.java:640)
at utils.DispatchServlet.doGet(DispatchServlet.java:252)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
at java.lang.Thread.run(Thread.java:680)

java.lang.NullPointerException
at utils.AbstractPageServlet.executeTemplatePhase(AbstractPageServlet.java:175)
at utils.AbstractPageServlet.renderTemplate(AbstractPageServlet.java:151)
at webdsl.generated.templates.mainResponsive_Template.renderInternal(mainResponsive_Template.java:220)
at utils.TemplateServlet.render(TemplateServlet.java:101)
at webdsl.generated.templates.wikilayoutWiki_Template.renderInternal(wikilayoutWiki_Template.java:196)
at utils.TemplateServlet.render(TemplateServlet.java:101)
at webdsl.generated.templates.wiki_Template.renderInternal(wiki_Template.java:310)
at utils.TemplateServlet.render(TemplateServlet.java:101)
at webdsl.generated.templates.WikiPage.render(WikiPage.java:237)
at webdsl.generated.templates.WikiPage.serve(WikiPage.java:161)
at utils.DispatchServletHelper.handlePage(DispatchServletHelper.java:680)
at utils.DispatchServletHelper.doServe(DispatchServletHelper.java:640)
at utils.DispatchServlet.doGet(DispatchServlet.java:252)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
at java.lang.Thread.run(Thread.java:680)

Submitted by Eelco Visser on 8 September 2012 at 12:43

On 24 October 2013 at 14:39 Danny Groenewegen commented:

duplicate of https://yellowgrass.org/issue/WebDSL/393

fixed in r5816


On 24 October 2013 at 14:39 Danny Groenewegen closed this issue.

On 24 October 2013 at 14:41 Danny Groenewegen tagged 1.3.0

Log in to post comments