403Webshell
Server IP : 35.80.110.71  /  Your IP : 216.73.216.221
Web Server : Apache/2.4.58 (Ubuntu)
System : Linux ip-172-31-21-44 6.17.0-1019-aws #19~24.04.1-Ubuntu SMP Tue Jun 23 18:53:06 UTC 2026 x86_64
User : ubuntu ( 1000)
PHP Version : 8.3.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/parso/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/parso/__pycache__/cache.cpython-312.pyc
�

̑�a!���UddlZddlZddlZddlZddlZddlZddlZddlZddlZddl	Z	ddl
mZddlm
Z
mZeje�ZdZ	dZ	dZ	dZ	ej,��dej.d�ej.d�de��Z	d	�Ze�Z	d
Zdd�ZiZe
eefed<Gd
�d�Z dd�Z!dd�Z"d�Z#dd�Z$dd�Z%dd�Z&defd�Z'd�Z(dd�Z)dd�Z*dd�Z+y)�N)�Path)�Dict�AnyiXi�'�!�-�c��tj�j�dk(r4tt	j
d�xsddd�}|j
�Stj�j�dk(rtdddd�}|j
�Stt	j
d�xsd	d
�}|j
�S)N�windows�LOCALAPPDATA�~�Parso�darwin�Library�Caches�XDG_CACHE_HOMEz~/.cache�parso)�platform�system�lowerr�os�getenv�
expanduser)�dir_s �-/usr/lib/python3/dist-packages/parso/cache.py�_get_default_cache_pathrBs��������� �I�-��B�I�I�n�-�4��g�w�G��
�?�?���	
���	�	 �	 �	"�h�	.��C��H�g�6���?�?����B�I�I�.�/�=�:�w�G���?�?���i�Qc�8�|xst}|jd�S)z�
    The path where the cache lock is stored.

    Cache lock will prevent continous cache clearing and only allow garbage
    collection once a day (can be configured in _CACHE_CLEAR_THRESHOLD).
    zPARSO-CACHE-LOCK)�_default_cache_path�joinpath��
cache_paths r�_get_cache_clear_lock_pathr"Ys!���2�2�J����1�2�2r�parser_cachec��eZdZdd�Zy)�_NodeCacheItemNc�h�||_||_|�tj�}||_||_y�N)�node�lines�time�change_time�	last_used)�selfr(r)r+s    r�__init__z_NodeCacheItem.__init__hs0����	���
����)�)�+�K�&���$��rr')�__name__�
__module__�__qualname__r.�rrr%r%gs��%rr%c��|j�}|�y	t||j}||jkr%t	j�|_|jSy#t$rt||j||��cYSwxYw)z0
    Returns a module or None, if it fails.
    Nr )	�get_last_modifiedr#�pathr+r*r,r(�KeyError�_load_from_file_system)�hashed_grammar�file_ior!�p_time�module_cache_items     r�load_moduler<qs����
