Ë
    ,Œ:jÈ  ã                   ó  — d Z ddlZddlZej                  rddlmZm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 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/„ d0e«      Z G d1„ d2e«      Z G d3„ d4e«      Z  G d5„ d6e «      Z! G d7„ d8e «      Z" G d9„ d:e «      Z# G d;„ d<e «      Z$ejJ                  	 dAd=ejL                  d>   d?ejN                  d   fd@„«       Z(y)Bul  
Our exception hierarchy:

* HTTPError
  x RequestError
    + TransportError
      - TimeoutException
        Â· ConnectTimeout
        Â· ReadTimeout
        Â· WriteTimeout
        Â· PoolTimeout
      - NetworkError
        Â· ConnectError
        Â· ReadError
        Â· WriteError
        Â· CloseError
      - ProtocolError
        Â· LocalProtocolError
        Â· RemoteProtocolError
      - ProxyError
      - UnsupportedProtocol
    + DecodingError
    + TooManyRedirects
  x HTTPStatusError
* InvalidURL
* CookieConflict
* StreamError
  x StreamConsumed
  x StreamClosed
  x ResponseNotRead
  x RequestNotRead
é    Né   )ÚRequestÚResponsec                   ód   ‡ — e Zd ZdZdeddfˆ fd„Zedd„«       Zej                  d	d„«       Zˆ xZ	S )
Ú	HTTPErrora’  
    Base class for `RequestError` and `HTTPStatusError`.

    Useful for `try...except` blocks when issuing a request,
    and then calling `.raise_for_status()`.

    For example:

    ```
    try:
        response = httpx.get("https://www.example.com")
        response.raise_for_status()
    except httpx.HTTPError as exc:
        print(f"HTTP Exception for {exc.request.url} - {exc}")
    ```
    ÚmessageÚreturnNc                 ó2   •— t         ‰| �  |«       d | _        y ©N©ÚsuperÚ__init__Ú_request©Úselfr   Ú	__class__s     €úS/var/www/html/tokenscope/api/venv/lib/python3.12/site-packages/httpx/_exceptions.pyr   zHTTPError.__init__:   s   ø€ Ü‰Ñ˜Ô!Ø48ˆ�ó    c                 óH   — | j                   €t        d«      ‚| j                   S )Nz'The .request property has not been set.)r   ÚRuntimeError)r   s    r   ÚrequestzHTTPError.request>   s"   € à�=‰=Ð ÜÐHÓIÐIØ�}‰}Ðr   c                 ó   — || _         y r   )r   )r   r   s     r   r   zHTTPError.requestD   s	   € àˆ�r   )r	   r   )r   r   r	   N)
Ú__name__Ú
__module__Ú__qualname__Ú__doc__Ústrr   Úpropertyr   ÚsetterÚ__classcell__©r   s   @r   r   r   (   sG   ø„ ñð"9 ð 9¨õ 9ð òó ðð
 ‡^�^ò ó ô r   r   c                   óP   ‡ — e Zd ZdZddœdedej                  d   ddfˆ fd„Zˆ xZS )	ÚRequestErrorzS
    Base class for all exceptions that may occur when issuing a `.request()`.
    N)r   r   r   r   r	   c                ó2   •— t         ‰| �  |«       || _        y r   r   )r   r   r   r   s      €r   r   zRequestError.__init__N   s   ø€ ô 	‰Ñ˜Ô!ð  ˆ�r   )	r   r   r   r   r   ÚtypingÚOptionalr   r    r!   s   @r   r#   r#   I   s:   ø„ ñð
 FJò
 Øð
 Ø(.¯©¸	Ñ(Bð
 à	÷
 ñ 
 r   r#   c                   ó   — e Zd ZdZy)ÚTransportErrorzU
    Base class for all exceptions that occur at the level of the Transport API.
    N©r   r   r   r   © r   r   r(   r(   [   ó   „ òr   r(   c                   ó   — e Zd ZdZy)ÚTimeoutExceptionzM
    The base class for timeout errors.

    An operation has timed out.
    Nr)   r*   r   r   r-   r-   d   ó   „ òr   r-   c                   ó   — e Zd ZdZy)ÚConnectTimeoutz1
    Timed out while connecting to the host.
    Nr)   r*   r   r   r0   r0   l   r+   r   r0   c                   ó   — e Zd ZdZy)ÚReadTimeoutz7
    Timed out while receiving data from the host.
    Nr)   r*   r   r   r2   r2   r   r+   r   r2   c                   ó   — e Zd ZdZy)ÚWriteTimeoutz3
    Timed out while sending data to the host.
    Nr)   r*   r   r   r4   r4   x   r+   r   r4   c                   ó   — e Zd ZdZy)ÚPoolTimeoutzB
    Timed out waiting to acquire a connection from the pool.
    Nr)   r*   r   r   r6   r6   ~   r+   r   r6   c                   ó   — e Zd ZdZy)ÚNetworkErrorzo
    The base class for network-related errors.

    An error occurred while interacting with the network.
    Nr)   r*   r   r   r8   r8   ‡   r.   r   r8   c                   ó   — e Zd ZdZy)Ú	ReadErrorz2
    Failed to receive data from the network.
    Nr)   r*   r   r   r:   r:   �   r+   r   r:   c                   ó   — e Zd ZdZy)Ú
WriteErrorz2
    Failed to send data through the network.
    Nr)   r*   r   r   r<   r<   •   r+   r   r<   c                   ó   — e Zd ZdZy)ÚConnectErrorz+
    Failed to establish a connection.
    Nr)   r*   r   r   r>   r>   ›   r+   r   r>   c                   ó   — e Zd ZdZy)Ú
CloseErrorz'
    Failed to close a connection.
    Nr)   r*   r   r   r@   r@   ¡   r+   r   r@   c                   ó   — e Zd ZdZy)Ú
ProxyErrorzB
    An error occurred while establishing a proxy connection.
    Nr)   r*   r   r   rB   rB   ª   r+   r   rB   c                   ó   — e Zd ZdZy)ÚUnsupportedProtocolz€
    Attempted to make a request to an unsupported protocol.

    For example issuing a request to `ftp://www.example.com`.
    Nr)   r*   r   r   rD   rD   °   r.   r   rD   c                   ó   — e Zd ZdZy)ÚProtocolErrorz$
    The protocol was violated.
    Nr)   r*   r   r   rF   rF   ¸   r+   r   rF   c                   ó   — e Zd ZdZy)ÚLocalProtocolErrorzæ
    A protocol was violated by the client.

    For example if the user instantiated a `Request` instance explicitly,
    failed to include the mandatory `Host:` header, and then issued it directly
    using `client.send()`.
    Nr)   r*   r   r   rH   rH   ¾   s   „ òr   rH   c                   ó   — e Zd ZdZy)ÚRemoteProtocolErrorz^
    The protocol was violated by the server.

    For example, returning malformed HTTP.
    Nr)   r*   r   r   rJ   rJ   È   r.   r   rJ   c                   ó   — e Zd ZdZy)ÚDecodingErrorzG
    Decoding of the response failed, due to a malformed encoding.
    Nr)   r*   r   r   rL   rL   Ó   r+   r   rL   c                   ó   — e Zd ZdZy)ÚTooManyRedirectsz
    Too many redirects.
    Nr)   r*   r   r   rN   rN   Ù   r+   r   rN   c                   ó4   ‡ — e Zd ZdZdeddddddfˆ fd	„Zˆ xZS )
ÚHTTPStatusErrorz|
    The response had an error HTTP status of 4xx or 5xx.

    May be raised when calling `response.raise_for_status()`
    r   r   r   Úresponser   r	   Nc                ó@   •— t         ‰| �  |«       || _        || _        y r   )r   r   r   rQ   )r   r   r   rQ   r   s       €r   r   zHTTPStatusError.__init__é   s    ø€ ô 	‰Ñ˜Ô!ØˆŒØ ˆ�r   ©r   r   r   r   r   r   r    r!   s   @r   rP   rP   â   s2   ø„ ñð!Øð!Ø(1ð!Ø=Gð!à	÷!ñ !r   rP   c                   ó,   ‡ — e Zd ZdZdeddfˆ fd„Zˆ xZS )Ú
