From 976cd84960f994d03526f63ffe59feb626c202ff Mon Sep 17 00:00:00 2001 From: Matteo Campinoti Date: Tue, 24 Sep 2024 10:27:26 +0200 Subject: [PATCH] main - handle faapi.exceptions.NotFound explicitly --- app/main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/app/main.py b/app/main.py index f8d7306..5d2553e 100644 --- a/app/main.py +++ b/app/main.py @@ -118,6 +118,7 @@ def handle_notice_message(_request: Request, err: Exception | faapi.exceptions.P # noinspection PyTypeChecker @app.exception_handler(faapi.exceptions.ServerError) @app.exception_handler(faapi.exceptions.DisabledAccount) +@app.exception_handler(faapi.exceptions.NotFound) def handle_server_error(_request: Request, err: faapi.exceptions.ParsingError): return handle_http_exception(_request, NotFound([err.__class__.__name__, *err.args[0:1]]))