o
Mifz @ s8 d dl Z d dlmZ G dd deZG dd deZdS ) N) HTTPErrorc s e Zd ZdZ fddZ ZS )UnprocessableEntitya
An HTTP 422 Unprocessable Entity error occurred.
https://help.helpjuice.com/en_US/api-v3/api-v3#errors
The request could not be processed, usually due to a missing or invalid parameter.
The response will also include an error object with an explanation of fields that
are missing or invalid. Here is an example:
.. code-block::
HTTP/1.1 422 Unprocessable Entity
{
"errors": [
{
"email": "is not valid."
}
]
}
c s t tt|j }| }| D ]%\}}||d}|s#qt |t
r/|d|}qt |tr;| d| }qt
|}tt| j|||d dS )zUnprocessableEntity constructor.
Parses out error information from the error object and passes on to the
:obj:`HTTPError` constructor.
Args:
exc (:obj:`HTTPError`): Original exception.
Nr requestresponse)nextiterjsonloadsbodydecodevaluesitemsget
isinstancelistinsertstrdumpssuperr __init__) selfr r rq_jsonerrorsfielderrorrq_fieldmsg __class__ 0/home/shebes/code/rag_eval/src/errors/rag_err.pyr s
zUnprocessableEntity.__init__)__name__
__module____qualname____doc__r
__classcell__r! r! r r"