Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Critical
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 1.4-M1
-
Component/s: None
-
Labels:None
Description
The problem is that the ErrorHandlingServlet uses and include and manual invocation of sitemesh. This means that any request parameters set during the error handling action (including request scoped beans) are not available when applying the layout to the returned view. This is incorrect because it is different to how layouts usually work with normal (i.e. non error-handling) actions/views.
I am going to release a plugin to backport a fix to the 1.3 line (link will be in comments once released) as this is too big a change to make on that branch. The plugin will inform the eventual changes for 1.4.
The solution involves configuring the sitemesh filter to apply to error dispatching, and to use a forward instead of an include to invoke the error handler.
Issue Links
- is related to
-
GRAILS-8904
GSP layout applied twice when rendering view after a 404 error
-
-
GRAILS-6987
Exceptions thrown during exception handlers cause exception to be logged in GrailsDispatcherServlet about no thread bound request
-
To fix this in versions of Grails prior to 1.4, install the ?error-pages-fix? plugin.
See: https://github.com/alkemist/grails-error-pages-fix