Problem
ValidationErrors in pydantic provide information about the exception in a very structured way. This is nice, but printing the stack trace and the pseudocode related to the error is not a very good idea.
Expected behavior
Exploit the (well) formatted exception provided by pydantic and provide a concise string through the parser.error function, to exit gracefully, while both keeping the terminal clean and the user informed.
Problem ValidationErrors in
pydantic
provide information about the exception in a very structured way. This is nice, but printing the stack trace and the pseudocode related to the error is not a very good idea.Expected behavior Exploit the (well) formatted exception provided by pydantic and provide a concise string through the
parser.error
function, to exit gracefully, while both keeping the terminal clean and the user informed.