You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed the for loop doesn't seem to be working.
When the following code is run
(as seen on CodePen)
body
- for (var x = 1; x < 16; x++)
.div= x
I get :
Uncaught Exception ::unable to evaluate [for (var x = 1; x < 16; x++)] - Parsing de.neuland.jade4j.expression.ExpressionHandler.evaluateExpression@1:12 parsing error near '... r x = 1; x ...'
class de.neuland.jade4j.exceptions.JadeCompilerException dashboard-android:31
unable to evaluate [for (var x = 1; x < 16; x++)] - Parsing de.neuland.jade4j.expression.ExpressionHandler.evaluateExpression@1:12 parsing error near '... r x = 1; x ...'
at de.neuland.jade4j.parser.node.ExpressionNode.execute(ExpressionNode.java:46)
at de.neuland.jade4j.parser.node.BlockNode.execute(BlockNode.java:16)
at de.neuland.jade4j.parser.node.TagNode.execute(TagNode.java:73)
at de.neuland.jade4j.parser.node.BlockNode.execute(BlockNode.java:16)
at de.neuland.jade4j.parser.node.TagNode.execute(TagNode.java:73)
at de.neuland.jade4j.parser.node.BlockNode.execute(BlockNode.java:16)
at de.neuland.jade4j.compiler.Compiler.compile(Compiler.java:30)
at de.neuland.jade4j.template.JadeTemplate.process(JadeTemplate.java:23)
at de.neuland.jade4j.JadeConfiguration.renderTemplate(JadeConfiguration.java:71)
at de.neuland.jade4j.JadeConfiguration.renderTemplate(JadeConfiguration.java:76)
at spark.template.jade.JadeTemplateEngine.render(JadeTemplateEngine.java:78)
at spark.TemplateViewRouteImpl$1.render(TemplateViewRouteImpl.java:61)
at spark.TemplateViewRouteImpl$1.render(TemplateViewRouteImpl.java:58)
at spark.TemplateViewRouteImpl.render(TemplateViewRouteImpl.java:85)
at spark.http.matching.Routes.execute(Routes.java:62)
at spark.http.matching.MatcherFilter.doFilter(MatcherFilter.java:126)
at spark.embeddedserver.jetty.JettyHandler.doHandle(JettyHandler.java:50)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:189)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:119)
at org.eclipse.jetty.server.Server.handle(Server.java:517)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:308)
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:242)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:261)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:95)
at org.eclipse.jetty.io.SelectChannelEndPoint$2.run(SelectChannelEndPoint.java:75)
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.produceAndRun(ExecuteProduceConsume.java:213)
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.run(ExecuteProduceConsume.java:147)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:654)
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:572)
at java.lang.Thread.run(Thread.java:745)
Caused by: de.neuland.jade4j.exceptions.ExpressionException: unable to evaluate [for (var x = 1; x < 16; x++)] - Parsing de.neuland.jade4j.expression.ExpressionHandler.evaluateExpression@1:12 parsing error near '... r x = 1; x ...'
at de.neuland.jade4j.expression.ExpressionHandler.evaluateExpression(ExpressionHandler.java:31)
at de.neuland.jade4j.expression.ExpressionHandler.evaluateStringExpression(ExpressionHandler.java:36)
at de.neuland.jade4j.parser.node.ExpressionNode.execute(ExpressionNode.java:28)
... 30 more
Caused by: org.apache.commons.jexl2.JexlException$Parsing: de.neuland.jade4j.expression.ExpressionHandler.evaluateExpression@1:12 parsing error near '... r x = 1; x ...'
at org.apache.commons.jexl2.JexlEngine.parse(JexlEngine.java:1260)
at org.apache.commons.jexl2.JexlEngine.createExpression(JexlEngine.java:435)
at org.apache.commons.jexl2.JexlEngine.createExpression(JexlEngine.java:419)
at de.neuland.jade4j.expression.ExpressionHandler.evaluateExpression(ExpressionHandler.java:28)
... 32 more
Caused by: org.apache.commons.jexl2.parser.ParseException: parse error
at org.apache.commons.jexl2.parser.Parser.generateParseException(Parser.java:3935)
at org.apache.commons.jexl2.parser.Parser.jj_consume_token(Parser.java:3817)
at org.apache.commons.jexl2.parser.Parser.ForeachStatement(Parser.java:374)
at org.apache.commons.jexl2.parser.Parser.Statement(Parser.java:118)
at org.apache.commons.jexl2.parser.Parser.JexlScript(Parser.java:72)
at org.apache.commons.jexl2.parser.Parser.parse(Parser.java:24)
at org.apache.commons.jexl2.JexlEngine.parse(JexlEngine.java:1248)
... 35 more
[qtp1021830707-16] INFO spark.embeddedserver.jetty.EmbeddedJettyServer - >>> Spark shutting down ...
[qtp1021830707-16] INFO org.eclipse.jetty.server.ServerConnector - Stopped ServerConnector@2020264c{HTTP/1.1,[http/1.1]}{0.0.0.0:4567}
[qtp1021830707-16] ERROR spark.embeddedserver.jetty.EmbeddedJettyServer - stop failed
java.lang.InterruptedException
at java.lang.Object.wait(Native Method)
at java.lang.Thread.join(Thread.java:1253)
at org.eclipse.jetty.util.thread.QueuedThreadPool.doStop(QueuedThreadPool.java:161)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:89)
at org.eclipse.jetty.util.component.ContainerLifeCycle.stop(ContainerLifeCycle.java:143)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStop(ContainerLifeCycle.java:161)
at org.eclipse.jetty.server.handler.AbstractHandler.doStop(AbstractHandler.java:73)
at org.eclipse.jetty.server.Server.doStop(Server.java:476)
at org.eclipse.jetty.util.component.AbstractLifeCycle.stop(AbstractLifeCycle.java:89)
at spark.embeddedserver.jetty.EmbeddedJettyServer.extinguish(EmbeddedJettyServer.java:145)
at spark.Service.stop(Service.java:309)
at spark.Spark.stop(Spark.java:1004)
at mycode.packageName.SparkImpl
at spark.Service$1.handle(Service.java:386)
at spark.http.matching.GeneralError.modify(GeneralError.java:43)
at spark.http.matching.MatcherFilter.doFilter(MatcherFilter.java:135)
at spark.embeddedserver.jetty.JettyHandler.doHandle(JettyHandler.java:50)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:189)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:119)
at org.eclipse.jetty.server.Server.handle(Server.java:517)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:308)
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:242)
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:261)
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:95)
at org.eclipse.jetty.io.SelectChannelEndPoint$2.run(SelectChannelEndPoint.java:75)
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.produceAndRun(ExecuteProduceConsume.java:213)
at org.eclipse.jetty.util.thread.strategy.ExecuteProduceConsume.run(ExecuteProduceConsume.java:147)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:654)
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:572)
at java.lang.Thread.run(Thread.java:745)
The text was updated successfully, but these errors were encountered:
Hi
I noticed the
for
loop doesn't seem to be working.When the following code is run
(as seen on CodePen)
I get :
The text was updated successfully, but these errors were encountered: