freemarker.template.TemplateException: Expected method. discount?string evaluated instead to freemarker.template.SimpleScalar on line 56, column 154 in WEB-INF/views/abc/abc-result.ftl.

Stack Overflow | Arjun Vinod | 2 months ago
tip
Do you find the tips below useful? Click on the to mark them and say thanks to rafael . Or join the community to write better ones.
  1. 0

    Error when using ?string("0.00") in FTL

    Stack Overflow | 2 months ago | Arjun Vinod
    freemarker.template.TemplateException: Expected method. discount?string evaluated instead to freemarker.template.SimpleScalar on line 56, column 154 in WEB-INF/views/abc/abc-result.ftl.
  2. 0
    samebug tip
    One of your fields was evaluated with NULL. If it's supposed to be NULL, follow the recommendations on the first line of the stack trace, otherwise, check why your code is setting this field to NULL.
  3. 0

    GitHub comment 97#35204329

    GitHub | 3 years ago | lefou
    org.jbake.template.RenderingException: freemarker.core.InvalidReferenceException: Expression post.date is undefined on line 29, column 20 in sitemap.ftl.
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    How to chunk List<Object> ?

    freemarker | 9 years ago | nobody
    freemarker.template.TemplateException: Expected hash. cell evaluated instead to freemarker.template.SimpleScalar on line 5, column 8 in test.ftl.
  6. 0

    Expression springMacroRequestContext is undefined

    Stack Overflow | 5 years ago | insomiac
    freemarker.core.InvalidReferenceException: Expression springMacroRequestContext is undefined on line 89, column 134 in spring.ftl.

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. freemarker.template.TemplateException

      Expected method. discount?string evaluated instead to freemarker.template.SimpleScalar on line 56, column 154 in WEB-INF/views/abc/abc-result.ftl.

      at freemarker.core.TemplateObject.invalidTypeException()
    2. FreeMarker
      Expression.getStringValue
      1. freemarker.core.TemplateObject.invalidTypeException(TemplateObject.java:136)[freemarker-2.3.19.jar:2.3.19]
      2. freemarker.core.MethodCall._getAsTemplateModel(MethodCall.java:114)[freemarker-2.3.19.jar:2.3.19]
      3. freemarker.core.Expression.getAsTemplateModel(Expression.java:89)[freemarker-2.3.19.jar:2.3.19]
      4. freemarker.core.Expression.getStringValue(Expression.java:93)[freemarker-2.3.19.jar:2.3.19]
      4 frames