
    0j                       d dl mZ d dlmZ d dlZg dZ G d de          Z G d de          Z G d	 d
e          Z	 G d de          Z
 G d de          Z G d de          Z G d de
          Z G d de
          Z G d de
          Z G d de
          Z G d de
          Z G d de
          Z G d de
          Z G d d e
          ZdS )!    )annotations)LiteralN)BadRequestErrorAuthenticationErrorPermissionDeniedErrorNotFoundErrorConflictErrorUnprocessableEntityErrorRateLimitErrorInternalServerErrorc                      e Zd ZdS )ParallelErrorN__name__
__module____qualname__     \/home/rurouni/.hermes/hermes-agent/venv/lib/python3.11/site-packages/parallel/_exceptions.pyr   r              Dr   r   c                  B     e Zd ZU ded<   ded<   ded<   	 d
 fd	Z xZS )APIErrorstrmessagehttpx.Requestrequestobject | NonebodyreturnNonec               t    t                                          |           || _        || _        || _        d S )N)super__init__r   r   r   )selfr   r   r   	__class__s       r   r#   zAPIError.__init__(   s4    !!!			r   )r   r   r   r   r   r   r   r    r   r   r   __annotations__r#   __classcell__r%   s   @r   r   r      se         LLL         r   r   c                  <     e Zd ZU ded<   ded<   ddd fdZ xZS )APIResponseValidationErrorhttpx.Responseresponseintstatus_codeNr   r   r   r   
str | Noner   r    c                   t                                          |pd|j        |           || _        |j        | _        d S )Nz1Data returned by API invalid for expected schema.r   r"   r#   r   r-   r/   )r$   r-   r   r   r%   s       r   r#   z#APIResponseValidationError.__init__3   sE    W$WYaYiptuuu #/r   )r-   r,   r   r   r   r1   r   r    r&   r)   s   @r   r+   r+   /   sd         _c 0 0 0 0 0 0 0 0 0 0 0 0r   r+   c                  :     e Zd ZU dZded<   ded<   d fdZ xZS )APIStatusErrorz<Raised when an API response has a status code of 4xx or 5xx.r,   r-   r.   r/   r   r   r   r   r   r    c                   t                                          ||j        |           || _        |j        | _        d S Nr3   r4   )r$   r   r-   r   r%   s       r   r#   zAPIStatusError.__init__?   s=    ("2>>> #/r   )r   r   r-   r,   r   r   r   r    )r   r   r   __doc__r'   r#   r(   r)   s   @r   r6   r6   9   s]         FF0 0 0 0 0 0 0 0 0 0r   r6   c                  &     e Zd Zddd
 fd	Z xZS )APIConnectionErrorzConnection error.r0   r   r   r   r   r   r    c               P    t                                          ||d            d S r8   r"   r#   )r$   r   r   r%   s      r   r#   zAPIConnectionError.__init__F   s(    '55555r   )r   r   r   r   r   r    r   r   r   r#   r(   r)   s   @r   r;   r;   E   sJ        )< 6 6 6 6 6 6 6 6 6 6 6 6r   r;   c                        e Zd Zd fdZ xZS )APITimeoutErrorr   r   r   r    c                N    t                                          d|           d S )NzRequest timed out.)r   r   r=   )r$   r   r%   s     r   r#   zAPITimeoutError.__init__K   s'    !5wGGGGGr   )r   r   r   r    r>   r)   s   @r   r@   r@   J   sG        H H H H H H H H H Hr   r@   c                      e Zd ZU dZded<   dS )r   i  zLiteral[400]r/   Nr   r   r   r/   r'   r   r   r   r   r   O   #          #K######r   r   c                      e Zd ZU dZded<   dS )r   i  zLiteral[401]r/   NrC   r   r   r   r   r   S   rD   r   r   c                      e Zd ZU dZded<   dS )r   i  zLiteral[403]r/   NrC   r   r   r   r   r   W   rD   r   r   c                      e Zd ZU dZded<   dS )r   i  zLiteral[404]r/   NrC   r   r   r   r   r   [   rD   r   r   c                      e Zd ZU dZded<   dS )r	   i  zLiteral[409]r/   NrC   r   r   r   r	   r	   _   rD   r   r	   c                      e Zd ZU dZded<   dS )r
   i  zLiteral[422]r/   NrC   r   r   r   r
   r
   c   rD   r   r
   c                      e Zd ZU dZded<   dS )r   i  zLiteral[429]r/   NrC   r   r   r   r   r   g   rD   r   r   c                      e Zd ZdS )r   Nr   r   r   r   r   r   k   r   r   r   )
__future__r   typing_extensionsr   httpx__all__	Exceptionr   r   r+   r6   r;   r@   r   r   r   r   r	   r
   r   r   r   r   r   <module>rQ      s   # " " " " " % % % % % % 	 	 		 	 	 	 	I 	 	 	    }   ,0 0 0 0 0 0 0 0	0 	0 	0 	0 	0X 	0 	0 	06 6 6 6 6 6 6 6
H H H H H( H H H
$ $ $ $ $n $ $ $$ $ $ $ $. $ $ $$ $ $ $ $N $ $ $$ $ $ $ $N $ $ $$ $ $ $ $N $ $ $$ $ $ $ $~ $ $ $$ $ $ $ $^ $ $ $	 	 	 	 	. 	 	 	 	 	r   