HEX
Server: LiteSpeed
System: Linux ws4.angoweb.net 5.14.0-611.13.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 11 04:57:59 EST 2025 x86_64
User: tswangoe (2287)
PHP: 8.1.33
Disabled: show_source, system, shell_exec, passthru, exec, phpinfo, popen, proc_open
Upload Files
File: //usr/local/lib/python3.9/site-packages/libpasteurize/fixes/__pycache__/fix_imports.cpython-39.pyc
a

q�dg��#@s�dZddlmZddlmZmZmZmZddlm	Z
ddlmZddl
mZmZddlmZdd	d
ddd
ddddddddddddddddddd d!d"d#d$d%d&d'd(d)d*�"Zd+Zd,Zd-Zd.Zd/Zd0Zd1Zd2Zd3Zd4Zd5d6�ZGd7d8�d8ej�Zd9S):z8
Fixer for standard library imports renamed in Python 3
�)�
fixer_base)�Name�is_probably_builtin�Newline�does_tree_import)�python_symbols)�token)�Node�Leaf��touch_import_top�repr�_winreg�ConfigParser�copy_regz"multiprocessing.queues.SimpleQueue�Queue�SocketServer�
markupbaseztest.test_support�dbhash�dbm�dumbdbm�gdbm�
HTMLParser�htmlentitydefs�httplib�Cookie�	cookielib�DialogZFixTk�ScrolledText�Tix�Tkconstants�Tkdnd�Tkinter�tkColorChooser�tkCommonDialog�tkFont�ttk�tkMessageBoxZturtle�robotparser�	xmlrpclib�__builtin__)"�reprlib�winreg�configparser�copyregzmultiprocessing.SimpleQueue�queue�socketserver�_markupbaseztest.supportzdbm.bsdzdbm.ndbmzdbm.dumbzdbm.gnuzhtml.parserz
html.entitieszhttp.clientzhttp.cookieszhttp.cookiejarztkinter.dialogztkinter._fixztkinter.scrolledtextztkinter.tixztkinter.constantsztkinter.dndztkinter.__init__ztkinter.colorchooserztkinter.commondialogztkinter.fontztkinter.ttkztkinter.messageboxztkinter.turtlezurllib.robotparserz
xmlrpc.client�builtinsz	name='%s'z	attr='%s'z$dotted_name=dotted_name< %s '.' %s >z%sz"power< %s trailer< '.' %s > any* >zpower< %s any* >z:from_import=import_from< 'from' %s 'import' imported=any >z�from_import_submod=import_from< 'from' %s 'import' (%s | import_as_name< %s 'as' renamed=any > | import_as_names< any* (%s | import_as_name< %s 'as' renamed=any >) any* > ) >zrname_import=import_name< 'import' %s > | name_import=import_name< 'import' dotted_as_name< %s 'as' renamed=any > >zAname_import=import_name< 'import' dotted_as_names< names=any* > >c
Cs�d|vr�|�dd�\}}t|}t|}t||f}t|}t|||||f}t||f}t||f}t|}	d�	|||||	f�St|}t||f}t|}t
|}d�	|||f�SdS)z�
    Accepts a string and returns a pattern of possible patterns involving that name
    Called by simple_mapping_to_pattern for each name in the mapping it receives.
    �.�� | 
N)�split�simple_name_match�
subname_match�dotted_name_match�from_import_match�from_import_submod_match�name_import_match�power_twoname_match�power_subname_match�join�power_onename_match)
�name�attrZsimple_nameZsimple_attrZdotted_nameZi_fromZ
i_from_submodZi_nameZu_nameZ	u_subname�rC�I/usr/local/lib/python3.9/site-packages/libpasteurize/fixes/fix_imports.py�all_patternsPs rEc@s6eZdZd�dd�eD��Zd�eef�Zdd�ZdS)�
FixImportsr5cCsg|]}t|��qSrC)rE)�.0rArCrCrD�
<listcomp>m�zFixImports.<listcomp>cCstdd|�dS)N�futureZstandard_libraryr)�self�node�resultsrCrCrD�	transformpszFixImports.transformN)�__name__�
__module__�__qualname__r?�MAPPINGZPATTERN�multiple_name_import_matchrNrCrCrCrDrFksrFN) �__doc__Zlib2to3rZlib2to3.fixer_utilrrrrZlib2to3.pygramrZsymsZ
lib2to3.pgen2rZlib2to3.pytreer	r
Zlibfuturize.fixer_utilrrRr7r8r9r@r=r>r:r;r<rSrEZBaseFixrFrCrCrCrD�<module>sj�-