Uploaded image for project: 'Velocity'
  1. Velocity
  2. VELOCITY-779

parse #[[#foreach()]]# error

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Invalid
    • 1.6.4
    • None
    • Engine
    • None

    Description

      The following VTL

      #[#foreach()]#

      It should be:

      #foreach()

      but exception :

      org.apache.velocity.exception.ParseErrorException: Encountered "<EOF>" at /purchase/print/inQueryPrint.vm[line 30, column 18]
      Was expecting one of:
      "(" ...
      <RPAREN> ...
      <ESCAPE_DIRECTIVE> ...
      <SET_DIRECTIVE> ...
      "##" ...
      "\\\\" ...
      "
      " ...
      <TEXT> ...
      "*#" ...
      "*#" ...
      <STRING_LITERAL> ...
      <END> ...
      <IF_DIRECTIVE> ...
      <STOP_DIRECTIVE> ...
      <INTEGER_LITERAL> ...
      <FLOATING_POINT_LITERAL> ...
      <WORD> ...
      <BRACKETED_WORD> ...
      <IDENTIFIER> ...
      <DOT> ...
      "

      {" ... "}

      " ...

      at org.apache.velocity.Template.process(Template.java:141)
      at org.apache.velocity.runtime.resource.ResourceManagerImpl.loadResource(ResourceManagerImpl.java:446)
      at org.apache.velocity.runtime.resource.ResourceManagerImpl.getResource(ResourceManagerImpl.java:354)
      at org.apache.velocity.runtime.RuntimeInstance.getTemplate(RuntimeInstance.java:1400)
      at org.apache.velocity.runtime.RuntimeInstance.getTemplate(RuntimeInstance.java:1380)
      at org.apache.velocity.app.VelocityEngine.getTemplate(VelocityEngine.java:401)

      Attachments

        Activity

          People

            Unassigned Unassigned
            jetma Jet Ma
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: