One Hat Cyber Team
Your IP :
18.222.140.52
Server IP :
103.133.214.160
Server :
Linux venus.ewebguru.net 4.18.0-553.22.1.el8_10.x86_64 #1 SMP Tue Sep 24 05:16:59 EDT 2024 x86_64
Server Software :
Apache/2
PHP Version :
8.1.30
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
lib64
/
python3.6
/
__pycache__
/
View File Name :
weakref.cpython-36.opt-1.pyc
3 � \�O��������������� ���@���s����d�Z�ddlmZmZmZmZmZmZmZm Z �ddl mZmZ�ddl Z ddlZddlZeefZddddd d ddd ddddg ZG�dd��de�ZG�dd��de j�ZG�dd��de�ZG�dd ��d e j�ZG�dd��d�ZdS�)z{Weak reference support for Python. This module is an implementation of PEP 205: http://www.python.org/dev/peps/pep-0205/ �����)�getweakrefcount�getweakrefs�ref�proxy�CallableProxyType� ProxyType� ReferenceType�_remove_dead_weakref)�WeakSet�_IterationGuardNr���r���r���r����WeakKeyDictionaryr���r���r���� ProxyTypes�WeakValueDictionaryr ���� WeakMethod�finalizec�������������������sD���e�Zd�ZdZdZddd�Z��fd d �Zdd��Zd d��Ze j Z ���ZS�)r���z� A custom `weakref.ref` subclass which simulates a weak reference to a bound method, working around the lifetime problem of bound methods. � _func_ref� _meth_type�_alive�__weakref__Nc����������������s~���y|j�}|j}W�n(�tk r8���tdjt|���d��Y�nX����fdd�}tj|�||�}t||�|_t|�|_ d|_ t|��|S�)Nz)argument should be a bound method, not {}c����������������s&������}|j�r"d|_���d�k r"��|��d�S�)NF)r���)�arg�self)�callback�self_wr���/usr/lib64/python3.6/weakref.py�_cb3���s ����zWeakMethod.__new__.<locals>._cbT)�__self__�__func__�AttributeError� TypeError�format�typer����__new__r���r���r���)�cls�methr����obj�funcr���r���r���)r���r���r���r"���,���s���� zWeakMethod.__new__c����������������s2���t���j��}|�j��}|d�ks"|d�kr&d�S�|�j||�S�)N)�super�__call__r���r���)r���r%���r&���)� __class__r���r���r(���B���s ���� zWeakMethod.__call__c�������������C���s>���t�|t�r:|�j�s|j�r"|�|kS�tj|�|�o8|�j|jkS�dS�)NF)� isinstancer���r���r����__eq__r���)r����otherr���r���r���r+���I���s ���� zWeakMethod.__eq__c�������������C���s>���t�|t�r:|�j�s|j�r"|�|k S�tj|�|�p8|�j|jkS�dS�)NT)r*���r���r���r����__ne__r���)r���r,���r���r���r���r-���P���s ���� zWeakMethod.__ne__)r���r���r���r���)N)�__name__� __module__�__qualname__�__doc__� __slots__r"���r(���r+���r-���r����__hash__� __classcell__r���r���)r)���r���r���$���s��� c���������������@���s����e�Zd�ZdZdd��Zdd��Zdd��Zdd ��Zd d��Zdd ��Z dd��Z dd��Zdd��ZeZ dd��Zd+dd�Zdd��Zdd��ZeZdd��Zdd ��Zd!d"��Zd#d$��Zd,d%d&�Zd'd(��Zd)d*��ZdS�)-r���z�Mapping class that references values weakly. Entries in the dictionary will be discarded when no strong reference to the value exists anymore c�����������������st���|�st�d��|�^}}�t|��dkr0t�dt|�����t|�tf��fdd� }||_g�|_t��|_i��|_��|j |�|��d�S�)NzGdescriptor '__init__' of 'WeakValueDictionary' object needs an argument����z$expected at most 1 arguments, got %dc����������������s4���|��}|d�k r0|j�r$|jj|�j��n|��|�j��d�S�)N)� _iterating�_pending_removals�append�key)�wr�selfref�_atomic_removalr���)�dr���r����removem���s ����z,WeakValueDictionary.__init__.<locals>.remove) r����lenr���r ����_remover7����setr6����data�update)�args�kwr���r>���r���)r=���r����__init__f���s���� zWeakValueDictionary.__init__c�������������C���s,���|�j�}|�j}x|r&|j��}t||��qW�d�S�)N)r7���rB����popr ���)r����lr=���r9���r���r���r����_commit_removals}���s ����z$WeakValueDictionary._commit_removalsc�������������C���s4���|�j�r|�j���|�j|���}|d�kr,t|��n|S�d�S�)N)r7���rI���rB����KeyError)r���r9����or���r���r����__getitem__����s���� zWeakValueDictionary.__getitem__c�������������C���s���|�j�r|�j���|�j|=�d�S�)N)r7���rI���rB���)r���r9���r���r���r����__delitem__����s����zWeakValueDictionary.__delitem__c�������������C���s���|�j�r|�j���t|�j�S�)N)r7���rI���r?���rB���)r���r���r���r����__len__����s����zWeakValueDictionary.__len__c�������������C���s<���|�j�r|�j���y|�j|���}W�n�tk r2���dS�X�|d�k S�)NF)r7���rI���rB���rJ���)r���r9���rK���r���r���r����__contains__����s����z WeakValueDictionary.__contains__c�������������C���s���d|�j�jt|��f�S�)Nz<%s at %#x>)r)���r.����id)r���r���r���r����__repr__����s����zWeakValueDictionary.__repr__c�������������C���s&���|�j�r|�j���t||�j|�|�j|<�d�S�)N)r7���rI����KeyedRefr@���rB���)r���r9����valuer���r���r����__setitem__����s����zWeakValueDictionary.__setitem__c�������������C���sF���|�j�r|�j���t��}x,|�jj��D�]\}}|��}|d�k r |||<�q W�|S�)N)r7���rI���r���rB����items)r����newr9���r:���rK���r���r���r����copy����s����zWeakValueDictionary.copyc�������������C���sZ���ddl�m}�|�jr|�j���|�j��}x2|�jj��D�]$\}}|��}|d�k r.|||||�<�q.W�|S�)Nr���)�deepcopy)rW���rX���r7���rI���r)���rB���rU���)r����memorX���rV���r9���r:���rK���r���r���r����__deepcopy__����s����z WeakValueDictionary.__deepcopy__Nc�������������C���sL���|�j�r|�j���y|�j|�}W�n�tk r0���|S�X�|��}|d�krD|S�|S�d�S�)N)r7���rI���rB���rJ���)r���r9����defaultr:���rK���r���r���r����get����s����zWeakValueDictionary.getc���������� ���c���sV���|�j�r|�j���t|���6�x.|�jj��D�] \}}|��}|d�k r$||fV��q$W�W�d�Q�R�X�d�S�)N)r7���rI���r���rB���rU���)r����kr:����vr���r���r���rU�������s���� zWeakValueDictionary.itemsc���������� ���c���sN���|�j�r|�j���t|���.�x&|�jj��D�]\}}|��d�k r$|V��q$W�W�d�Q�R�X�d�S�)N)r7���rI���r���rB���rU���)r���r]���r:���r���r���r����keys����s���� zWeakValueDictionary.keysc���������� ���c���s6���|�j�r|�j���t|����|�jj��E�dH��W�dQ�R�X�dS�)a���Return an iterator that yields the weak references to the values. The references are not guaranteed to be 'live' at the time they are used, so the result of calling the references needs to be checked before being used. This can be used to avoid creating references that will cause the garbage collector to keep the values around longer than needed. N)r7���rI���r���rB����values)r���r���r���r���� itervaluerefs����s���� z!WeakValueDictionary.itervaluerefsc���������� ���c���sN���|�j�r|�j���t|���.�x&|�jj��D�]}|��}|d�k r$|V��q$W�W�d�Q�R�X�d�S�)N)r7���rI���r���rB���r`���)r���r:���r%���r���r���r���r`�������s���� zWeakValueDictionary.valuesc�������������C���s<���|�j�r|�j���x(|�jj��\}}|��}|d�k r||fS�qW�d�S�)N)r7���rI���rB����popitem)r���r9���r:���rK���r���r���r���rb�������s����zWeakValueDictionary.popitemc�������������G���s`���|�j�r|�j���y|�jj|���}W�n�tk r8���d�}Y�nX�|d�krX|rN|d�S�t|��n|S�d�S�)Nr���)r7���rI���rB���rG���rJ���)r���r9���rD���rK���r���r���r���rG�����s���� zWeakValueDictionary.popc�������������C���s`���y|�j�|���}W�n�tk r(���d�}Y�nX�|d�krX|�jr@|�j���t||�j|�|�j�|<�|S�|S�d�S�)N)rB���rJ���r7���rI���rR���r@���)r���r9���r[���rK���r���r���r���� setdefault��s���� zWeakValueDictionary.setdefaultc��������������O���s����|�st�d��|�^}}�t|��dkr0t�dt|�����|�r<|�d�nd�}|jrN|j���|j}|d�k r�t|d�srti��|�}x&|j��D�]\}}t||j |�||<�q|W�t|�r�|j |��d�S�)NzEdescriptor 'update' of 'WeakValueDictionary' object needs an argumentr5���z$expected at most 1 arguments, got %dr���rU���)r���r?���r7���rI���rB����hasattrr!���rU���rR���r@���rC���)rD����kwargsr����dictr=���r9���rK���r���r���r���rC��� ��s ���� zWeakValueDictionary.updatec�������������C���s���|�j�r|�j���t|�jj���S�)a~��Return a list of weak references to the values. The references are not guaranteed to be 'live' at the time they are used, so the result of calling the references needs to be checked before being used. This can be used to avoid creating references that will cause the garbage collector to keep the values around longer than needed. )r7���rI����listrB���r`���)r���r���r���r���� valuerefs3��s���� zWeakValueDictionary.valuerefs)N)N)r.���r/���r0���r1���rF���rI���rL���rM���rN���rO���rQ���rT���rW����__copy__rZ���r\���rU���r_����__iter__ra���r`���rb���rG���rc���rC���rh���r���r���r���r���r���Z���s.��� c�������������������s,���e�Zd�ZdZdZdd��Z��fdd�Z���ZS�)rR���a[��Specialized reference that includes a key corresponding to the value. This is used in the WeakValueDictionary to avoid having to create a function object for each key stored in the mapping. A shared callback object can use the 'key' attribute of a KeyedRef instead of getting a reference to the key from an enclosing scope. r9���c�������������C���s���t�j|�||�}||_|S�)N)r���r"���r9���)r!����obr���r9���r���r���r���r���r"���N��s����zKeyedRef.__new__c����������������s���t���j||��d�S�)N)r'���rF���)r���rk���r���r9���)r)���r���r���rF���S��s����zKeyedRef.__init__)r9���)r.���r/���r0���r1���r2���r"���rF���r4���r���r���)r)���r���rR���B��s���rR���c���������������@���s����e�Zd�ZdZd+dd�Zdd��Zdd��Zd d ��Zdd��Zd d��Z dd��Z dd��Zdd��ZeZ dd��Zd,dd�Zdd��Zdd��Zdd��ZeZdd ��Zd!d"��Zd#d$��Zd%d&��Zd-d'd(�Zd.d)d*�ZdS�)/r���a��� Mapping class that references keys weakly. Entries in the dictionary will be discarded when there is no longer a strong reference to the key. This can be used to associate additional data with an object owned by other parts of an application without adding attributes to those objects. This can be especially useful with objects that override attribute accesses. Nc�������������C���sF���i�|�_�t|��fdd�}||�_g�|�_t��|�_d|�_|d�k rB|�j|��d�S�)Nc�������������S���s.���|��}|d�k r*|j�r"|jj|���n|j|�=�d�S�)N)r6���r7���r8���rB���)r]���r;���r���r���r���r���r>���d��s ����z*WeakKeyDictionary.__init__.<locals>.removeF)rB���r���r@���r7���rA���r6���� _dirty_lenrC���)r���rf���r>���r���r���r���rF���b��s����zWeakKeyDictionary.__init__c�������������C���s>���|�j�}|�j}x,|r8y||j��=�W�q�tk r4���Y�qX�qW�d�S�)N)r7���rB���rG���rJ���)r���rH���r=���r���r���r���rI���s��s����z"WeakKeyDictionary._commit_removalsc����������������s&���|�j�����fdd�|�jD��|�_d|�_d�S�)Nc����������������s���g�|�]}|��kr|�qS�r���r���)�.0r]���)r=���r���r���� <listcomp>���s����z5WeakKeyDictionary._scrub_removals.<locals>.<listcomp>F)rB���r7���rl���)r���r���)r=���r����_scrub_removals���s����z!WeakKeyDictionary._scrub_removalsc�������������C���s���d|�_�|�jt|�=�d�S�)NT)rl���rB���r���)r���r9���r���r���r���rM������s����zWeakKeyDictionary.__delitem__c�������������C���s���|�j�t|��S�)N)rB���r���)r���r9���r���r���r���rL������s����zWeakKeyDictionary.__getitem__c�������������C���s(���|�j�r|�jr|�j���t|�j�t|�j��S�)N)rl���r7���ro���r?���rB���)r���r���r���r���rN������s����zWeakKeyDictionary.__len__c�������������C���s���d|�j�jt|��f�S�)Nz<%s at %#x>)r)���r.���rP���)r���r���r���r���rQ������s����zWeakKeyDictionary.__repr__c�������������C���s���||�j�t||�j�<�d�S�)N)rB���r���r@���)r���r9���rS���r���r���r���rT������s����zWeakKeyDictionary.__setitem__c�������������C���s8���t���}x,|�jj��D�]\}}|��}|d�k r|||<�qW�|S�)N)r���rB���rU���)r���rV���r9���rS���rK���r���r���r���rW������s����zWeakKeyDictionary.copyc�������������C���sL���ddl�m}�|�j��}x2|�jj��D�]$\}}|��}|d�k r |||�||<�q W�|S�)Nr���)rX���)rW���rX���r)���rB���rU���)r���rY���rX���rV���r9���rS���rK���r���r���r���rZ������s����zWeakKeyDictionary.__deepcopy__c�������������C���s���|�j�jt|�|�S�)N)rB���r\���r���)r���r9���r[���r���r���r���r\������s����zWeakKeyDictionary.getc�������������C���s,���yt�|�}W�n�tk r ���dS�X�||�jkS�)NF)r���r���rB���)r���r9���r:���r���r���r���rO������s ����zWeakKeyDictionary.__contains__c���������� ���c���sH���t�|���6�x.|�jj��D�] \}}|��}|d�k r||fV��qW�W�d�Q�R�X�d�S�)N)r���rB���rU���)r���r:���rS���r9���r���r���r���rU������s ���� zWeakKeyDictionary.itemsc���������� ���c���s<���t�|���*�x"|�jD�]}|��}|d�k r|V��qW�W�d�Q�R�X�d�S�)N)r���rB���)r���r:���r%���r���r���r���r_������s ���� zWeakKeyDictionary.keysc���������� ���c���s@���t�|���.�x&|�jj��D�]\}}|��d�k r|V��qW�W�d�Q�R�X�d�S�)N)r���rB���rU���)r���r:���rS���r���r���r���r`������s���� zWeakKeyDictionary.valuesc�������������C���s ���t�|�j�S�)az��Return a list of weak references to the keys. The references are not guaranteed to be 'live' at the time they are used, so the result of calling the references needs to be checked before being used. This can be used to avoid creating references that will cause the garbage collector to keep the keys around longer than needed. )rg���rB���)r���r���r���r����keyrefs���s���� zWeakKeyDictionary.keyrefsc�������������C���s4���d|�_�x(|�jj��\}}|��}|d�k r||fS�qW�d�S�)NT)rl���rB���rb���)r���r9���rS���rK���r���r���r���rb������s����zWeakKeyDictionary.popitemc�������������G���s���d|�_�|�jjt|�f|���S�)NT)rl���rB���rG���r���)r���r9���rD���r���r���r���rG������s����zWeakKeyDictionary.popc�������������C���s���|�j�jt||�j�|�S�)N)rB���rc���r���r@���)r���r9���r[���r���r���r���rc������s����zWeakKeyDictionary.setdefaultc�������������K���s`���|�j�}|d�k rJt|d�s$ti��|�}x$|j��D�]\}}||t||�j�<�q.W�t|�r\|�j|��d�S�)NrU���)rB���rd���r!���rU���r���r@���r?���rC���)r���rf���re���r=���r9���rS���r���r���r���rC������s���� zWeakKeyDictionary.update)N)N)N)N)r.���r/���r0���r1���rF���rI���ro���rM���rL���rN���rQ���rT���rW���ri���rZ���r\���rO���rU���r_���rj���r`���rp���rb���rG���rc���rC���r���r���r���r���r���W��s.��� c���������������@���s����e�Zd�ZdZf�Zi�ZdZej��Z dZ dZG�dd��d�Zdd��Z ddd �Zd d��Zdd ��Zedd���Zedd���Zejdd���Zdd��Zedd���Zedd���ZdS�)r���a��Class for finalization of weakrefable objects finalize(obj, func, *args, **kwargs) returns a callable finalizer object which will be called when obj is garbage collected. The first time the finalizer is called it evaluates func(*arg, **kwargs) and returns the result. After this the finalizer is dead, and calling it just returns None. When the program exits any remaining finalizers for which the atexit attribute is true will be run in reverse order of creation. By default atexit is true. Fc���������������@���s���e�Zd�ZdZdS�) zfinalize._Info�weakrefr&���rD���re����atexit�indexN)rq���r&���rD���re���rr���rs���)r.���r/���r0���r2���r���r���r���r����_Info��s���rt���c�������������O���sp���|�j�s dd�l}|j|�j��dt_�|�j��}t||��|_||_||_ |pFd�|_ d|_t|�j�|_ ||�j|�<�dt_d�S�)Nr���T)�_registered_with_atexitrr����register� _exitfuncr���rt���r���rq���r&���rD���re����next�_index_iterrs���� _registry�_dirty)r���r%���r&���rD���re���rr����infor���r���r���rF�����s���� zfinalize.__init__Nc�������������C���s2���|�j�j|�d�}|r.|�j�r.|j|j|jp*i��S�dS�)zZIf alive then mark as dead and return func(*args, **kwargs); otherwise return NoneN)rz���rG���� _shutdownr&���rD���re���)r����_r|���r���r���r���r(�����s����zfinalize.__call__c�������������C���sH���|�j�j|��}|o|j��}|dk rD|�j�j|�d�rD||j|j|jp@i�fS�dS�)z^If alive then mark as dead and return (obj, func, args, kwargs); otherwise return NoneN)rz���r\���rq���rG���r&���rD���re���)r���r|���r%���r���r���r����detach&��s����zfinalize.detachc�������������C���s:���|�j�j|��}|o|j��}|dk r6||j|j|jp2i�fS�dS�)zMIf alive then return (obj, func, args, kwargs); otherwise return NoneN)rz���r\���rq���r&���rD���re���)r���r|���r%���r���r���r����peek.��s����z finalize.peekc�������������C���s ���|�|�j�kS�)zWhether finalizer is alive)rz���)r���r���r���r����alive6��s����zfinalize.alivec�������������C���s���|�j�j|��}t|�o|jS�)z*Whether finalizer should be called at exit)rz���r\����boolrr���)r���r|���r���r���r���rr���;��s����zfinalize.atexitc�������������C���s���|�j�j|��}|rt|�|_d�S�)N)rz���r\���r����rr���)r���rS���r|���r���r���r���rr���A��s����c�������������C���s^���|�j�j|��}|o|j��}|d�kr6dt|��jt|��f�S�dt|��jt|��t|�jt|�f�S�d�S�)Nz<%s object at %#x; dead>z!<%s object at %#x; for %r at %#x>)rz���r\���rq���r!���r.���rP���)r���r|���r%���r���r���r���rQ���G��s����zfinalize.__repr__c�������������C���s2���dd��|�j�j��D��}|jdd��d��dd��|D��S�)Nc�������������S���s���g�|�]\}}|j�r||f�qS�r���)rr���)rm����f�ir���r���r���rn���S��s����z-finalize._select_for_exit.<locals>.<listcomp>c�������������S���s ���|�d�j�S�)Nr5���)rs���)�itemr���r���r����<lambda>T��s����z+finalize._select_for_exit.<locals>.<lambda>)r9���c�������������S���s���g�|�]\}}|�qS�r���r���)rm���r����r����r���r���r���rn���U��s����)rz���rU����sort)r#����Lr���r���r����_select_for_exitP��s����zfinalize._select_for_exitc�������������C���s����d}z�|�j�r�dd�l}|j��r(d}|j���d�}x\|d�ks<tjrJ|�j��}dt_|sPP�|j��}y |���W�q.�tk r����t j t j�����Y�q.X�q.W�W�d�dt_|r�|j ���X�d�S�)NFr���T)rz����gc� isenabled�disabler���r{���r����rG���� Exception�sys� excepthook�exc_infor}����enable)r#����reenable_gcr�����pendingr����r���r���r���rw���W��s.���� zfinalize._exitfunc)N)r.���r/���r0���r1���r2���rz���r}���� itertools�country���r{���ru���rt���rF���r(���r���r�����propertyr����rr����setterrQ����classmethodr����rw���r���r���r���r���r������s$��� )r1����_weakrefr���r���r���r���r���r���r���r ����_weakrefsetr ���r����collectionsr����r����r ����__all__r����MutableMappingr���rR���r���r���r���r���r���r����<module>���s"���( 6�i