/usr/lib64/python3.9/importlib/__pycache__
NameSizeModeActions
abc.cpython-39.opt-1.pyc168170644editdlrm
abc.cpython-39.opt-2.pyc92540644editdlrm
abc.cpython-39.pyc168170644editdlrm
machinery.cpython-39.opt-1.pyc9640644editdlrm
machinery.cpython-39.opt-2.pyc8240644editdlrm
machinery.cpython-39.pyc9640644editdlrm
metadata.cpython-39.opt-1.pyc221740644editdlrm
metadata.cpython-39.opt-2.pyc160460644editdlrm
metadata.cpython-39.pyc221740644editdlrm
resources.cpython-39.opt-1.pyc63910644editdlrm
resources.cpython-39.opt-2.pyc49690644editdlrm
resources.cpython-39.pyc63910644editdlrm
util.cpython-39.opt-1.pyc93220644editdlrm
util.cpython-39.opt-2.pyc64530644editdlrm
util.cpython-39.pyc93220644editdlrm
_bootstrap.cpython-39.opt-1.pyc289520644editdlrm
_bootstrap.cpython-39.opt-2.pyc221930644editdlrm
_bootstrap.cpython-39.pyc289680644editdlrm
_bootstrap_external.cpython-39.opt-1.pyc458320644editdlrm
_bootstrap_external.cpython-39.opt-2.pyc345520644editdlrm
_bootstrap_external.cpython-39.pyc462440644editdlrm
_common.cpython-39.opt-1.pyc16990644editdlrm
_common.cpython-39.opt-2.pyc14600644editdlrm
_common.cpython-39.pyc16990644editdlrm
__init__.cpython-39.opt-1.pyc38330644editdlrm
__init__.cpython-39.opt-2.pyc31540644editdlrm
__init__.cpython-39.pyc38330644editdlrm
Edit: /usr/lib64/python3.9/importlib/__pycache__/_bootstrap_external.cpython-39.pyc (46244B)
a à”|j�ã@sdZddladdlZddladdlZddlZtjdkZerLddlZ ddl Z nddl Z erbddgZ ndgZ e dd„e Dƒƒs~J‚e dZee ƒZd e ¡Z d d „e DƒZd Zd ZeeZd d„Zdd„Zdd„Zdd„Zerädd„Zndd„Zdd„Zdd„Zdd„Zdd„Zd d!„Ze�r$d"d#„Z nd$d#„Z d‚d&d'„Z!e"e!j#ƒZ$d( %d)d*¡d+Z&e' (e&d*¡Z)d,Z*d-Z+d.gZ,d/gZ-e-Z.Z/dƒdd0œd1d2„Z0d3d4„Z1d5d6„Z2d7d8„Z3d9d:„Z4d;d<„Z5d=d>„Z6d?d@„Z7dAdB„Z8dCdD„Z9d„dEdF„Z:d…dGdH„Z;d†dJdK„ZƒZ?d‡de?dNœdOdP„Z@GdQdR„dRƒZAGdSdT„dTƒZBGdUdV„dVeBƒZCGdWdX„dXƒZDGdYdZ„dZeDeCƒZEGd[d\„d\eDeBƒZFgZGGd]d^„d^eDeBƒZHGd_d`„d`ƒZIGdadb„dbƒZJGdcdd„ddƒZKGdedf„dfƒZLdˆdgdh„ZMdidj„ZNdkdl„ZOdmdn„ZPdodpdqdrdsdtdudvdwdxdydzd{d|d}d~dœZQd€d�„ZRdS)‰a^Core implementation of path-based import. This module is NOT meant to be directly imported! It has been designed such that it can be bootstrapped into Python as the implementation of import. As such it requires the injection of specific modules and attributes in order to work. One should use importlib as the public-facing version of this module. éNÚwin32ú\ú/ccs|]}t|ƒdkVqdS©éN©Úlen©Ú.0Úsep©r ú5/usr/lib64/python3.9/importlib/_bootstrap_external.pyÚ +órÚcCsh|]}d|›�’qS©ú:r ©r Úsr r r Ú /rr)Úwin)ÚcygwinÚdarwincs<tj t¡r0tj t¡rd‰nd‰‡fdd„}ndd„}|S)NÚ PYTHONCASEOKs PYTHONCASEOKcstjj oˆtjvS)z^True if filenames must be checked case-insensitively and ignore environment flags are not set.)ÚsysÚflagsÚignore_environmentÚ_osÚenvironr ©Úkeyr r Ú _relax_case@sz%_make_relax_case.._relax_casecSsdS)z5True if filenames must be checked case-insensitively.Fr r r r r r!Ds)rÚplatformÚ startswithÚ_CASE_INSENSITIVE_PLATFORMSÚ#_CASE_INSENSITIVE_PLATFORMS_STR_KEY)r!r rr Ú_make_relax_case9s  r&cCst|ƒd@ dd¡S)z*Convert a 32-bit integer to little-endian.ìÿÿéÚlittle)ÚintÚto_bytes)Úxr r r Ú _pack_uint32Jsr-cCst|ƒdksJ‚t |d¡S)z/Convert 4 bytes in little-endian to an integer.r(r)©rr*Ú from_bytes©Údatar r r Ú_unpack_uint32Osr2cCst|ƒdksJ‚t |d¡S)z/Convert 2 bytes in little-endian to an integer.ér)r.r0r r r Ú_unpack_uint16Tsr4cGsä|sdSt|ƒdkr|dSd}g}ttj|ƒD]z\}}| t¡sL| t¡rf| t¡pX|}t |g}q0| d¡r˜|  ¡|  ¡krŒ|}|g}qª|  |¡q0|pž|}|  |¡q0dd„|Dƒ}t|ƒdkrÖ|dsÖ|t S|t   |¡S)úReplacement for os.path.join().rrrrcSsg|]}|r| t¡‘qSr ©ÚrstripÚpath_separators©r Úpr r r Ú rrú_path_join..) rÚmaprÚ_path_splitrootr#Úpath_sep_tupleÚendswithr7r8Úpath_sepÚcasefoldÚappendÚjoin)Ú path_partsÚrootÚpathZnew_rootÚtailr r r Ú _path_join[s*     rIcGst dd„|Dƒ¡S)r5cSsg|]}|r| t¡‘qSr r6)r Úpartr r r r;{sÿr<)rArD)rEr r r rIys ÿcsBt‡fdd„tDƒƒ}|dkr&dˆfSˆd|…ˆ|dd…fS)z Replacement for os.path.split().c3s|]}ˆ |¡VqdS©N)Úrfindr9©rGr r r�rz_path_split..rrNr)Úmaxr8)rGÚir rMr Ú _path_splitsrPcCs t |¡S)z~Stat the path. Made a separate function to make it easier to override in experiments (e.g. cache stat results). )rÚstatrMr r r Ú _path_stat‡srRcCs0z t|ƒ}Wnty YdS0|jd@|kS)z1Test whether the path is the specified mode type.Fið)rRÚOSErrorÚst_mode)rGÚmodeÚ stat_infor r r Ú_path_is_mode_type‘s   rWcCs t|dƒS)zReplacement for os.path.isfile.i€)rWrMr r r Ú _path_isfilešsrXcCs|s t ¡}t|dƒS)zReplacement for os.path.isdir.i@)rÚgetcwdrWrMr r r Ú _path_isdirŸsrZcCs>|sdSt |¡d dd¡}t|ƒdko<| d¡p<| d¡S)úReplacement for os.path.isabs.Frrrrz\\)rr>Úreplacerr#r@)rGrFr r r Ú _path_isabs§sr]cCs | t¡S)r[)r#r8rMr r r r]¯sé¶c Cs²d |t|ƒ¡}t |tjtjBtjB|d@¡}zFt |d¡�}|  |¡Wdƒn1s^0Yt  ||¡Wn6t y¬zt  |¡Wnt y¤Yn0‚Yn0dS)z¢Best-effort function to write data to a path atomically. Be prepared to handle a FileExistsError if concurrent writing of the temporary file is attempted.ú{}.{}r^ÚwbN) ÚformatÚidrÚopenÚO_EXCLÚO_CREATÚO_WRONLYÚ_ioÚFileIOÚwriter\rSÚunlink)rGr1rUÚpath_tmpÚfdÚfiler r r Ú _write_atomic´sÿ(  rnia r3r)s Ú __pycache__zopt-z.pyz.pyc)Ú optimizationc CsX|dur4t dt¡|dur(d}t|ƒ‚|r0dnd}t |¡}t|ƒ\}}| d¡\}}}tj j } | durrt dƒ‚d  |r~|n||| g¡} |dur¬tj jdkr¤d}ntj j}t|ƒ}|dkrà| ¡sÒtd  |¡ƒ‚d  | t|¡} | td} tjdu�rLt|ƒ�stt ¡|ƒ}|dd k�r8|dtv�r8|d d…}ttj| t¡| ƒSt|t| ƒS) aþGiven the path to a .py file, return the path to its .pyc file. The .py file does not need to exist; this simply returns the path to the .pyc file calculated as if the .py file were imported. The 'optimization' parameter controls the presumed optimization level of the bytecode file. If 'optimization' is not None, the string representation of the argument is taken and verified to be alphanumeric (else ValueError is raised). The debug_override parameter is deprecated. If debug_override is not None, a True value is the same as setting 'optimization' to the empty string while a False value is equivalent to setting 'optimization' to '1'. If sys.implementation.cache_tag is None then NotImplementedError is raised. NzFthe debug_override parameter is deprecated; use 'optimization' insteadz2debug_override or optimization must be set to NonerrÚ.ú$sys.implementation.cache_tag is Nonerz{!r} is not alphanumericz{}.{}{}rr3)Ú _warningsÚwarnÚDeprecationWarningÚ TypeErrorrÚfspathrPÚ rpartitionrÚimplementationÚ cache_tagÚNotImplementedErrorrDrÚoptimizeÚstrÚisalnumÚ ValueErrorraÚ_OPTÚBYTECODE_SUFFIXESÚpycache_prefixr]rIrYr8ÚlstripÚ_PYCACHE) rGÚdebug_overriderpÚmessageÚheadrHÚbaser ÚrestÚtagÚalmost_filenameÚfilenamer r r Úcache_from_sourceisHÿ       ýr�c Cs.tjjdurtdƒ‚t |¡}t|ƒ\}}d}tjdurftj t ¡}|  |t ¡rf|t |ƒd…}d}|s�t|ƒ\}}|t kr�tt ›d|›�ƒ‚| d¡}|dvr²td|›�ƒ‚n\|d k�r| dd ¡d }|  t¡sätd t›�ƒ‚|t tƒd…}| ¡�std |›d�ƒ‚| d¡d} t|| tdƒS)anGiven the path to a .pyc. file, return the path to its .py file. The .pyc file does not need to exist; this simply returns the path to the .py file calculated to correspond to the .pyc file. If path does not conform to PEP 3147/488 format, ValueError will be raised. If sys.implementation.cache_tag is None then NotImplementedError is raised. NrrFTz not bottom-level directory in rq>r3ézexpected only 2 or 3 dots in rŽr3éþÿÿÿz5optimization portion of filename does not start with zoptimization level z is not an alphanumeric valuer)rryrzr{rrwrPr‚r7r8r#rArr„rÚcountÚrsplitr€r~Ú partitionrIÚSOURCE_SUFFIXES) rGr‡Úpycache_filenameÚfound_in_pycache_prefixÚ stripped_pathÚpycacheÚ dot_countrpÚ opt_levelÚ base_filenamer r r Úsource_from_cache°s<      ÿ   ÿ r›c Cs|t|ƒdkrdS| d¡\}}}|r8| ¡dd…dkr<|Sz t|ƒ}Wn"ttfyj|dd…}Yn0t|ƒrx|S|S)z¼Convert a bytecode file path to a source path (if possible). This function exists purely for backwards-compatibility for PyImport_ExecCodeModuleWithFilenames() in the C API. rNrqéýÿÿÿéÿÿÿÿÚpy)rrxÚlowerr›r{rrX)Ú bytecode_pathr‰Ú_Ú extensionÚ source_pathr r r Ú_get_sourcefileØs  r¤cCsH| ttƒ¡r.z t|ƒWSty*YqD0n| ttƒ¡r@|SdSdSrK)r@Útupler“r�r{r�)rŒr r r Ú _get_cachedës  r¦cCs2zt|ƒj}Wnty$d}Yn0|dO}|S)z3Calculate the mode permissions for a bytecode file.r^é€)rRrTrS)rGrUr r r Ú _calc_mode÷s   r¨csBd‡fdd„ }z tj}Wnty2dd„}Yn0||ˆƒ|S)züDecorator to verify that the module being requested matches the one the loader can handle. The first argument (self) must define _name which the second argument is compared against. If the comparison fails then ImportError is raised. NcsH|dur|j}n |j|kr0td|j|f|d�‚ˆ||g|¢Ri|¤ŽS)Nzloader for %s cannot handle %s©Úname)rªÚ ImportError)ÚselfrªÚargsÚkwargs©Úmethodr r Ú_check_name_wrapper s ÿÿz(_check_name.._check_name_wrappercSs8dD] }t||ƒrt||t||ƒƒq|j |j¡dS)N)Ú __module__Ú__name__Ú __qualname__Ú__doc__)ÚhasattrÚsetattrÚgetattrÚ__dict__Úupdate)ÚnewÚoldr\r r r Ú_wraps z_check_name.._wrap)N)Ú _bootstrapr½Ú NameError)r°r±r½r r¯r Ú _check_names   rÀcCs<| |¡\}}|dur8t|ƒr8d}t | |d¡t¡|S)z›Try to find a loader for the specified module by delegating to self.find_loader(). This method is deprecated in favor of finder.find_spec(). Nz,Not importing directory {}: missing __init__r)Ú find_loaderrrsrtraÚ ImportWarning)r¬ÚfullnameÚloaderÚportionsÚmsgr r r Ú_find_module_shims rÇcCs¦|dd…}|tkr@d|›d|›�}t d|¡t|fi|¤Ž‚t|ƒdkrjd|›�}t d|¡t|ƒ‚t|dd…ƒ}|d @r¢d |›d |›�}t|fi|¤Ž‚|S) aTPerform basic validity checking of a pyc header and return the flags field, which determines how the pyc should be further validated against the source. *data* is the contents of the pyc file. (Only the first 16 bytes are required, though.) *name* is the name of the module being imported. It is used for logging. *exc_details* is a dictionary passed to ImportError if it raised for improved debugging. ImportError is raised when the magic number is incorrect or when the flags field is invalid. EOFError is raised when the data is found to be truncated. Nr(zbad magic number in z: ú{}éz(reached EOF while reading pyc header of ééüÿÿÿzinvalid flags z in )Ú MAGIC_NUMBERr¾Ú_verbose_messager«rÚEOFErrorr2)r1rªÚ exc_detailsÚmagicr†rr r r Ú _classify_pyc0s     rÑcCsxt|dd…ƒ|d@kr>d|›�}t d|¡t|fi|¤Ž‚|durtt|dd…ƒ|d@krttd|›�fi|¤Ž‚dS)aValidate a pyc against the source last-modified time. *data* is the contents of the pyc file. (Only the first 16 bytes are required.) *source_mtime* is the last modified timestamp of the source file. *source_size* is None or the size of the source file in bytes. *name* is the name of the module being imported. It is used for logging. *exc_details* is a dictionary passed to ImportError if it raised for improved debugging. An ImportError is raised if the bytecode is stale. rÊé r'zbytecode is stale for rÈNrÉ)r2r¾rÍr«)r1Ú source_mtimeÚ source_sizerªrÏr†r r r Ú_validate_timestamp_pycQs  ÿrÕcCs*|dd…|kr&td|›�fi|¤Ž‚dS)aóValidate a hash-based pyc by checking the real source hash against the one in the pyc header. *data* is the contents of the pyc file. (Only the first 16 bytes are required.) *source_hash* is the importlib.util.source_hash() of the source file. *name* is the name of the module being imported. It is used for logging. *exc_details* is a dictionary passed to ImportError if it raised for improved debugging. An ImportError is raised if the bytecode is stale. rÊrÉz.hash in bytecode doesn't match hash of source N)r«)r1Ú source_hashrªrÏr r r Ú_validate_hash_pycms ÿþr×cCsPt |¡}t|tƒr8t d|¡|dur4t ||¡|Std  |¡||d�‚dS)z#Compile bytecode as found in a pyc.zcode object from {!r}NzNon-code object in {!r}©rªrG) ÚmarshalÚloadsÚ isinstanceÚ _code_typer¾rÍÚ_impÚ_fix_co_filenamer«ra)r1rªr r£Úcoder r r Ú_compile_bytecode…s     ÿràcCsFttƒ}| tdƒ¡| t|ƒ¡| t|ƒ¡| t |¡¡|S)z+Produce the data for a timestamp-based pyc.r)Ú bytearrayrÌÚextendr-rÙÚdumps)rßÚmtimerÔr1r r r Ú_code_to_timestamp_pyc’s råTcCsPttƒ}d|d>B}| t|ƒ¡t|ƒdks2J‚| |¡| t |¡¡|S)z&Produce the data for a hash-based pyc.rrÊ)rárÌrâr-rrÙrã)rßrÖÚcheckedr1rr r r Ú_code_to_hash_pycœs  rçcCs>ddl}t |¡j}| |¡}t dd¡}| | |d¡¡S)zyDecode bytes representing source code and return the string. Universal newline support is used in the decoding. rNT)ÚtokenizergÚBytesIOÚreadlineÚdetect_encodingÚIncrementalNewlineDecoderÚdecode)Ú source_bytesrèÚsource_bytes_readlineÚencodingÚnewline_decoderr r r Ú decode_source§s    rò©rÄÚsubmodule_search_locationsc Cs |dur:d}t|dƒrDz| |¡}WqDty6YqD0n t |¡}tj|||d�}d|_|dur˜tƒD]*\}}|  t |ƒ¡rh|||ƒ}||_ q˜qhdS|t urØt|dƒrÞz|  |¡}WntyÊYqÞ0|rÞg|_n||_|jgk�r|�rt|ƒd}|j |¡|S)a=Return a module spec based on a file location. To indicate that the module is a package, set submodule_search_locations to a list of directory paths. An empty list is sufficient, though its not otherwise useful to the import system. The loader must take a spec as its only __init__() arg. Nz Ú get_filename©ÚoriginTÚ is_packager)r¶rõr«rrwr¾Ú ModuleSpecÚ _set_fileattrÚ_get_supported_file_loadersr@r¥rÄÚ _POPULATErørôrPrC) rªÚlocationrÄrôÚspecÚ loader_classÚsuffixesrøÚdirnamer r r Úspec_from_file_location¸s>          rc@sPeZdZdZdZdZdZedd„ƒZedd„ƒZ edd d „ƒZ edd d „ƒZ d S)ÚWindowsRegistryFinderz>Meta path finder for modules declared in the Windows registry.z;Software\Python\PythonCore\{sys_version}\Modules\{fullname}zASoftware\Python\PythonCore\{sys_version}\Modules\{fullname}\DebugFcCs6zt tj|¡WSty0t tj|¡YS0dSrK)ÚwinregÚOpenKeyÚHKEY_CURRENT_USERrSÚHKEY_LOCAL_MACHINE)Úclsr r r r Ú_open_registrys z$WindowsRegistryFinder._open_registrycCs„|jr|j}n|j}|j|dtjdd…d�}z:| |¡�}t |d¡}Wdƒn1s^0YWnt y~YdS0|S)Nz%d.%dr3)rÃÚ sys_versionr) Ú DEBUG_BUILDÚREGISTRY_KEY_DEBUGÚ REGISTRY_KEYrarÚ version_infor rÚ QueryValuerS)rrÃÚ registry_keyr ÚhkeyÚfilepathr r r Ú_search_registrysÿ . z&WindowsRegistryFinder._search_registryNcCsx| |¡}|durdSz t|ƒWnty6YdS0tƒD]4\}}| t|ƒ¡r>tj||||ƒ|d�}|Sq>dS)Nrö)rrRrSrûr@r¥r¾Úspec_from_loader)rrÃrGÚtargetrrÄrrþr r r Ú find_specs   þzWindowsRegistryFinder.find_speccCs"| ||¡}|dur|jSdSdS)zlFind module named in the registry. This method is deprecated. Use exec_module() instead. N©rrÄ©rrÃrGrþr r r Ú find_module.s z!WindowsRegistryFinder.find_module)NN)N) r³r²r´rµr r r Ú classmethodr rrrr r r r rüsÿÿ   rc@s0eZdZdZdd„Zdd„Zdd„Zdd „Zd S) Ú _LoaderBasicszSBase class of common code needed by both SourceLoader and SourcelessFileLoader.cCs@t| |¡ƒd}| dd¡d}| d¡d}|dko>|dkS)z�Concrete implementation of InspectLoader.is_package by checking if the path returned by get_filename has a filename of '__init__.py'.rrqrr3Ú__init__)rPrõr‘rx)r¬rÃrŒÚ filename_baseÚ tail_namer r r røAsz_LoaderBasics.is_packagecCsdS©z*Use default semantics for module creation.Nr ©r¬rþr r r Ú create_moduleIsz_LoaderBasics.create_modulecCs8| |j¡}|dur$td |j¡ƒ‚t t||j¡dS)zExecute the module.Nz4cannot load module {!r} when get_code() returns None)Úget_coder³r«rar¾Ú_call_with_frames_removedÚexecr¹)r¬Úmodulerßr r r Ú exec_moduleLs  ÿz_LoaderBasics.exec_modulecCs t ||¡S)zThis module is deprecated.)r¾Ú_load_module_shim©r¬rÃr r r Ú load_moduleTsz_LoaderBasics.load_moduleN)r³r²r´rµrør!r&r)r r r r r<s rc@sJeZdZdd„Zdd„Zdd„Zdd„Zd d „Zd d œd d„Zdd„Z dS)Ú SourceLoadercCst‚dS)z¥Optional method that returns the modification time (an int) for the specified path (a str). Raises OSError when the path cannot be handled. N)rS©r¬rGr r r Ú path_mtime[szSourceLoader.path_mtimecCsd| |¡iS)ažOptional method returning a metadata dict for the specified path (a str). Possible keys: - 'mtime' (mandatory) is the numeric timestamp of last source code modification; - 'size' (optional) is the size in bytes of the source code. Implementing this method allows the loader to read bytecode files. Raises OSError when the path cannot be handled. rä)r,r+r r r Ú path_statscs zSourceLoader.path_statscCs | ||¡S)zäOptional method which writes data (bytes) to a file path (a str). Implementing this method allows for the writing of bytecode files. The source path is needed in order to correctly transfer permissions )Úset_data)r¬r£Ú cache_pathr1r r r Ú_cache_bytecodeqszSourceLoader._cache_bytecodecCsdS)z–Optional method which writes data (bytes) to a file path (a str). Implementing this method allows for the writing of bytecode files. Nr )r¬rGr1r r r r.{szSourceLoader.set_datac CsT| |¡}z| |¡}Wn2tyJ}ztd|d�|‚WYd}~n d}~00t|ƒS)z4Concrete implementation of InspectLoader.get_source.z'source not available through get_data()r©N)rõÚget_datarSr«rò)r¬rÃrGrîÚexcr r r Ú get_source‚s ÿÿzSourceLoader.get_sourcer�)Ú _optimizecCstjt||dd|d�S)z‚Return the code object compiled from source. The 'data' argument can be any object type that compile() supports. r$T)Ú dont_inheritr|)r¾r#Úcompile)r¬r1rGr4r r r Úsource_to_codeŒs ÿzSourceLoader.source_to_codec Cs| |¡}d}d}d}d}d}z t|ƒ}WntyBd}Y�n*0z| |¡} WntyfY�n0t| dƒ}z| |¡} Wnty”YnØ0||dœ} z”t| || ƒ} t| ƒdd…} | d@dk}|�r| d @dk}t j d k�r2|søt j d k�r2| |¡}t   t |¡}t | ||| ƒnt| || d || ƒWnttf�yLYn 0t d ||¡t| |||d�S|du�r€| |¡}| ||¡}t d|¡tj�s|du�r|du�r|�rÞ|du�rÐt   t |¡}t|||ƒ} nt||t|ƒƒ} z| ||| ¡Wnt�yYn0|S)z¾Concrete implementation of InspectLoader.get_code. Reading of bytecode requires path_stats to be implemented. To write bytecode, set_data must also be implemented. NFTrärØrÉrrr3ÚneverÚalwaysÚsizez {} matches {})rªr r£zcode object from {})rõr�r{r-rSr*r1rÑÚ memoryviewrÝÚcheck_hash_based_pycsrÖÚ_RAW_MAGIC_NUMBERr×rÕr«rÎr¾rÍràr7rÚdont_write_bytecoderçrårr0)r¬rÃr£rÓrîrÖÚ hash_basedÚ check_sourcer Ústr1rÏrÚ bytes_dataÚ code_objectr r r r"”sœ       þ    ÿþ þÿûÿþ    ÿ ÿÿzSourceLoader.get_codeN) r³r²r´r,r-r0r.r3r7r"r r r r r*Ys  r*cs|eZdZdZdd„Zdd„Zdd„Ze‡fdd „ƒZed d „ƒZ d d „Z edd„ƒZ dd„Z dd„Z dd„Zdd„Z‡ZS)Ú FileLoaderzgBase file loader class which implements the loader protocol methods that require file system usage.cCs||_||_dS)zKCache the module name and the path to the file found by the finder.NrØ)r¬rÃrGr r r rïszFileLoader.__init__cCs|j|jko|j|jkSrK©Ú __class__r¹©r¬Úotherr r r Ú__eq__õs  ÿzFileLoader.__eq__cCst|jƒt|jƒASrK©ÚhashrªrG©r¬r r r Ú__hash__ùszFileLoader.__hash__cstt|ƒ |¡S)zdLoad a module from a file. This method is deprecated. Use exec_module() instead. )ÚsuperrDr)r(©rFr r r)üs zFileLoader.load_modulecCs|jS©z:Return the path to the source file as found by the finder.rMr(r r r rõszFileLoader.get_filenamecCs~t|ttfƒrFt t|ƒ¡�}| ¡WdƒS1s:0Yn4t |d¡�}| ¡WdƒS1sp0YdS)z'Return the data from path as raw bytes.NÚr)rÛr*ÚExtensionFileLoaderrgÚ open_coder}Úreadrh)r¬rGrmr r r r1 s (zFileLoader.get_datacCs| |¡r|SdSrK)rø©r¬r%r r r Úget_resource_readers zFileLoader.get_resource_readercCs tt|jƒd|ƒ}t |d¡S)NrrQ)rIrPrGrgrh©r¬ÚresourcerGr r r Ú open_resourceszFileLoader.open_resourcecCs&| |¡st‚tt|jƒd|ƒ}|S©Nr)Ú is_resourceÚFileNotFoundErrorrIrPrGrWr r r Ú resource_path"s zFileLoader.resource_pathcCs(t|vr dStt|jƒd|ƒ}t|ƒS)NFr)rArIrPrGrX©r¬rªrGr r r r[(szFileLoader.is_resourcecCstt t|jƒd¡ƒSrZ)ÚiterrÚlistdirrPrGrLr r r Úcontents.szFileLoader.contents)r³r²r´rµrrIrMrÀr)rõr1rVrYr]r[raÚ __classcell__r r rOr rDês    rDc@s.eZdZdZdd„Zdd„Zddœdd „Zd S) ÚSourceFileLoaderz>Concrete implementation of SourceLoader using the file system.cCst|ƒ}|j|jdœS)z!Return the metadata for the path.)rär:)rRÚst_mtimeÚst_size)r¬rGrAr r r r-6szSourceFileLoader.path_statscCst|ƒ}|j|||d�S)N©Ú_mode)r¨r.)r¬r£r r1rUr r r r0;sz SourceFileLoader._cache_bytecoder^rfc Csüt|ƒ\}}g}|r4t|ƒs4t|ƒ\}}| |¡qt|ƒD]h}t||ƒ}zt |¡Wq<tynYq||_t|ƒs4ztt ¡|ƒ}Wnty2Yn0||_dSrK)rªr]rIrrYrSrGr^r r r r„s zExtensionFileLoader.__init__cCs|j|jko|j|jkSrKrErGr r r rI�s  ÿzExtensionFileLoader.__eq__cCst|jƒt|jƒASrKrJrLr r r rM‘szExtensionFileLoader.__hash__cCs$t tj|¡}t d|j|j¡|S)z&Create an unitialized extension modulez&extension module {!r} loaded from {!r})r¾r#rÝÚcreate_dynamicrÍrªrG)r¬rþr%r r r r!”sÿÿz!ExtensionFileLoader.create_modulecCs$t tj|¡t d|j|j¡dS)zInitialize an extension modulez(extension module {!r} executed from {!r}N)r¾r#rÝÚ exec_dynamicrÍrªrGrUr r r r&œsÿzExtensionFileLoader.exec_modulecs$t|jƒd‰t‡fdd„tDƒƒS)z1Return True if the extension module is a package.rc3s|]}ˆd|kVqdS)rNr ©r Úsuffix©Ú file_namer r r¥sÿz1ExtensionFileLoader.is_package..)rPrGÚanyÚEXTENSION_SUFFIXESr(r rqr rø¢s ÿzExtensionFileLoader.is_packagecCsdS)z?Return None as an extension module cannot create a code object.Nr r(r r r r"¨szExtensionFileLoader.get_codecCsdS)z5Return None as extension modules have no source code.Nr r(r r r r3¬szExtensionFileLoader.get_sourcecCs|jSrPrMr(r r r rõ°sz ExtensionFileLoader.get_filenameN)r³r²r´rµrrIrMr!r&rør"r3rÀrõr r r r rR|s rRc@sleZdZdZdZdd„Zdd„Zdd„Zd d „Zd d „Z d d„Z dd„Z dd„Z dd„Z dd„Zdd„ZdS)Ú_NamespacePatha&Represents a namespace package's path. It uses the module name to find its parent module, and from there it looks up the parent's __path__. When this changes, the module's own path is recomputed, using path_finder. For top-level modules, the parent module's path is sys.path.rcCs,||_||_t| ¡ƒ|_|j|_||_dSrK)Ú_nameÚ_pathr¥Ú_get_parent_pathÚ_last_parent_pathÚ_epochÚ _last_epochÚ _path_finder©r¬rªrGÚ path_finderr r r rÁs z_NamespacePath.__init__cCs&|j d¡\}}}|dkrdS|dfS)z>Returns a tuple of (parent-module-name, parent-path-attr-name)rqr)rrGÚ__path__)rvrx)r¬rkÚdotÚmer r r Ú_find_parent_path_namesÈsz&_NamespacePath._find_parent_path_namescCs| ¡\}}ttj||ƒSrK)r‚r¸rÚmodules)r¬Úparent_module_nameÚpath_attr_namer r r rxÒs z_NamespacePath._get_parent_pathcCsdt| ¡ƒ}||jks"|j|jkr^| |j|¡}|durP|jdurP|jrP|j|_ ||_|j|_|j SrK) r¥rxryrzr{r|rvrÄrôrw)r¬Ú parent_pathrþr r r Ú _recalculateÖs z_NamespacePath._recalculatecCs t| ¡ƒSrK)r_r‡rLr r r Ú__iter__äsz_NamespacePath.__iter__cCs | ¡|SrK©r‡)r¬Úindexr r r Ú __getitem__çsz_NamespacePath.__getitem__cCs||j|<dSrK)rw)r¬rŠrGr r r Ú __setitem__êsz_NamespacePath.__setitem__cCs t| ¡ƒSrK)rr‡rLr r r Ú__len__ísz_NamespacePath.__len__cCs d |j¡S)Nz_NamespacePath({!r}))rarwrLr r r Ú__repr__ðsz_NamespacePath.__repr__cCs || ¡vSrKr‰©r¬Úitemr r r Ú __contains__ósz_NamespacePath.__contains__cCs|j |¡dSrK)rwrCr�r r r rCösz_NamespacePath.appendN)r³r²r´rµrzrr‚rxr‡rˆr‹rŒr�rŽr‘rCr r r r ru¶s ruc@sPeZdZdd„Zedd„ƒZdd„Zdd„Zd d „Zd d „Z d d„Z dd„Z dS)Ú_NamespaceLoadercCst|||ƒ|_dSrK)rurwr}r r r rüsz_NamespaceLoader.__init__cCs d |j¡S)zsReturn repr for the module. The method is deprecated. The import machinery does the job itself. z)rar³)rr%r r r Ú module_reprÿsz_NamespaceLoader.module_reprcCsdS)NTr r(r r r røsz_NamespaceLoader.is_packagecCsdS)Nrr r(r r r r3 sz_NamespaceLoader.get_sourcecCstddddd�S)Nrzr$T)r5)r6r(r r r r"sz_NamespaceLoader.get_codecCsdSrr r r r r r!sz_NamespaceLoader.create_modulecCsdSrKr rUr r r r&sz_NamespaceLoader.exec_modulecCst d|j¡t ||¡S)zbLoad a namespace module. This method is deprecated. Use exec_module() instead. z&namespace module loaded with path {!r})r¾rÍrwr'r(r r r r)sÿz_NamespaceLoader.load_moduleN) r³r²r´rrr“rør3r"r!r&r)r r r r r’ûs r’c@sveZdZdZedd„ƒZedd„ƒZedd„ƒZedd „ƒZedd d „ƒZ edd d„ƒZ eddd„ƒZ edd„ƒZ d S)Ú PathFinderz>Meta path finder for sys.path and package __path__ attributes.cCsNttj ¡ƒD],\}}|dur(tj|=qt|dƒr| ¡qtjd7_dS)z}Call the invalidate_caches() method on all path entry finders stored in sys.path_importer_caches (where implemented).NÚinvalidate_cachesr)ÚlistrÚpath_importer_cacheÚitemsr¶r•rurz)rrªÚfinderr r r r•)s    zPathFinder.invalidate_cachesc CsRtjdurtjst dt¡tjD]*}z||ƒWStyJYq"Yq"0q"dS)z.Search sys.path_hooks for a finder for 'path'.Nzsys.path_hooks is empty)rÚ path_hooksrsrtrÂr«)rrGÚhookr r r Ú _path_hooks6s    zPathFinder._path_hookscCsd|dkr*z t ¡}Wnty(YdS0ztj|}Wn&ty^| |¡}|tj|<Yn0|S)zÒGet the finder for the path entry from sys.path_importer_cache. If the path entry is not in the cache, find the appropriate finder and cache it. If no finder is available, store None. rN)rrYr\rr—ÚKeyErrorrœ)rrGr™r r r Ú_path_importer_cacheCs    zPathFinder._path_importer_cachecCsRt|dƒr| |¡\}}n| |¡}g}|dur.rqr�N) râÚ_loadersrGr]rIrrYÚ _path_mtimeÚsetÚ _path_cacheÚ_relaxed_path_cache)r¬rGÚloader_detailsÚloadersrr r¨r rÄs   zFileFinder.__init__cCs d|_dS)zInvalidate the directory mtime.r�N)rªrLr r r r•ÔszFileFinder.invalidate_cachescCs*| |¡}|durdgfS|j|jp&gfS)zÅTry to find a loader for the specified module, or the namespace package portions. Returns (loader, list-of-portions). This method is deprecated. Use find_spec() instead. N)rrÄrô)r¬rÃrþr r r rÁÚs zFileFinder.find_loadercCs|||ƒ}t||||d�S)Nró)r)r¬rÿrÃrGÚsmslrrÄr r r r£æs ÿzFileFinder._get_specNc Cs~d}| d¡d}zt|jp"t ¡ƒj}Wnty@d}Yn0||jkrZ| ¡||_t ƒrp|j }|  ¡}n |j }|}||vrØt |j|ƒ}|jD]:\} } d| } t || ƒ} t| ƒr”| | || |g|¡Sq”t|ƒ}|jD]p\} } zt |j|| ƒ} Wnt�yYdS0tjd| dd�|| |vrÞt| ƒrÞ| | || d|¡SqÞ|�rzt d |¡t |d¡} |g| _| SdS) zoTry to find a spec for the specified module. Returns the matching spec, or None if not found. Frqr3r�rNz trying {})Ú verbosityzpossible namespace for {})rxrRrGrrYrdrSrªÚ _fill_cacher!r­rŸr¬rIr©rXr£rZrr¾rÍrùrô)r¬rÃrÚ is_namespaceÚ tail_moduleräÚcacheÚ cache_moduleÚ base_pathrprÿÚ init_filenameÚ full_pathrþr r r rësN         ÿ   zFileFinder.find_specc Cs¼|j}zt |pt ¡¡}Wntttfy8g}Yn0tj  d¡sRt |ƒ|_ nJt ƒ}|D]8}|  d¡\}}}|r†d  || ¡¡}n|}| |¡q\||_ tj  t¡r¸dd„|Dƒ|_dS)zDFill the cache of potential modules and packages for this directory.rrqr_cSsh|] }| ¡’qSr )rŸ)r Úfnr r r r;rz)FileFinder._fill_cache..N)rGrr`rYr\ÚPermissionErrorÚNotADirectoryErrorrr"r#r«r¬r’rarŸÚaddr$r­) r¬rGraÚlower_suffix_contentsr�rªr€rpÚnew_namer r r r²s"     zFileFinder._fill_cachecs‡‡fdd„}|S)aA class method which returns a closure to use on sys.path_hook which will return an instance using the specified loaders and the path called on the closure. If the path called on the closure is not a directory, ImportError is raised. cs$t|ƒstd|d�‚ˆ|gˆ¢RŽS)z-Path hook for importlib.machinery.FileFinder.zonly directories are supportedrM)rZr«rM©rr®r r Úpath_hook_for_FileFinderGs z6FileFinder.path_hook..path_hook_for_FileFinderr )rr®rÁr rÀr Ú path_hook=s zFileFinder.path_hookcCs d |j¡S)NzFileFinder({!r}))rarGrLr r r rŽOszFileFinder.__repr__)N)r³r²r´rµrr•rÇrrÁr£rr²rrÂrŽr r r r r§»s  3 r§cCs�| d¡}| d¡}|sB|r$|j}n||kr8t||ƒ}n t||ƒ}|sTt|||d�}z$||d<||d<||d<||d<WntyŠYn0dS)NÚ __loader__Ú__spec__r¨Ú__file__Ú __cached__)ÚgetrÄrlrcrÚ Exception)ÚnsrªÚpathnameÚ cpathnamerÄrþr r r Ú_fix_up_moduleUs"      rÌcCs*ttt ¡ƒf}ttf}ttf}|||gS)z_Returns a list of file-based module loaders. Each item is a tuple (loader, suffixes). )rRÚ_alternative_architecturesrÝÚextension_suffixesrcr“rlr�)Ú extensionsÚsourceÚbytecoder r r rûlsrûc Csˆ|atjatjatjt}ddgfdddgff}|D]l\}}tdd„|DƒƒsRJ‚|d}|tjvrttj|}qªq4zt |¡}WqªWq4tyžYq4Yq40q4tdƒ‚t|d |ƒt|d |ƒt|d d   |¡ƒt|d dd„|Dƒƒgd¢}|dk�r|  d¡|D]4}|tjv�r&t |¡} n tj|} t||| ƒ�q t|dt ƒƒt   tt ¡ƒ¡|dk�r„t  d¡dt v�r„dt_dS)zÍSetup the path-based importers for importlib by importing needed built-in modules and injecting them into the global namespace. Other components are extracted from the core bootstrap module. ÚposixrÚntrcss|]}t|ƒdkVqdSrrr r r r r‰rz_setup..rzimportlib requires posix or ntrrAr8rÚ_pathseps_with_coloncSsh|]}d|›�’qSrr rr r r ršrz_setup..)rgrsrÙrr!z.pywz_d.pydTN)r¾rrÝrƒr³ÚallÚ_builtin_from_namer«r·rDrCr&rtrârÍrÎr“rr ) Ú_bootstrap_moduleÚ self_moduleÚ os_detailsÚ builtin_osr8rAÚ os_moduleÚ builtin_namesÚ builtin_nameÚbuiltin_moduler r r Ú_setupwsF                  rßcCs2t|ƒtƒ}tj tj|Žg¡tj t ¡dS)z)Install the path-based import components.N) rßrûrršrâr§rÂÚ meta_pathrCr”)r×Úsupported_loadersr r r Ú_install°srâú-arm-linux-gnueabihf.ú-armeb-linux-gnueabihf.ú-mips64-linux-gnuabi64.ú-mips64el-linux-gnuabi64.ú-powerpc-linux-gnu.ú-powerpc-linux-gnuspe.ú-powerpc64-linux-gnu.ú-powerpc64le-linux-gnu.ú-arm-linux-gnueabi.ú-armeb-linux-gnueabi.ú-mips64-linux-gnu.ú-mips64el-linux-gnu.ú-ppc-linux-gnu.ú-ppc-linux-gnuspe.ú-ppc64-linux-gnu.ú-ppc64le-linux-gnu.)rërìrírîrïrðrñròrãrärårærçrèrérêcCsF|D]<}t ¡D].\}}||vr| | ||¡¡|Sqq|S)z®Add a suffix with an alternative architecture name to the list of suffixes so an extension built with the default (upstream) setting is loadable with our Pythons )Ú _ARCH_MAPr˜rCr\)rrpÚoriginalÚ alternativer r r rÍÍs rÍ)r^)N)NNN)rr)T)N)N)SrµrÝrgrrsrÙr"Ú _MS_WINDOWSrÓrrrÒr8rÕrAr¥r?rDrÔr%Ú%_CASE_INSENSITIVE_PLATFORMS_BYTES_KEYr$r&r-r2r4rIrPrRrWrXrZr]rnÚtypeÚ__code__rÜr+rÌr*r/r=r„r€r“r�ÚDEBUG_BYTECODE_SUFFIXESÚOPTIMIZED_BYTECODE_SUFFIXESr�r›r¤r¦r¨rÀrÇrÑrÕr×ràrårçròÚobjectrürrrr*rDrcrlrtrRrur’r”r§rÌrûrßrârórÍr r r r ÚsÎ    ÿ       G(  ! ÿ D@H-:E*  9 ï