From: Dylan Anthony <43723790+dbanty@users.noreply.github.com> Date: Fri, 12 Jun 2020 20:44:40 +0000 (-0400) Subject: 🔇 Remove error log when parsing malformed JSON body as it's a client error (#1351) X-Git-Tag: 0.56.1~24 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2351fb5623b747f480d8c91af53dc7b3e9736e45;p=thirdparty%2Ffastapi%2Ffastapi.git 🔇 Remove error log when parsing malformed JSON body as it's a client error (#1351) --- diff --git a/fastapi/routing.py b/fastapi/routing.py index 3ac420e6e2..dab751a09e 100644 --- a/fastapi/routing.py +++ b/fastapi/routing.py @@ -179,7 +179,6 @@ def get_request_handler( if body_bytes: body = await request.json() except Exception as e: - logger.error(f"Error getting request body: {e}") raise HTTPException( status_code=400, detail="There was an error parsing the body" ) from e