[Koha-bugs] [Bug 26048] PSGI Koha does not use custom ErrorDocument pages

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Sun Jan 24 23:50:06 CET 2021


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26048

--- Comment #29 from David Cook <dcook at prosentient.com.au> ---
(In reply to Fridolin Somers from comment #27)
> If only we could find a way to display the error in 500.pl.
> Would be so useful for support.

The errors should still be in your web server logs. See
https://metacpan.org/release/Plack/source/lib/Plack/Middleware/HTTPExceptions.pm#L63

In terms of displaying on the screen, we could probably do it a number of ways. 

For instance, we could do our own middleware to catch errors and then throw a
HTTP::Exception and let Plack::Middleware::HTTPException handle it. 

Or we could replace HTTPException with our own middleware which sets an
environmental variable that we then print in the subrequest done by
ErrorDocument. 

Or we could replace both HTTPException and ErrorDocument with a middleware that
renders the template we want and shows the message we want. It wouldn't be very
hard.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list