We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When calling other macros within an imported macro, it has been observed that the calls do not execute as intended.
common.tpl
{% macro inner_test() export %}innertest{% endmacro %} {% macro outter_test() export %} outtertest begin {{ inner_test() }} outtertest end {% endmacro %} {{outter_test()}}
Macros calls are executed correctly
> p2 -t common.tpl outtertest begin innertest outtertest end
Create another template and import the outter_test macro test.txt .
test.txt
begin {% import "common.tpl" outter_test %}{{outter_test()}} end
Render test.txt, the contents of inner_test() are missing.
> p2 -t test.txt begin outtertest begin outtertest end end
The text was updated successfully, but these errors were encountered:
This is a flaw in the underlying pongo2 library, which is what implements templating.
Sorry, something went wrong.
No branches or pull requests
Problem Description
When calling other macros within an imported macro, it has been observed that the calls do not execute as intended.
Environment
Reproduce
common.tpl
Macros calls are executed correctly
> p2 -t common.tpl outtertest begin innertest outtertest end
Create another template and import the outter_test macro
test.txt
.Render test.txt, the contents of inner_test() are missing.
> p2 -t test.txt begin outtertest begin outtertest end end
The text was updated successfully, but these errors were encountered: