Bugfix
Detail
#28141
Rendering safety: Subsequent errors after error handling of errors in template variables
If an error occurs in a template variable, it is intercepted correctly since #28089, but the subsequent rendering crashes if the template variable was evaluated in an attribute, for example. The error handling closes all open tags, but the following code does not expect this and runs into an error from the tl:TagWriter due to invalid nesting (a tag is closed although no tag is currently open.
Solution
Only handle errors if the context is inside an element. Instead, introduce additional error handling when rendering tags from templates.
Test
No test.