Ignore errors in exception handlers #1380

Closed
wants to merge 3 commits into
from

5 participants

@jeppenejsum
Lift Web Framework member

Ignore (but log) any errors that occur when running exception handlers and return an empty response instead.

Also, the default exceptionHandler no longer throws in prod mode if a file is uploaded which exceeds the limit.

jeppenejsum added some commits Dec 12, 2012
@jeppenejsum jeppenejsum Avoid exceptions in default error handler.
The toString method on Req will throw if it contains files that are too
large for the configured limits
13d1558
@jeppenejsum jeppenejsum Improve error handling in case exceptionHandlers throw.
Now any errors that occurs in exceptionHandlers are ignored (but
logged), instead returning an empty response
a43003f
@Shadowfiend
Lift Web Framework member

+1

@pbrant
Lift Web Framework member
@jeppenejsum
Lift Web Framework member

Thou shall not ignore errors in log files :-)

Currently you get the standard 404 page, but yes we could return something different?

@pbrant
Lift Web Framework member
@andreak
Lift Web Framework member
@Shadowfiend
Lift Web Framework member

I do agree that we should probably return a 500 error at that point.

@jeppenejsum
Lift Web Framework member

Ahhh, you're all right of course. Guess that's what happens when you try to be lazy :-) I'll make an update shortly

@fmpwizard
Lift Web Framework member

Rebased to master

@fmpwizard fmpwizard closed this Dec 14, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment