
    @wj                    T   d dl mZ d dlZd dlZd dlZd dlZd dlZd dlmZ  G d de	      Z
e
Ze
Ze
Ze
Ze
Ze
Ze
Zej$                  eeef   ZddZddZdddZ G d	 d
e      Z G d d      Z G d dej:                        Z	 d	 	 	 	 	 	 	 	 	 	 	 ddZ G d dej@                        Z y)    )annotationsN)Sequencec                      e Zd Zy)CryptographyDeprecationWarningN__name__
__module____qualname__     P/root/dashboard-youtube/.venv/lib/python3.12/site-packages/cryptography/utils.pyr   r          r   r   c                @    t        |t              st        |  d      y )Nz must be bytes)
isinstancebytes	TypeErrornamevalues     r   _check_bytesr   (   s#    eU#4&/00 $r   c                    t        |t        t        t        f      ry 	 t        |       y # t        $ r t	        |  d      w xY w)Nz must be bytes-like)r   r   	bytearray
memoryviewr   r   s     r   _check_bytesliker   -   sE    %%J7865 64& 34556s	   * Ac                ~    |dk(  rt        d      | j                  |xs | j                         dz   dz  xs dd      S )Nr   zlength argument can't be 0         big)
ValueErrorto_bytes
bit_length)integerlengths     r   int_to_bytesr%   6   sJ    {56667%%'!+16Q r   c                      e Zd Zy)InterfaceNotImplementedNr   r   r   r   r'   r'   >   r   r   r'   c                      e Zd ZddZy)_DeprecatedValuec                .    || _         || _        || _        y N)r   messagewarning_class)selfr   r,   r-   s       r   __init__z_DeprecatedValue.__init__C   s    
*r   N)r   objectr,   str)r   r	   r
   r/   r   r   r   r)   r)   B   s    +r   r)   c                  @     e Zd Zd fdZddZddZd	dZd
dZ xZS )_ModuleWithDeprecationsc                V    t         |   |j                         || j                  d<   y N_module)superr/   r   __dict__)r.   module	__class__s     r   r/   z _ModuleWithDeprecations.__init__J   s"    )#)i r   c                    t        | j                  |      }t        |t              r:t	        j
                  |j                  |j                  d       |j                  }|S || j                  |<   |S N   )
stacklevel)
getattrr6   r   r)   warningswarnr,   r-   r   r8   )r.   r   objs      r   __getattr__z#_ModuleWithDeprecations.__getattr__N   s\    dllD)c+,MM#++s'8'8QG))C 
 #&DMM$
r   c                    t        |t              r| j                  j                  |d        n|| j                  |<   t	        | j
                  ||       y r+   )r   r)   r8   popsetattrr6   )r.   attrr   s      r   __setattr__z#_ModuleWithDeprecations.__setattr__]   s?    e-.MMdD)"'DMM$dE*r   c                   t        | j                  |      }t        |t              r,t	        j
                  |j                  |j                  d       | j                  j                  |d        t        | j                  |       y r<   )r?   r6   r   r)   r@   rA   r,   r-   r8   rE   delattr)r.   rG   rB   s      r   __delattr__z#_ModuleWithDeprecations.__delattr__d   sY    dllD)c+,MM#++s'8'8QG$%d#r   c                2    dgt        | j                        S r5   )dirr6   r.   s    r   __dir__z_ModuleWithDeprecations.__dir__l   s    .C-..r   )r9   ztypes.ModuleType)r   r1   returnz
typing.Any)rG   r1   r   r0   rP   None)rG   r1   rP   rQ   )rP   zSequence[str])	r   r	   r
   r/   rC   rH   rK   rO   __classcell__)r:   s   @r   r3   r3   I   s    *+$/r   r3   c                    t         j                  |   }t        |t              st        |      xt         j                  |<   }t	        | ||      }|t        |||       |S r+   )sysmodulesr   r3   r)   rF   )r   module_namer,   r-   r   r9   dvs          r   
deprecatedrX   p   sZ     [[%Ff56,CF,KKK 6	%-	8Bb!Ir   c                      e Zd ZddZddZy)Enumc                j    d| j                   j                   d| j                   d| j                  dS )N<.z: >)r:   r   _name__value_rN   s    r   __repr__zEnum.__repr__   s1    4>>**+1T[[MDLL;K1MMr   c                L    | j                   j                   d| j                   S )Nr]   )r:   r   r_   rN   s    r   __str__zEnum.__str__   s"    ..))*!DKK=99r   N)rP   r1   )r   r	   r
   ra   rc   r   r   r   rZ   rZ      s    N:r   rZ   )r   r1   r   r   rP   rQ   )r   r1   r   BufferrP   rQ   r+   )r#   intr$   z
int | NonerP   r   )r   r0   rV   r1   r,   r1   r-   ztype[Warning]r   z
str | NonerP   r)   )!
__future__r   enumrT   typestypingr@   collections.abcr   UserWarningr   DeprecatedIn36DeprecatedIn40DeprecatedIn41DeprecatedIn42DeprecatedIn43DeprecatedIn47DeprecatedIn50Unionr   r   r   rd   r   r   r%   	Exceptionr'   r)   
ModuleTyper3   rX   rZ   r   r   r   <module>rv      s   
 #  
    $
	[ 	 0////// 
eY
2	31
6	i 	+ +$/e.. $/X   !	
  &:499 :r   