Your IP : 3.144.37.178


Current Path : /opt/alt/python310/lib64/python3.10/importlib/__pycache__/
Upload File :
Current File : //opt/alt/python310/lib64/python3.10/importlib/__pycache__/_bootstrap.cpython-310.opt-2.pyc

o

6��f���@s�	dd�ZdZdZdZdadd�Zdd�ZiZiZGdd�de	�Z
Gd	d
�d
�ZGdd�d�ZGd
d�d�Z
dd�Zdd�Zdd�Zdd�dd�Zdd�Zdd�Zdd�Zdd �ZGd!d"�d"�Zddd#�d$d%�Zd_d&d'�Zd(d)�d*d+�Zd,d-�Zd.d/�Zd0d1�Zd2d3�Zd4d5�Zd6d7�ZGd8d9�d9�Z Gd:d;�d;�Z!Gd<d=�d=�Z"d>d?�Z#d@dA�Z$d`dBdC�Z%dDdE�Z&dFZ'e'dGZ(dHdI�Z)e*�Z+dJdK�Z,dadMdN�Z-d(dO�dPdQ�Z.dRdS�Z/dbdUdV�Z0dWdX�Z1dYdZ�Z2d[d\�Z3d]d^�Z4dS)ccCs&z|jWStyt|�jYSw�N)�__qualname__�AttributeError�type)�obj�r�;/opt/alt/python310/lib64/python3.10/importlib/_bootstrap.py�_object_names
�rNcCs:	dD]}t||�rt||t||��q|j�|j�dS)N)�
__module__�__name__r�__doc__)�hasattr�setattr�getattr�__dict__�update)�new�old�replacerrr�_wrap(s
�rcCstt�|�Sr)r�sys��namerrr�_new_module0src@seZdZdS)�_DeadlockErrorN)r
r	rrrrrr=src@s6eZdZ	dd�Zdd�Zdd�Zdd�Zd	d
�ZdS)�_ModuleLockcCs0t��|_t��|_||_d|_d|_d|_dS�N�)�_thread�
allocate_lock�lock�wakeupr�owner�count�waiters��selfrrrr�__init__Gs


z_ModuleLock.__init__cCsVt��}|j}t�}	t�|�}|durdS|j}||krdS||vr%dS|�|�q)NTF)r�	get_identr!�set�_blocking_on�get�add)r%�me�tid�seenrrrr�has_deadlockOs

�z_ModuleLock.has_deadlockcCs�	t��}|t|<zW	|j�@|jdks|j|kr0||_|jd7_	Wd�Wt|=dS|��r:td|��|j�	d�rG|j
d7_
Wd�n1sQwY|j�	�|j��qt|=w)NTr�zdeadlock detected by %rF)rr'r)rr"r!r/rr �acquirer#�release�r%r-rrrr1ds,�

���


�z_ModuleLock.acquirecCs�t��}|j�@|j|krtd��|jd8_|jdkr7d|_|jr?|jd8_|j��Wd�dSWd�dSWd�dS1sJwYdS)N�cannot release un-acquired lockr0r)	rr'rr!�RuntimeErrorr"r#r r2r3rrrr2}s

��"�z_ModuleLock.releasecC�d�|jt|��S)Nz_ModuleLock({!r}) at {}��formatr�id�r%rrr�__repr__��z_ModuleLock.__repr__N)r
r	rr&r/r1r2r;rrrrrAs
rc@s.eZdZ	dd�Zdd�Zdd�Zdd�Zd	S)
�_DummyModuleLockcCs||_d|_dSr)rr"r$rrrr&��
z_DummyModuleLock.__init__cCs|jd7_dS)Nr0T)r"r:rrrr1�sz_DummyModuleLock.acquirecCs$|jdkr	td��|jd8_dS)Nrr4r0)r"r5r:rrrr2�s
z_DummyModuleLock.releasecCr6)Nz_DummyModuleLock({!r}) at {}r7r:rrrr;�r<z_DummyModuleLock.__repr__N)r
r	rr&r1r2r;rrrrr=�sr=c@s$eZdZdd�Zdd�Zdd�ZdS)�_ModuleLockManagercCs||_d|_dSr)�_name�_lockr$rrrr&�r>z_ModuleLockManager.__init__cCst|j�|_|j��dSr)�_get_module_lockr@rAr1r:rrr�	__enter__�sz_ModuleLockManager.__enter__cOs|j��dSr)rAr2)r%�args�kwargsrrr�__exit__�sz_ModuleLockManager.__exit__N)r
r	rr&rCrFrrrrr?�sr?cCs�	t��z@zt|�}Wntyd}Ynw|dur?tdur&t|�}nt|�}|fdd�}t�||�t|<Wt�	�|SWt�	�|St�	�w)NcSsDt��zt�|�|urt|=Wt��dSWt��dSt��wr)�_imp�acquire_lock�
_module_locksr*�release_lock)�refrrrr�cb�s�z_get_module_lock.<locals>.cb)
rGrHrI�KeyErrorrr=r�_weakrefrKrJ)rrrLrrrrB�s(�
�
�rBcCs8	t|�}z|��Wn
tyYdSw|��dSr)rBr1rr2)rrrrr�_lock_unlock_module�s�rOcOs	||i|��Srr)�frD�kwdsrrr�_call_with_frames_removed�srRr0)�	verbositycGs<	tjj|kr|�d�sd|}t|j|�tjd�dSdS)N)�#zimport z# )�file)r�flags�verbose�
startswith�printr8�stderr)�messagerSrDrrr�_verbose_message�s
�r\c�	�fdd�}t|��|S)Ncs&|tjvrtd�|�|d���||�S�Nz{!r} is not a built-in moduler)r�builtin_module_names�ImportErrorr8�r%�fullname��fxnrr�_requires_builtin_wrapper��


�
z4_requires_builtin.<locals>._requires_builtin_wrapper�r)rdrerrcr�_requires_builtin��
rhcr])Ncs&t�|�std�|�|d���||�S�Nz{!r} is not a frozen moduler)rG�	is_frozenr`r8rarcrr�_requires_frozen_wrapper	rfz2_requires_frozen.<locals>._requires_frozen_wrapperrg)rdrlrrcr�_requires_frozenrirmcCsL	d}t�|t�t||�}|tjvr"tj|}t||�tj|St|�S)Nzgthe load_module() method is deprecated and slated for removal in Python 3.12; use exec_module() instead)�	_warnings�warn�DeprecationWarning�spec_from_loaderr�modules�_exec�_load)r%rb�msg�spec�modulerrr�_load_module_shims




rxcCs�	t|dd�}t|dd�}rt|�St|d�r(z|�|�WSty'Ynwz|j}Wnty8d}Ynwz|j}WntyX|durPd�|�YSd�||�YSwd�||�S)N�
__loader__�__spec__�module_repr�?�
<module {!r}>�<module {!r} ({!r})>�<module {!r} from {!r}>)	r�_module_repr_from_specrr{�	Exceptionr
r�__file__r8)rw�loaderrvr�filenamerrr�_module_repr&s.
�
�
�r�c@speZdZ	dddd�dd�Zdd�Zdd�Zed	d
��Zejdd
��Zedd
��Z	edd��Z
e
jdd��Z
dS)�
ModuleSpecN)�origin�loader_state�
is_packagecCs6||_||_||_||_|rgnd|_d|_d|_dS�NF)rr�r�r��submodule_search_locations�
_set_fileattr�_cached)r%rr�r�r�r�rrrr&es
zModuleSpec.__init__cCsfd�|j�d�|j�g}|jdur|�d�|j��|jdur(|�d�|j��d�|jjd�|��S)Nz	name={!r}zloader={!r}zorigin={!r}zsubmodule_search_locations={}z{}({})z, )	r8rr�r��appendr��	__class__r
�join)r%rDrrrr;qs

�

�zModuleSpec.__repr__cCsf|j}z$|j|jko&|j|jko&|j|jko&||jko&|j|jko&|j|jkWSty2tYSwr)r�rr�r��cached�has_locationr�NotImplemented)r%�other�smslrrr�__eq__{s 
�
��
�
��zModuleSpec.__eq__cCs:|jdur|jdur|jrtdurt�t�|j�|_|jSr)r�r�r��_bootstrap_external�NotImplementedError�_get_cachedr:rrrr��s
zModuleSpec.cachedcCs
||_dSr)r�)r%r�rrrr��s
cCs"	|jdur|j�d�dS|jS)N�.r)r�r�
rpartitionr:rrr�parent�s
zModuleSpec.parentcCs|jSr)r�r:rrrr��szModuleSpec.has_locationcCst|�|_dSr)�boolr�)r%�valuerrrr��s)r
r	rr&r;r��propertyr��setterr�r�rrrrr�@s"$�




r��r�r�cCs�	t|d�r&tdurt�tj}|dur|||d�S|rgnd}||||d�S|durDt|d�rBz|�|�}Wn
tyAd}Ynwd}t||||d�S)N�get_filename)r�)r�r�r�Fr�)rr�r��spec_from_file_locationr�r`r�)rr�r�r�r��searchrrrrq�s(
�
�rqcCs&z|j}Wn	tyYnw|dur|S|j}|dur+z|j}Wn	ty*Ynwz|j}Wnty;d}Ynw|durW|durUz|j}Wn
tyTd}Ynw|}z|j}Wntygd}Ynwzt|j�}Wntyzd}Ynwt	|||d�}|dur�dnd|_
||_||_|S)N�r�FT)
rzrr
ryr��_ORIGIN�
__cached__�list�__path__r�r�r�r�)rwr�r�rvr�locationr�r�rrr�_spec_from_module�sT
�
�
�
�
��r�F��overridecCs�|s
t|dd�durz|j|_Wn	tyYnw|s$t|dd�durW|j}|durH|jdurHtdur6t�tj}|�	|�}|j|_
||_d|_z||_Wn	tyVYnw|sat|dd�durqz|j
|_Wn	typYnwz||_Wn	tyYnw|s�t|dd�dur�|jdur�z|j|_Wn	ty�Ynw|jr�|s�t|dd�dur�z|j|_Wn	ty�Ynw|s�t|dd�dur�|jdur�z|j|_W|Sty�Y|Sw|S)Nr
ry�__package__r�r�r�)rrr
rr�r�r�r��_NamespaceLoader�__new__�_pathr�ryr�r�rzr�r�r�r�r�)rvrwr�r�r�rrr�_init_module_attrs�sr�


��
�
��

��r�cCsT	d}t|jd�r|j�|�}n
t|jd�rtd��|dur#t|j�}t||�|S)N�
create_module�exec_modulezBloaders that define exec_module() must also define create_module())rr�r�r`rrr��rvrwrrr�module_from_spec4s

r�cCsf	|jdurdn|j}|jdur!|jdurd�|�Sd�||j�S|jr+d�||j�Sd�|j|j�S)Nr|r}r~r�<module {!r} ({})>)rr�r�r8r�)rvrrrrr�Es


r�c
Cs	|j}t|��{tj�|�|urd�|�}t||d��zP|jdur6|jdur.td|jd��t	||dd�n(t	||dd�t
|jd�sXt|j��d�}t�
|t�|j�|�n|j�|�Wtj�|j�}|tj|j<ntj�|j�}|tj|j<wWd�|S1s�wY|S)Nzmodule {!r} not in sys.modulesr�missing loaderTr�r��7.exec_module() not found; falling back to load_module())rr?rrrr*r8r`r�r�r�rrrnro�
ImportWarning�load_moduler��pop)rvrwrrurrrrsVs4



��
��rscCsz	|j�|j�Wn|jtjvr tj�|j�}|tj|j<�tj�|j�}|tj|j<t|dd�durFz|j|_Wn	tyEYnwt|dd�durlz|j	|_
t|d�sa|j�d�d|_
Wn	tykYnwt|dd�dur�z||_
W|Sty�Y|Sw|S)Nryr�r�r�rrz)r�r�rrrrr�rryrr
r�rr�rzr�rrr�_load_backward_compatibletsB�
����r�cCs�|jdurt|jd�st|j��d�}t�|t�t|�St|�}d|_zP|t	j
|j<z|jdur>|jdur=t
d|jd��n|j�|�Wnzt	j
|j=W�tyYY�wt	j
�|j�}|t	j
|j<td|j|j�Wd|_|Sd|_w)Nr�r�Tr�rzimport {!r} # {!r}F)r�rrrnror�r�r��
_initializingrrrrr�r`r�rMr�r\)rvrurwrrr�_load_unlocked�s<


�����r�cCs8	t|j��t|�Wd�S1swYdSr)r?rr��rvrrrrt�s$�rtc@s�eZdZ	dZedd��Zeddd��Zeddd��Zed	d
��Z	edd��Z
eed
d���Zeedd���Z
eedd���Zee�ZdS)�BuiltinImporterzbuilt-incCs$	t�dt�d|j�dtj�d�S)NzQBuiltinImporter.module_repr() is deprecated and slated for removal in Python 3.12z<module z (z)>)rnrorpr
r�r��rwrrrr{�s
�zBuiltinImporter.module_reprNcCs*|durdSt�|�rt|||jd�SdS�Nr�)rG�
is_builtinrqr���clsrb�path�targetrrr�	find_spec�s

zBuiltinImporter.find_speccCs,	t�dt�|�||�}|dur|jSdS)NzjBuiltinImporter.find_module() is deprecated and slated for removal in Python 3.12; use find_spec() instead)rnrorpr�r�)r�rbr�rvrrr�find_module�s�zBuiltinImporter.find_modulecCs0	|jtjvrtd�|j�|jd��ttj|�Sr^)rrr_r`r8rRrG�create_builtinr�rrrr�s�zBuiltinImporter.create_modulecCs	ttj|�dSr)rRrG�exec_builtinr�rrrr�
szBuiltinImporter.exec_modulecC�	dSrr�r�rbrrr�get_code�zBuiltinImporter.get_codecCr�rrr�rrr�
get_sourcer�zBuiltinImporter.get_sourcecCs	dSr�rr�rrrr�r�zBuiltinImporter.is_package�NNr)r
r	rr��staticmethodr{�classmethodr�r�r�r�rhr�r�r�rxr�rrrrr��s.



r�c@s�eZdZ	dZedd��Zeddd��Zeddd��Zed	d
��Z	edd��Z
ed
d��Zeedd���Z
eedd���Zeedd���ZdS)�FrozenImporter�frozencCs	t�dt�d�|jtj�S)NzPFrozenImporter.module_repr() is deprecated and slated for removal in Python 3.12r�)rnrorpr8r
r�r�)�mrrrr{/s
�zFrozenImporter.module_reprNcCst�|�r
t|||jd�SdSr�)rGrkrqr�r�rrrr�:s
zFrozenImporter.find_speccCs 	t�dt�t�|�r|SdS)NziFrozenImporter.find_module() is deprecated and slated for removal in Python 3.12; use find_spec() instead)rnrorprGrk)r�rbr�rrrr�As
�zFrozenImporter.find_modulecCsdSrrr�rrrr�MszFrozenImporter.create_modulecCs@|jj}t�|�std�|�|d��ttj|�}t||j	�dSrj)
rzrrGrkr`r8rR�get_frozen_object�execr)rwr�coderrrr�Qs

�zFrozenImporter.exec_modulecCs	t||�Sr)rxr�rrrr�Zs
zFrozenImporter.load_modulecC�	t�|�Sr)rGr�r�rrrr�d�
zFrozenImporter.get_codecCr�rrr�rrrr�jr�zFrozenImporter.get_sourcecCr�r)rG�is_frozen_packager�rrrr�pr�zFrozenImporter.is_packager�r)r
r	rr�r�r{r�r�r�r�r�r�rmr�r�r�rrrrr�$s0




	r�c@seZdZ	dd�Zdd�ZdS)�_ImportLockContextcC�	t��dSr)rGrHr:rrrrC}�z_ImportLockContext.__enter__cCr�r)rGrJ)r%�exc_type�	exc_value�
exc_tracebackrrrrF�r�z_ImportLockContext.__exit__N)r
r	rrCrFrrrrr�ysr�cCsB	|�d|d�}t|�|krtd��|d}|rd�||�S|S)Nr�r0z2attempted relative import beyond top-level packager�{}.{})�rsplit�lenr`r8)r�package�level�bits�baserrr�
_resolve_name�sr�cCs<t|��d�}t�|t�|�||�}|durdSt||�S)Nz5.find_spec() not found; falling back to find_module())rrnror�r�rq)�finderrr�rur�rrr�_find_spec_legacy�s
r�c

Cs	tj}|durtd��|st�dt�|tjv}|D]o}t��/z|j}Wnt	yAt
|||�}|dur?YWd�qYnw||||�}Wd�n1sRwY|dur�|s�|tjvr�tj|}z|j}	Wn
t	yy|YSw|	dur�|S|	S|SqdS)Nz5sys.meta_path is None, Python is likely shutting downzsys.meta_path is empty)r�	meta_pathr`rnror�rrr�r�rr�rz)
rr�r�r��	is_reloadr�r�rvrwrzrrr�
_find_spec�sF

����	

��r�cCsp	t|t�std�t|����|dkrtd��|dkr*t|t�s$td��|s*td��|s4|dkr6td��dSdS)Nzmodule name must be str, not {}rzlevel must be >= 0z__package__ not set to a stringz6attempted relative import with no known parent packagezEmpty module name)�
isinstance�str�	TypeErrorr8r�
ValueErrorr`�rr�r�rrr�
_sanity_check�s

�r�zNo module named z{!r}c	Csd}|�d�d}|r@|tjvrt||�|tjvrtj|Stj|}z|j}Wnty?td�||�}t||d�d�wt	||�}|durRtt�|�|d��t
|�}|r�tj|}|�d�d}z	t|||�W|Sty�d|�d|��}t�
|t�Y|Sw|S)Nr�rz; {!r} is not a packager�zCannot set an attribute on z for child module )r�rrrrRr�r�_ERR_MSGr8�ModuleNotFoundErrorr�r�r
rnror�)	r�import_r�r��
parent_modulerurvrw�childrrr�_find_and_load_unlocked�s<





