hug icon indicating copy to clipboard operation
hug copied to clipboard

Add exception in not_found router

Open ptitpoulpe opened this issue 3 years ago • 0 comments

Issue

Currently, if an endpoint raised a HTTPNotFound exception it’s catched (see here), so you cannot have custom HTTPNotFound exception.

Solution

Pass the exception to not_found handlers so they can use the raised HTTPNotFound exception to generate not found message.

ptitpoulpe avatar Jun 14 '21 14:06 ptitpoulpe