InvalidURLz7
    URL is improperly formed or cannot be parsed.
    r   r	   Nc                 ó$   •— t         ‰| �  |«       y r   ©r   r   r   s     €r   r   zInvalidURL.__init__ö   ó   ø€ Ü‰Ñ˜Õ!r   rS   r!   s   @r   rU   rU   ñ   s    ø„ ñð" ð "¨÷ "ñ "r   rU   c                   ó,   ‡ — e Zd ZdZdeddfˆ fd„Zˆ xZS )ÚCookieConflictz†
    Attempted to lookup a cookie by name, but multiple cookies existed.

    Can occur when calling `response.cookies.get(...)`.
    r   r	   Nc                 ó$   •— t         ‰| �  |«       y r   rW   r   s     €r   r   zCookieConflict.__init__  rX   r   rS   r!   s   @r   rZ   rZ   ú   s    ø„ ñð" ð "¨÷ "ñ "r   rZ   c                   ó,   ‡ — e Zd ZdZdeddfˆ fd„Zˆ xZS )ÚStreamErrorz‡
    The base class for stream exceptions.

    The developer made an error in accessing the request stream in
    an invalid way.
    r   r	   Nc                 ó$   •— t         ‰| �  |«       y r   rW   r   s     €r   r   zStreamError.__init__  rX   r   rS   r!   s   @r   r]   r]     s    ø„ ñð" ð "¨÷ "ñ "r   r]   c                   ó$   ‡ — e Zd ZdZdˆ fd„Zˆ xZS )ÚStreamConsumedz]
    Attempted to read or stream content, but the content has already
    been streamed.
    c                 ó(   •— d}t         ‰| �  |«       y )Na]  Attempted to read or stream some content, but the content has already been streamed. For requests, this could be due to passing a generator as request content, and then receiving a redirect response or a secondary request as part of an authentication flow.For responses, this could be due to attempting to stream the response content more than once.rW   r   s     €r   r   zStreamConsumed.__init__  s   ø€ ð&ð 	ô 	‰Ñ˜Õ!r   ©r	   N©r   r   r   r   r   r    r!   s   @r   r`   r`     s   ø„ ñ÷
	"ñ 	"r   r`   c                   ó$   ‡ — e Zd ZdZdˆ fd„Zˆ xZS )ÚStreamClosedz\
    Attempted to read or stream response content, but the request has been
    closed.
    c                 ó(   •— d}t         ‰| �  |«       y )NzDAttempted to read or stream content, but the stream has been closed.rW   r   s     €r   r   zStreamClosed.__init__/  s   ø€ àUð 	ô 	‰Ñ˜Õ!r   rb   rc   r!   s   @r   re   re   )  s   ø„ ñ÷
"ñ "r   re   c                   ó$   ‡ — e Zd ZdZdˆ fd„Zˆ xZS )ÚResponseNotReadzY
    Attempted to access streaming response content, without having called `read()`.
    c                 ó(   •— d}t         ‰| �  |«       y )NzOAttempted to access streaming response content, without having called `read()`.rW   r   s     €r   r   zResponseNotRead.__init__;  s   ø€ ØcˆÜ‰Ñ˜Õ!r   rb   rc   r!   s   @r   rh   rh   6  ó   ø„ ñ÷"ñ "r   rh   c                   ó$   ‡ — e Zd ZdZdˆ fd„Zˆ xZS )ÚRequestNotReadzX
    Attempted to access streaming request content, without having called `read()`.
    c                 ó(   •— d}t         ‰| �  |«       y )NzNAttempted to access streaming request content, without having called `read()`.rW   r   s     €r   r   zRequestNotRead.__init__E  s   ø€ ØbˆÜ‰Ñ˜Õ!r   rb   rc   r!   s   @r   rl   rl   @  rj   r   rl   r   r   r	   c              #   óN   K  — 	 d–— y# t         $ r}| �| |_        |‚d}~ww xY w­w)z—
    A context manager that can be used to attach the given request context
    to any `RequestError` exceptions that are raised within the block.
    N)r#   r   )r   Úexcs     r   Úrequest_contextrp   J  s/   è ø€ ðÜøÜò ØÐØ!ˆCŒKØˆ	ûðüs   ‚%„	 ˆ%‰	"’�"¢%r   ))r   Ú
contextlibr%   ÚTYPE_CHECKINGÚ_modelsr   r   Ú	Exceptionr   r#   r(   r-   r0   r2   r4   r6   r8   r:   r<   r>   r@   rB   rD   rF   rH   rJ   rL   rN   rP   rU   rZ   r   r]   r`   re   rh   rl   Úcontextmanagerr&   ÚIteratorrp   r*   r   r   ú<module>rw      s³  ðñó@ Û à	×Òß*ô �	ô  ôB �9ô  ô$�\ô ô�~ô ôÐ%ô ôÐ"ô ôÐ#ô ôÐ"ô ô�>ô ô�ô ô�ô ô�<ô ô�ô ô�ô ô˜.ô ô�Nô ô˜ô ô˜-ô ô�Lô ô�|ô ô!�iô !ô"�ô "ô"�Yô "ô"	"�,ô 	"ô"�[ô "ô$
"�;ô 
"ô"�kô "ô"�[ô "ð ×Ñà*.ñØ�_‰_˜YÑ'ðà‡_�_�TÑòó ñr   