Menu
Introduction
Getting Started
Developer guide
Release
Architecture
CLI
Technical documentations
Version
Publication date

Mar 9, 2022

Confidentiality
Public
Reactions
1
Share

ExceptionHandler

Class to handle exceptions and return a formatted object to the front

Functions
generate_instance_id @classmethod
Return type : str
handle_exception @classmethod
request : starlette.requests.Request | None
exception : Exception
Return type : ExceptionResponse
handle_request_validation_error @classmethod

Handle a RequestValidationError exception (error 422 Unprocessable Entity) It returns only the first message

exc : RequestValidationError
Shine Logo
Technical bricks to reuse or customize

Have you developed a brick?

Share it to accelerate projects for the entire community.