From 851133ff0635521265bdd80f019042cf14e9a93a Mon Sep 17 00:00:00 2001 From: Julien Castiaux Date: Thu, 28 Mar 2024 13:19:21 +0100 Subject: [PATCH] [FIX] core: NotFound error without warning The conditionnal `isinstance(exc, NotFound)` is shadowed by the conditionnal `isinstance(exc, HTTPException)` two lines above. Nobody ever complained that the warning for NotFound error was gone. Since werkzeug 1.0.0, the status code in the response log is colored, 404 is colored yellow which should catch the eye. The explicit warning line isn't really necessary. closes odoo/odoo#159895 X-original-commit: 851b91f19b87446662421cb8d801a9472725bc72 Signed-off-by: Julien Castiaux (juc) --- odoo/http.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/odoo/http.py b/odoo/http.py index 3da421e8df0..b7d65862861 100644 --- a/odoo/http.py +++ b/odoo/http.py @@ -2205,7 +2205,7 @@ class Application: pass elif isinstance(exc, SessionExpiredException): _logger.info(exc) - elif isinstance(exc, (UserError, AccessError, NotFound)): + elif isinstance(exc, (UserError, AccessError)): _logger.warning(exc) else: _logger.error("Exception during request handling.", exc_info=True)