�

��r�cCs�	t|��tj�|t�}|turt||�Wd�SWd�n1s'wY|dur;d�|�}t||d��t|�|S)Nz(import of {} halted; None in sys.modulesr)	r?rrrr*�_NEEDS_LOADINGr�r8r�rO)rr�rwr[rrr�_find_and_load�s
���r�rcCs,	t|||�|dkrt|||�}t|t�Sr)r�r�r��_gcd_importr�rrrrs

r��	recursivecCs�	|D]h}t|t�s!|r|jd}nd}td|�dt|�j����|dkr6|s5t|d�r5t||j|dd�qt||�skd	�|j|�}zt	||�Wqt
yj}z|j|kretj
�|t�dureWYd}~q�d}~wwq|S)
Nz.__all__z
``from list''zItem in z must be str, not �*�__all__Trr�)r�r�r
r�rr�_handle_fromlistrr8rRr�rrrrr*r�)rw�fromlistr�r�x�where�	from_name�excrrrrs8	

�
��

���rcCs�	|�d�}|�d�}|dur*|dur(||jkr(tjd|�d|j�d�tdd�|S|dur1|jStjdtdd�|d	}d
|vrH|�d�d}|S)
Nr�rzz __package__ != __spec__.parent (z != �)�)�
stacklevelzYcan't resolve package from __spec__ or __package__, falling back on __name__ and __path__r
r�r�r)r*r�rnror�r�)�globalsr�rvrrr�_calc___package__Bs,

����rrc	Cs�	|dkr
t|�}n|dur|ni}t|�}t|||�}|sK|dkr+t|�d�d�S|s/|St|�t|�d�d�}tj|jdt|j�|�St|d�rVt||t�S|S)Nrr�r�)	rr�	partitionr�rrrr
rr)	rr�localsrr�rw�globals_r��cut_offrrr�
__import__]s 


rcCs&t�|�}|durtd|��t|�S)Nzno built-in module named )r�r�r`r�)rrvrrr�_builtin_from_name�s
rc
Cs�	|a|att�}tj��D]$\}}t||�r2|tjvrt}n	t�|�r't	}nqt
||�}t||�qtjt}dD]}|tjvrFt
|�}	ntj|}	t|||	�q:dS)N)rrnrN)rGrrrr�itemsr�r_r�rkr�r�r�r
rr
)
�
sys_module�_imp_module�module_typerrwr�rv�self_module�builtin_name�builtin_modulerrr�_setup�s*




�



�rcCs(	t||�tj�t�tj�t�dSr)rrr�r�r�r�)rrrrr�_install�s
rcCs"	ddl}|a|�tjt�dSr)�_frozen_importlib_externalr�rrrrr
)rrrr�_install_external_importers�sr r�rr)NNrr)5rrrnrNr�rrrIr)r5rrr=r?rBrOrRr\rhrmrxr�r�rqr�r�r�r�rsr�r�rtr�r�r�r�r�r�r��_ERR_MSG_PREFIXr�r��objectr�r�rrrrrrrr rrrr�<module>sh	M%e
-H$-PU
	

/ 
%
%#

?>