In Discord, wallarug reported the following cookiecutter error:
The toJson is an expression inside the GitHub Actions workflow, used as such: ${{ toJson(blah) }}.
The Jinja2 parser is reading the {{ }} as a Jinja template expression, and obviously failing to execute it.
This fixes this by copying the workflow files in .github/ without sending them through the Jinja2 parser. I tested this locally, got no errors, and everything was rendered properly.
In Discord,
wallarug
reported the following cookiecutter error:The
toJson
is an expression inside the GitHub Actions workflow, used as such:${{ toJson(blah) }}
.The Jinja2 parser is reading the
{{ }}
as a Jinja template expression, and obviously failing to execute it.This fixes this by copying the workflow files in
.github/
without sending them through the Jinja2 parser. I tested this locally, got no errors, and everything was rendered properly.Uses:
_copy_without_render
.I really should've spotted this during the Actions PR review. I may have assumed that the
$
would keep Jinja from trying to parse it. 🤷♂