Jinja exceptions are not exposed in the user-facing CI log.
Pointed out by @cburr
Currently an exception raised by Jinja will appear in the CI as
INFO:Creating production B02DDbarKPi FATAL:Error creating production: Failed to create production for B02DDbarKPi WARN:not enough values to unpack (expected 7, got 5)
If one were to test locally they would see
Traceback (most recent call last): File "/miniconda/envs/analysis-productions/lib/python3.9/site-packages/LbAnalysisProductions/gitlab_runner.py", line 200, in create_productions production = Production.create( File "/miniconda/envs/analysis-productions/lib/python3.9/site-packages/LbAnalysisProductions/models/production.py", line 64, in create self.rendered_yaml = LbAPCommon.render_yaml(self.yaml) File "/miniconda/envs/analysis-productions/lib/python3.9/site-packages/LbAPCommon/parsing.py", line 187, in render_yaml rendered_yaml = jinja2.Template( File "/miniconda/envs/analysis-productions/lib/python3.9/site-packages/jinja2/environment.py", line 1291, in render self.environment.handle_exception() File "/miniconda/envs/analysis-productions/lib/python3.9/site-packages/jinja2/environment.py", line 925, in handle_exception raise rewrite_traceback_stack(source=source) File "<template>", line 132, in top-level template code ValueError: not enough values to unpack (expected 7, got 5)
which specifies the line causing the exception so is much more useful for a user to debug their YAML.
We should try have a message like
Exception running jinja2 templating on line 132 of xxx/yyy.yaml: ValueError: not enough values to unpack (expected 7, got 5)