Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

无法生成word,模板有问题 #50

Open
unclebryan719 opened this issue Sep 29, 2021 · 0 comments
Open

无法生成word,模板有问题 #50

unclebryan719 opened this issue Sep 29, 2021 · 0 comments

Comments

@unclebryan719
Copy link

FTL stack trace ("~" means nesting-related):
- Failed at: #if description?trim?length gt 2 [in template "documentation_word.ftl" at line 20, column 4681]

at cn.smallbun.screw.core.util.ExceptionUtils.mpe(ExceptionUtils.java:62)
at cn.smallbun.screw.core.execute.DocumentationExecute.execute(DocumentationExecute.java:57)
at Generate.documentGeneration(Generate.java:102)
at Generate.main(Generate.java:27)

Caused by: cn.smallbun.screw.core.exception.ScrewException: freemarker.core.InvalidReferenceException: The following has evaluated to null or missing:
==> description [in template "documentation_word.ftl" at line 20, column 4686]


Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??


FTL stack trace ("~" means nesting-related):
- Failed at: #if description?trim?length gt 2 [in template "documentation_word.ftl" at line 20, column 4681]

at cn.smallbun.screw.core.util.ExceptionUtils.mpe(ExceptionUtils.java:62)
at cn.smallbun.screw.core.engine.freemark.FreemarkerTemplateEngine.produce(FreemarkerTemplateEngine.java:121)
at cn.smallbun.screw.core.execute.DocumentationExecute.execute(DocumentationExecute.java:53)
... 2 more

Caused by: freemarker.core.InvalidReferenceException: The following has evaluated to null or missing:
==> description [in template "documentation_word.ftl" at line 20, column 4686]


Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??


FTL stack trace ("~" means nesting-related):
- Failed at: #if description?trim?length gt 2 [in template "documentation_word.ftl" at line 20, column 4681]

at freemarker.core.InvalidReferenceException.getInstance(InvalidReferenceException.java:134)
at freemarker.core.EvalUtil.coerceModelToTextualCommon(EvalUtil.java:481)
at freemarker.core.EvalUtil.coerceModelToStringOrUnsupportedMarkup(EvalUtil.java:434)
at freemarker.core.Expression.evalAndCoerceToStringOrUnsupportedMarkup(Expression.java:139)
at freemarker.core.BuiltInForString.getTargetString(BuiltInForString.java:34)
at freemarker.core.BuiltInForString._eval(BuiltInForString.java:29)
at freemarker.core.Expression.eval(Expression.java:101)
at freemarker.core.Expression.evalAndCoerceToStringOrUnsupportedMarkup(Expression.java:139)
at freemarker.core.BuiltInForString.getTargetString(BuiltInForString.java:34)
at freemarker.core.BuiltInForString._eval(BuiltInForString.java:29)
at freemarker.core.Expression.eval(Expression.java:101)
at freemarker.core.EvalUtil.compare(EvalUtil.java:113)
at freemarker.core.ComparisonExpression.evalToBoolean(ComparisonExpression.java:78)
at freemarker.core.ConditionalBlock.accept(ConditionalBlock.java:48)
at freemarker.core.Environment.visit(Environment.java:334)
at freemarker.core.Environment.visit(Environment.java:340)
at freemarker.core.Environment.process(Environment.java:313)
at freemarker.template.Template.process(Template.java:383)
at cn.smallbun.screw.core.engine.freemark.FreemarkerTemplateEngine.produce(FreemarkerTemplateEngine.java:116)
... 3 more
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant