You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a follow-on problem as a result of #1622 and its fix 3331ad7
In the highly unlikely event that send_as is called during the render of a template, the error Unable to load serializer class for plain: Can't locate Dancer2/Serializer/plain.pm will be experienced. This is because 3331ad7 removes the longjump when a template is processed, which means statements such as this do not return immediately, leading to unexpected behavior when the subsequent statements are executed.
The use-case here is for the Dancer2::Plugin::LogReport plugin, which (in the worst case scenario if can't do anything else) will render a plain text error if there is an unhandled exception when rendering a template.
I have a proposed solution which I will submit as a separate PR.
The text was updated successfully, but these errors were encountered:
abeverley
added a commit
to abeverley/Dancer2
that referenced
this issue
Jun 27, 2024
This is a follow-on problem as a result of #1622 and its fix 3331ad7
In the highly unlikely event that
send_as
is called during the render of a template, the errorUnable to load serializer class for plain: Can't locate Dancer2/Serializer/plain.pm
will be experienced. This is because 3331ad7 removes the longjump when a template is processed, which means statements such as this do not return immediately, leading to unexpected behavior when the subsequent statements are executed.The use-case here is for the
Dancer2::Plugin::LogReport
plugin, which (in the worst case scenario if can't do anything else) will render a plain text error if there is an unhandled exception when rendering a template.I have a proposed solution which I will submit as a separate PR.
The text was updated successfully, but these errors were encountered: