-
Bug
-
Resolution: Unresolved
-
Low
-
None
-
8.5.4, 7.19.17
-
2
-
Severity 3 - Minor
-
6
-
Issue Summary
This is reproducible on Data Center: Yes
Steps to Reproduce
- Browse to General Configuration > Global Templates and Blueprints > Add global page template
- Add any variable to the page and an empty HTML Macro.
- Save the template, and use it to create a new page.
Expected Results
You will see the editor and be able to use the template and create a new page.
Actual Results
You are brought to an error page, "Oops - an error has occurred". There is no stack trace on this page, but there is in the logs.
The below exception is thrown in the atlassian-confluence.log file:
2023-12-09 11:22:12,357 ERROR [http-nio-8090-exec-20] url: /pages/createpage-entervariables.action; user: admin] [apache.struts2.result.VelocityResult] doExecute Unable to render velocity template: '/pages/createpage-entervariables.vm' -- url: /pages/createpage-entervariables.action | userName: admin | action: createpage-entervariables | referer: https://test.confluence.com/dashboard.action | traceId: org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getRenderedTemplateContent' in class com.atlassian.confluence.pages.actions.PageVariablesAction threw exception java.lang.NullPointerException at /pages/createpage-entervariables.vm[line 19, column 51] at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:228) at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:262)
Workaround
Currently there is no known workaround for this behavior, but adding any content to the html macro resolves the issue.