&�
&�
(�F�
�~��
�(��8����F���&�2�2�2�*.�)�)�+��'�$�)�)�)�3���
�%���L�L��!�	
�	
�
�s�A	A � "B�Bc���t|||��}	|tjj|�kDryt	|d�5}tj�	tj|�}tj�	ddd�t||�tjd|�|jS#tj�wxYw#1swY�QxYw#t$rYywxYw)Nr �rbzpickle loaded: %s)�_get_hashed_pathrr5�getmtime�open�gc�disable�pickle�load�enable�_set_cache_item�LOG�debugr(�FileNotFoundError)r8r5r:r!�fr;s      rr7r7�s���!�.�$�:�N�J�&��B�G�G�$�$�Z�0�0��
�*�d�
#�	�q��J�J�L�
�$*�K�K��N�!��	�	��	�	���.?�@��	�	�%�t�,� �%�%�%��
�	�	���	�	������sE�"C�C�C�B6�*C�?C�6C�C�C�C�	C'�&C'c�z�td�tj�D��tk\rqt	j�t
z
}tj
�D]?\}}|j
�D��cic]\}}|j|kDr||��c}}t|<�A|tj|i�<ycc}}w)Nc3�2K�|]}t|����y�wr')�len)�.0�vs  r�	<genexpr>z"_set_cache_item.<locals>.<genexpr>�s����
1�a�3�q�6�
1�s�)	�sumr#�values�_CACHED_SIZE_TRIGGERr*�_CACHED_FILE_MINIMUM_SURVIVAL�itemsr,�
setdefault)r8r5r;�cutoff_time�key�path_to_item_map�	node_items       rrGrG�s���
�
1�<�.�.�0�
1�1�5I�I��i�i�k�$A�A��%1�%7�%7�%9�	�!�C�!�(8�'=�'=�'?�!�#�D�)��&�&��4��i��!�L���	�9J�L���N�B�/��5��
!s�4B7c�<�|j}	|�dn|j�}t|||�}t	|||�|r |�	t||||��t
|��yyy#t$rd}d}Y�LwxYw#t$r tjd|zt�YywxYw)NFr z6Tried to save a file to %s, but got permission denied.)r5r4�OSErrorr%rG�_save_to_file_system�_remove_cache_and_update_lock�PermissionError�warnings�warn�Warning)	r8r9�moduler)�picklingr!r5r:�items	         r�try_to_save_modulerg�s����<�<�D�����7�+D�+D�+F��
�&�%��0�D��N�D�$�/��D�$�	A� ���t�
�S�
*�Z�@�%�x��
���������	�
�M�M�H�4�O��
�		�s#�A�A2�
A/�.A/�2&B�Bc��tt|||��d�5}tj||tj�ddd�y#1swYyxYw)Nr �wb)rAr?rD�dump�HIGHEST_PROTOCOL)r8r5rfr!rKs     rr^r^�sD��	
��~�t�
�K�T�	R�6�VW����D�!�V�4�4�5�6�6�6�s�&A�Ac�f�|�t}tj|�tj	�yr')r�shutil�rmtreer#�clearr s r�clear_cacherp�s%����(�
�
�M�M�*�����rc��|�t}|j�sytj|�D]�}|j	|�}|j�s�%tj|�D]Y}|j�jtztj�ks�:	tj|j��[��y#t$rY�jwxYw)NFT)r�existsr�listdirr�is_dir�scandir�stat�st_atime�_CACHED_FILE_MAXIMUM_SURVIVALr*�remover5r])r!�inactivity_threshold�dirname�version_path�files     r�clear_inactive_cacher~�s�����(�
�������:�:�j�)���!�*�*�7�3���"�"�$���J�J�|�,�	�D��y�y�{�#�#�&C�C�t�y�y�{�R���I�I�d�i�i�(�	�	�������s�$C�	C�Cc��	tj|d�y#t$r6	t|d�}|j	�Yy#t
tf$rYYywxYwwxYw)N�aFT)r�utimerJrA�closer]�IOError)r5r}s  r�_touchr��sb���
����t����
��	���c�?�D��J�J�L�����!�	��	��	�s&��	A�A�A�A�A�Ac���t|��}	tjj|�}|�|t
zt
j�krt|�syt|��yy#t$rd}Y�GwxYw)Nr F)	r"rr5r@rJ�_CACHE_CLEAR_THRESHOLDr*r�r~)r!�	lock_path�clear_lock_times   rr_r_�sr��*�j�A�I���'�'�*�*�9�5��	���3�3�t�y�y�{�B��i� ���
�3�C��	�����s�A'�'A5�4A5c���t|��}tjt|�j	d��j�}tjj||�d|�d��S)Nr zutf-8rz.pkl)	�_get_cache_directory_path�hashlib�sha256�str�encode�	hexdigestrr5�join)r8r5r!�	directory�	file_hashs     rr?r?sL��)�Z�@�I����s�4�y�/�/��8�9�C�C�E�I�
�7�7�<�<�	�.�)�#L�M�Mrc��|�t}|jt�}|j�st	j
|�|Sr')rr�_VERSION_TAGrrr�makedirs)r!r�s  rr�r�
s;����(�
��#�#�L�1�I�����
���I���rr')TN),r*r�sysr�rBrmr�loggingrarD�pathlibr�typingrr�	getLoggerr/rHrUrxrT�_PICKLE_VERSION�python_implementation�version_infor�rrr�r"r#r��__annotations__r%r<r7rGrgr^rpr~r�r_r?r�r2rr�<module>r�s)���	�
��	�
����
����g����!�� '���!2���
��	���
�#�H�"�"�$����Q�����Q���	����.�/���&��3� "��d�3��8�n�!�%�%�
�,&�*
J� A�26�
��6��,	�4�&N�r

Youez - 2016 - github.com/yon3zu
LinuXploit