Uname: Linux web3.us.cloudlogin.co 5.10.226-xeon-hst #2 SMP Fri Sep 13 12:28:44 UTC 2024 x86_64
Software: Apache
PHP version: 8.1.31 [ PHP INFO ] PHP os: Linux
Server Ip: 162.210.96.117
Your Ip: 3.15.181.250
User: edustar (269686) | Group: tty (888)
Safe Mode: OFF
Disable Function:
NONE

name : compat.cpython-312.pyc
�


f����ddlmZddlZddlZddlZddlZ	ddlZejddkr�ddl	m	Z	e
fZeZ
ddlmZddlZddlZddlmZmZmZmZmZddlmZmZmZmZm Z m!Z!m"Z"d�Zddl#Z#dd	l#m$Z$m%Z%m&Z&m'Z'm(Z(m)Z)m*Z*m+Z+m,Z,erdd
l#m-Z-ddl.Z.ddl/Z/ddl0Z1ddl2m2Z2ddl3Z3e4Z4ddl5m6Z7dd
l5m8Z9n�ddl:m	Z	e;fZe;Z
ddl:m<ZddlZddlZddl=mZmZmZmZmZmZmZm"Z"ddl>m%Z%mZm$Z$mZm Z m(Z(m)Z)m*Z*m+Z+m,Z,erdd
l>m-Z-ddl?m'Z'm&Z&m!Z!ddl@mAZ.ddl>mBZ#ddlCmAZ/ddl1Z1ddlDm2Z2ddlEmFZ3eGZ4ddl5m9Z9e7Z7	ddlmHZHmIZI	ddlmLZM	ddlmOZOddlRmSZTeUeTd�reTZSnddlRmVZWGd �d!eW�ZVGd"�d#eT�ZS	dd$lXmYZYddlZZZ	e[Z[	ej�Z_ej�Z`	dd.lemfZf	dd3lmmnZnejdd4d5kre2�j�Zpndd6lmmpZp	dd7lqmrZr	dd=lwmxZx	dd?lqmyZy	ddDl�m�Z�m�Z�y#e$rdZY���wxYw#e$rGd�deJ�ZIdPd�ZKd�ZHY��wxYw#e$rGd�deN�ZMY��wxYw#e$r!ej�ej�zdfd�ZOY��wxYw#e$rd%�ZYY��wxYw#e\$rdd&l]m^Z^d'�Z[Y��wxYw#ea$r)ej��xsd(Zcecd)k(rd*Zdnd+Zdd,�Z_d-�Z`Y��wxYw#e$r$dd/lgmhZhmiZiej�d0�Zkd1�Zld2�ZfY��5wxYw#e$r
dd3lomnZnY��@wxYw#e$r,dd8lqmsZs	dd9ltmuZvn#e$rdQd:�ZvYnwxYwGd;�d<es�ZrY��CwxYw#e$rdRd>�ZxY��LwxYw#e$r?	dd@lzm{Z|n#e$r	dd@l}m{Z|YnwxYw	ddAl~mZm�Z�m�Z�n#e$rYnwxYwGdB�dCe��ZyY���wxYw#e$rTej�dEe�j�Z�dF�Z�GdG�dHe��Z�dRdI�Z�GdJ�dKe��Z�GdL�dMe��Z�GdN�dOeN�Z�YywxYw)S�)�absolute_importN�)�StringIO)�FileType)�urlparse�
urlunparse�urljoin�urlsplit�
urlunsplit)�urlretrieve�quote�unquote�url2pathname�pathname2url�ContentTooShortError�	splittypec�Z�t|t�r|jd�}t|�S)N�utf-8)�
isinstance�unicode�encode�_quote)�ss �E/usr/local/python-3.12/lib/python3.12/site-packages/distlib/compat.pyr
r
s$���a��!�����!�A��a�y��)	�Request�urlopen�URLError�	HTTPError�HTTPBasicAuthHandler�HTTPPasswordMgr�HTTPHandler�HTTPRedirectHandler�build_opener)�HTTPSHandler)�
HTMLParser)�ifilter)�ifilterfalse)�
TextIOWrapper)rrr	r
rr
rr)
rrrrrr r!r"r#r$)rrr)�filterfalse)�match_hostname�CertificateErrorc��eZdZy)r,N)�__name__�
__module__�__qualname__�rrr,r,]s��rr,c���g}|sy|jd�}|d|dd}}|jd�}||kDrtdt|�z��|s!|j	�|j	�k(S|dk(r|jd�n{|j
d	�s|j
d	�r%|jtj|��n4|jtj|�jd
d��|D]&}|jtj|���(tjdd
j|�zdztj�}	|	j|�S)zpMatching according to RFC 6125, section 6.4.3

        http://tools.ietf.org/html/rfc6125#section-6.4.3
        F�.r�N�*z,too many wildcards in certificate DNS name: z[^.]+zxn--z\*z[^.]*z\Az\.z\Z)�split�countr,�repr�lower�append�
startswith�re�escape�replace�compile�join�
IGNORECASE�match)
�dn�hostname�
max_wildcards�pats�parts�leftmost�	remainder�	wildcards�frag�pats
          r�_dnsname_matchrM`sI��
��������
��#�A�h��a�b�	�)���N�N�3�'�	��}�$�
#�>��b��I�K�
K���8�8�:����!1�1�1�
�s�?�
�K�K�� �
�
 �
 ��
(�H�,?�,?��,G�

�K�K��	�	�(�+�,�
�K�K��	�	�(�+�3�3�E�7�C�D��	)�D��K�K��	�	�$��(�	)��j�j�����D�!1�1�E�9�2�=�=�I���y�y��"�"rc��|std��g}|jdd�}|D]*\}}|dk(s�t||�ry|j|��,|sG|jdd�D]2}|D]+\}}|dk(s�t||�ry|j|��-�4t	|�dkDr.td	|�d
dj
tt|������t	|�dk(rtd	|�d|d
����td��)a=Verify that *cert* (in decoded format as returned by
        SSLSocket.getpeercert()) matches the *hostname*.  RFC 2818 and RFC 6125
        rules are followed, but IP addresses are not accepted for *hostname*.

        CertificateError is raised on failure. On success, the function
        returns nothing.
        ztempty or no certificate, match_hostname needs a SSL socket or SSL context with either CERT_OPTIONAL or CERT_REQUIRED�subjectAltNamer1�DNSN�subject�
commonNamer4z	hostname z doesn't match either of �, z doesn't match rz=no appropriate commonName or subjectAltName fields were found)	�
ValueError�getrMr:�lenr,r@�mapr8)�certrD�dnsnames�san�key�value�subs       rr+r+�s3����>�?�
?����h�h�'��,���	'�J�C���e�|�!�%��2������&�		'�
��x�x�	�2�.�
/��"%�/�J�C���l�*�)�%��:�"� ����.�
/�
/��x�=�1��"�$,�d�i�i��D�(�8K�.L�$N�O�
O���]�a�
�"�$,�h�q�k�$;�<�
<�#�$F�G�
Gr)�SimpleNamespacec��eZdZdZd�Zy)�	ContainerzR
        A generic container for when multiple values need to be returned
        c�:�|jj|�y�N��__dict__�update)�self�kwargss  r�__init__zContainer.__init__�s���M�M� � ��(rN)r.r/r0�__doc__rhr1rrr`r`�s��	�	)rr`)�whichc�h��d�}tjj��r|�|�r�Sy|�.tjj	dtj
�}|sy|j
tj�}tjdk(r�tj|vr |jdtj�tjj	dd�j
tj�}t�fd�|D��r�g}n|D�cgc]}�|z��	}}n�g}t�}|D]m}tjj|�}	|	|vs�'|j|	�|D]1}
tjj!||
�}|||�s�-|ccS�oycc}w)	aKGiven a command, mode, and a PATH string, return the path which
        conforms to the given mode on the PATH, or None if there is no such
        file.

        `mode` defaults to os.F_OK | os.X_OK. `path` defaults to the result
        of os.environ.get("PATH"), or can be overridden with a custom search
        path.

        c��tjj|�xr8tj||�xr tjj	|�Srb)�os�path�exists�access�isdir)�fn�modes  r�
_access_checkzwhich.<locals>._access_check�sA���G�G�N�N�2�&�.�2�9�9�R��+>�.��G�G�M�M�"�-�-�
/rN�PATH�win32r�PATHEXT�c3�x�K�|]1}�j�j|j�����3y�wrb)r9�endswith)�.0�ext�cmds  �r�	<genexpr>zwhich.<locals>.<genexpr>�s(�����H��3�9�9�;�'�'��	�	��4�H�s�7:)rmrn�dirname�environrU�defpathr6�pathsep�sys�platform�curdir�insert�any�set�normcase�addr@)r}rsrnrt�pathext�filesr|�seen�dir�normdir�thefile�names`           rrjrj�sa���	/��7�7�?�?�3���S�$�'��
���<��:�:�>�>�&�"�*�*�5�D����z�z�"�*�*�%���<�<�7�"��y�y��$����A�r�y�y�)��j�j�n�n�Y��3�9�9�"�*�*�E�G�
�H��H�H����.5�6�s��s��6��6��E�E��u���	$�C��g�g�&�&�s�+�G��d�"�����!�$�$�G��7�7�<�<��W�5�D�$�T�4�0�#��$�		$���7s� F/)�ZipFile�	__enter__)�
ZipExtFilec��eZdZd�Zd�Zd�Zy)r�c�N�|jj|j�yrbrc)rf�bases  rrhzZipExtFile.__init__s���M�M� � ����/rc��|Srbr1�rfs rr�zZipExtFile.__enter__����Krc�$�|j�yrb��close�rf�exc_infos  r�__exit__zZipExtFile.__exit__����J�J�LrN)r.r/r0rhr�r�r1rrr�r�s��	0�	�	rr�c��eZdZd�Zd�Zd�Zy)r�c��|Srbr1r�s rr�zZipFile.__enter__$r�rc�$�|j�yrbr�r�s  rr�zZipFile.__exit__'r�rc�J�tj|g|��i|��}t|�Srb)�BaseZipFile�openr�)rf�argsrgr�s    rr�zZipFile.open+s'���#�#�D�:�4�:�6�:�D��d�#�#rN)r.r/r0r�r�r�r1rrr�r�"s��	�	�	$rr�)�python_implementationc��dtjvrytjdk(rytjj	d�ryy)z6Return a string identifying the Python implementation.�PyPy�java�Jython�
IronPython�CPython)r��versionrmr�r;r1rrr�r�4s8���S�[�[� ��
�7�7�f����;�;�!�!�,�/��r)�Callablec�"�t|t�Srb)rr�)�objs r�callabler�Fs���#�x�(�(rr�mbcs�strict�surrogateescapec��t|t�r|St|t�r|jtt
�St
dt|�jz���Nzexpect bytes or str, not %s)	r�bytes�	text_typer�_fsencoding�	_fserrors�	TypeError�typer.��filenames r�fsencoder�ZsN���h��&��O�
��)�
,��?�?�;�	�:�:��9� ��N�3�3�4�5�
5rc��t|t�r|St|t�r|jtt
�St
dt|�jz��r�)	rr�r��decoder�r�r�r�r.r�s r�fsdecoder�csN���h�	�*��O�
��%�
(��?�?�;�	�:�:��9� ��N�3�3�4�5�
5r)�detect_encoding)�BOM_UTF8�lookupzcoding[:=]\s*([-\w.]+)c��|ddj�jdd�}|dk(s|jd�ry|dvs|jd�ry	|S)
z(Imitates get_normal_name in tokenizer.c.N��_�-rzutf-8-)zlatin-1�
iso-8859-1ziso-latin-1)zlatin-1-ziso-8859-1-ziso-latin-1-r�)r9r>r;)�orig_enc�encs  r�_get_normal_namer�tsX���s��m�!�!�#�+�+�C��5���'�>�S�^�^�H�5���:�:��>�>�E�F���rc�6����	�jj�d�d}d}�fd�}��fd�}|�}|jt�r	d�|dd}d}|s|gfS||�}|r||gfS|�}|s||gfS||�}|r|||gfS|||gfS#t$rd�Y�|wxYw)	a?
        The detect_encoding() function is used to detect the encoding that should
        be used to decode a Python source file.  It requires one argument, readline,
        in the same way as the tokenize() generator.

        It will call readline a maximum of twice, and return the encoding used
        (as a string) and a list of any lines (left as bytes) it has read in.

        It detects the encoding from the presence of a utf-8 bom or an encoding
        cookie as specified in pep-0263.  If both a bom and a cookie are present,
        but disagree, a SyntaxError will be raised.  If the encoding cookie is an
        invalid charset, raise a SyntaxError.  Note that if a utf-8 bom is found,
        'utf-8-sig' is returned.

        If no encoding is specified, then the default of 'utf-8' will be returned.
        NFrc�2��	��S#t$rYywxYw)Nr)�
StopIteration)�readlines�r�read_or_stopz%detect_encoding.<locals>.read_or_stop�s"���
��z�!�� �
��
�s�
�	�c����	|jd�}tj|�}|syt
|d�}	t|�}�r?|jdk7r+��
d}t|��dj��}t|��|d	z
}|S#t$r"d}��dj|��}t|��wxYw#t$r0��d|z}t|��dj�|�}t|��wxYw)
Nrz'invalid or missing encoding declarationz{} for {!r}rzunknown encoding: zunknown encoding for {!r}: {}zencoding problem: utf-8z encoding problem for {!r}: utf-8z-sig)
r��UnicodeDecodeError�format�SyntaxError�	cookie_re�findallr�r��LookupErrorr�)�line�line_string�msg�matches�encoding�codec�	bom_foundr�s      ��r�find_cookiez$detect_encoding.<locals>.find_cookie�s.���	
'�#�k�k�'�2�� �'�'��4�G���'���
�3�H�	
'��x�(����:�:��(��'�7��&�c�*�*�A�G�G�$�&��%�c�*�*��F�"���O��?&�
'�?���'�'�.�.�s�H�=�C�!�#�&�&�	
'���
'��#�.��9�C�"�#�&�&�:�@�@� �(�,�C�!�#�&�&�
'�s�B	�B7�	+B4�79C0Trz	utf-8-sig)�__self__r��AttributeErrorr;r�)	r�r��defaultr�r��first�secondr�r�s	`      @@rr�r�s����"	��(�(�-�-�H��	�����	�%	�N������H�%��I��!�"�I�E�!�G���B�;���u�%����e�W�$�$������U�G�#�#��v�&����e�V�_�,�,�����'�'��O�	��H�	�s�B
�
B�B)r=�)r�)�unescape)�ChainMap)�MutableMapping)�recursive_reprc����fd�}|S)zm
            Decorator to make a repr function return fillvalue for a recursive
            call
            c�����t�����fd�}t�d�|_t�d�|_t�d�|_t�di�|_|S)Nc���t|�t�f}|�vr�S�j|�	�|�}�j|�|S#�j|�wxYwrb)�id�	get_identr��discard)rfr[�result�	fillvalue�repr_running�
user_functions   ���r�wrapperz=_recursive_repr.<locals>.decorating_function.<locals>.wrapper�sc����T�(�I�K�/�C��l�*�(�(� �$�$�S�)�2�!.�t�!4��$�,�,�S�1�!�M��%�,�,�S�1�s�A
�
Ar/rir.�__annotations__)r��getattrr/rir.r�)r�r�r�r�s` @�r�decorating_functionz,_recursive_repr.<locals>.decorating_function�sW���"�u��	"�&-�]�L�%I��"�")�-��"C���#*�=�*�#E�� �*1�-�2C�R�+I��'��rr1)r�r�s` r�_recursive_reprr��s���
�,'�&rc��eZdZdZd�Zd�Zd�Zdd�Zd�Zd�Z	d	�Z
d
�Ze�d��Z
ed��Zd
�ZeZd�Zed��Zd�Zd�Zd�Zd�Zd�Zy)r�a�
        A ChainMap groups multiple dicts (or other mappings) together
        to create a single, updateable view.

        The underlying mappings are stored in a list.  That list is public and can
        accessed or updated using the *maps* attribute.  There is no other state.

        Lookups search the underlying mappings successively until a key is found.
        In contrast, writes, updates, and deletions only operate on the first
        mapping.
        c�.�t|�xsig|_y)z�Initialize a ChainMap by setting *maps* to the given mappings.
            If no mappings are provided, a single empty dictionary is used.

            N)�list�maps)rfrs  rrhzChainMap.__init__s��
�T�
�*�r�d�D�Irc��t|��rb)�KeyError�rfr[s  r�__missing__zChainMap.__missing__!s���3�-�rc�r�|jD]	}	||cS|j|�S#t$rY�(wxYwrb)rrr)rfr[�mappings   r�__getitem__zChainMap.__getitem__$sV���9�9�
���"����
��#�#���
�� ����s�*�	6�6Nc��||vr||S|Srbr1�rfr[r�s   rrUzChainMap.get.s�� #�t��4��9�8��8rc�V�tt�j|j��Srb)rVr��unionrr�s r�__len__zChainMap.__len__1s%���{�s�u�{�{������
rc�V�tt�j|j��Srb)�iterr�r
rr�s r�__iter__zChainMap.__iter__5s��������T�Y�Y�/�0�0rc�@��t�fd�|jD��S)Nc3�&�K�|]}�|v���
y�wrbr1)r{�mr[s  �rr~z(ChainMap.__contains__.<locals>.<genexpr>9s�����3�A�s�a�x�3�s��r�rrs `r�__contains__zChainMap.__contains__8s����3����3�3�3rc�,�t|j�Srbrr�s r�__bool__zChainMap.__bool__;s���t�y�y�>�!rc	�t�dj|djtt|j���S)Nz{0.__class__.__name__}({1})rS)r�r@rWr8rr�s r�__repr__zChainMap.__repr__>s.��0�7�7��d�i�i��D�$�)�)� 4�5�7�
7rc�:�|tj|g|����S)z?Create a ChainMap with a single dict created from the iterable.)�dict�fromkeys)�cls�iterabler�s   rrzChainMap.fromkeysCs���t�}�}�X�5��5�6�6rc�x�|j|jdj�g|jdd���S)zHNew ChainMap or subclass with a new copy of maps[0] and refs to maps[1:]rr4N)�	__class__r�copyr�s rr"z
ChainMap.copyHs3��!�4�>�>�$�)�)�A�,�"3�"3�"5�F��	�	�!�"�
�F�Frc�<�|jig|j���S)z;New ChainMap with a new dict followed by all previous maps.�r!rr�s r�	new_childzChainMap.new_childNs��!�4�>�>�"�1�t�y�y�1�1rc�:�|j|jdd�S)zNew ChainMap from maps[1:].r4Nr$r�s r�parentszChainMap.parentsRs��"�4�>�>�4�9�9�Q�R�=�1�1rc�(�||jd|<y)Nr)r)rfr[r\s   r�__setitem__zChainMap.__setitem__Ws�� %�D�I�I�a�L��rc�t�	|jd|=y#t$rtdj|���wxYw)Nr�(Key not found in the first mapping: {!r})rrr�rs  r�__delitem__zChainMap.__delitem__ZsF��
L��I�I�a�L��%���
L��>�E�E�c�J�L�L�
L�s��$7c�n�	|jdj�S#t$rtd��wxYw)zPRemove and return an item pair from maps[0]. Raise KeyError is maps[0] is empty.rz#No keys found in the first mapping.)r�popitemrr�s rr.zChainMap.popitemas<��
F��y�y��|�+�+�-�-���
F��D�E�E�
F�s��4c��	|jdj|g|���S#t$rtdj|���wxYw)zWRemove *key* from maps[0] and return its value. Raise KeyError if *key* not in maps[0].rr+)r�poprr�)rfr[r�s   rr0zChainMap.pophsV��
L�'�t�y�y��|�'�'��3�d�3�3���
L��>�E�E�c�J�L�L�
L�s	�"�$Ac�>�|jdj�y)z'Clear maps[0], leaving maps[1:] intact.rN)r�clearr�s rr2zChainMap.clearps���I�I�a�L��� rrb)r.r/r0rirhrr	rUrrrrr�r�classmethodrr"�__copy__r%�propertyr'r)r,r.r0r2r1rrr�r�
s���
	�	+�	 �	�	9�	�	1�	4�	"�
�	�	7�
�	7�
�	7�
�	7�	G���	2�
�	2�
�	2�	&�	L�	F�	L�	!rr�)�cache_from_sourcec�P�|jd�sJ�|�d}|rd}||zSd}||zS)Nz.pyT�c�o)rz)rn�debug_override�suffixs   rr6r6ysD���}�}�U�#�#�#��!�&�N���F��f�}���F��f�}�r)�OrderedDict)r�)�KeysView�
ValuesView�	ItemsViewc��eZdZdZd�Zejfd�Zejfd�Zd�Zd�Z	d�Z
dd�Zd	�Zd
�Z
d�Zd�Zd
�Zd�Zd�ZeZe�Zefd�Zdd�Zdd�Zd�Zd�Zedd��Zd�Zd�Zd�Zd�Z d�Z!y)r<z)Dictionary that remembers insertion orderc���t|�dkDrtdt|�z��	|j|j
|i|��y#t$rgx|_}||dg|ddi|_Y�6wxYw)z�Initialize an ordered dictionary.  Signature is the same as for
            regular dictionaries, but keyword arguments are not recommended
            because their insertion order is arbitrary.

            r4z$expected at most 1 arguments, got %dN)rVr��_OrderedDict__rootr��_OrderedDict__map�_OrderedDict__update)rfr��kwds�roots    rrhzOrderedDict.__init__�s����4�y�1�}�� F� #�D�	�!*�+�+�
 ����

�D�M�M�4�(�4�(��	"�
 �%'�'���d���t�,��Q����
�
 �s�A�!A*�)A*c�z�||vr-|j}|d}|||gx|d<x|d<|j|<||||�y)z!od.__setitem__(i, y) <==> od[i]=yrr4N)rBrC)rfr[r\�dict_setitemrF�lasts      rr)zOrderedDict.__setitem__�sO���$���{�{���A�w��7;�T�3�6G�G��Q��G�$�q�'�D�J�J�s�O���s�E�*rc�h�|||�|jj|�\}}}||d<||d<y)z od.__delitem__(y) <==> del od[y]r4rN)rCr0)rfr[�dict_delitem�	link_prev�	link_nexts     rr,zOrderedDict.__delitem__�s9��
��s�#�(,�
�
���s�(;�%�I�y�#�$�I�a�L�$�I�a�Lrc#�ZK�|j}|d}||ur|d��|d}||ur�yy�w)zod.__iter__() <==> iter(od)r4r�N�rB�rfrF�currs   rrzOrderedDict.__iter__��<�����;�;�D���7�D��d�"��1�g�
��A�w���d�"���&+�+c#�ZK�|j}|d}||ur|d��|d}||ur�yy�w)z#od.__reversed__() <==> reversed(od)rr�NrOrPs   r�__reversed__zOrderedDict.__reversed__�rRrSc���	|jj�D]}|dd�=�	|j}||dg|dd|jj�t
j|�y#t$rY�!wxYw)z.od.clear() -> None.  Remove all items from od.N)rC�
itervaluesrBr2r�r)rf�noderFs   rr2zOrderedDict.clear�su��
� �J�J�1�1�3� �D��Q�� ��{�{����t�,��Q���
�
� � �"�
�J�J�t���"�
��
�s�AA*�*	A6�5A6c���|std��|j}|r|d}|d}||d<||d<n|d}|d}||d<||d<|d}|j|=tj	||�}||fS)z�od.popitem() -> (k, v), return and remove a (key, value) pair.
            Pairs are returned in LIFO order if last is true or FIFO order if false.

            zdictionary is emptyrr4r�)rrBrCrr0)rfrIrF�linkrLrMr[r\s        rr.zOrderedDict.popitem�s���
��4�5�5��;�;�D���A�w�� ��G�	�#�	�!��#��Q���A�w�� ��G�	�#��Q��#�	�!���q�'�C��
�
�3���H�H�T�3�'�E���:�rc��t|�S)zod.keys() -> list of keys in od)rr�s r�keyszOrderedDict.keys������:�rc�2�|D�cgc]}||��	c}Scc}w)z#od.values() -> list of values in odr1rs  r�valueszOrderedDict.values�s��)-�.�#�D��I�.�.��.s�c�6�|D�cgc]	}|||f��c}Scc}w)z.od.items() -> list of (key, value) pairs in odr1rs  r�itemszOrderedDict.itemss��04�5��S�$�s�)�$�5�5��5s�c��t|�S)z0od.iterkeys() -> an iterator over the keys in od)rr�s r�iterkeyszOrderedDict.iterkeysr]rc#�(K�|D]	}||���y�w)z2od.itervalues -> an iterator over the values in odNr1�rf�ks  rrWzOrderedDict.itervalues
s�����
���1�g�
�
�s�c#�,K�|D]}|||f���
y�w)z=od.iteritems -> an iterator over the (key, value) items in odNr1res  r�	iteritemszOrderedDict.iteritemss#�����
#���$�q�'�l�"�
#�s�c��t|�dkDrtdt|�fz��|std��|d}d}t|�dk(r|d}t|t�r|D]
}||||<�n9t	|d�r|j�D]
}||||<�n|D]
\}}|||<�|j
�D]
\}}|||<�y)	a�od.update(E, **F) -> None.  Update od from dict/iterable E and F.

            If E is a dict instance, does:           for k in E: od[k] = E[k]
            If E has a .keys() method, does:         for k in E.keys(): od[k] = E[k]
            Or if E is an iterable of items, does:   for k, v in E: od[k] = v
            In either case, this is followed by:     for k, v in F.items(): od[k] = v

            r�z8update() takes at most 2 positional arguments (%d given)z,update() takes at least 1 argument (0 given)rr1r4r\N)rVr�rr�hasattrr\ra)r�rErf�otherr[r\s      rrezOrderedDict.updates����4�y�1�}��!7�:=�d�)��!G�H�H��� N�O�O���7�D��E��4�y�A�~��Q����%��&� �+�C� %�c�
�D��I�+����'� �:�:�<�+�C� %�c�
�D��I�+�#(�&�J�C�� %�D��I�&�"�j�j�l�
"�
��U�!��S�	�
"rc�T�||vr
||}||=|S||jurt|��|S)z�od.pop(k[,d]) -> v, remove specified key and return the corresponding value.
            If key is not found, d is returned if given, otherwise KeyError is raised.

            )�_OrderedDict__markerr)rfr[r�r�s    rr0zOrderedDict.pop7s;��
�d�{��c�����I��
��$�-�-�'��s�m�#��NrNc�"�||vr||S|||<|S)zDod.setdefault(k[,d]) -> od.get(k,d), also set od[k]=d if k not in odr1rs   r�
setdefaultzOrderedDict.setdefaultDs!���d�{��C�y� ��D��I��Nrc���|si}t|�t�f}||vryd||<	|s|jj�d�||=S|jj�d|j	��d�||=S#||=wxYw)zod.__repr__() <==> repr(od)�...r4�()�(�))r��
_get_identr!r.ra)rf�
_repr_running�call_keys   rrzOrderedDict.__repr__Ks|�� � "�
��$�x���-�H��=�(��&'�M�(�#�
,��%)�^�^�%<�%<�?�"�(�+�$(�>�>�#:�#:�D�J�J�L�I�!�(�+��M�(�+�s�A0�)A0�0A5c��|D�cgc]	}|||g��}}t|�j�}tt��D]}|j|d��|r|j|f|fS|j|ffScc}w)z%Return state information for picklingN)�varsr"r<r0r!)rfrfra�	inst_dicts    r�
__reduce__zOrderedDict.__reduce__Zs}��+/�0�a�a��a��\�0�E�0��T�
���)�I��+�-�(�
'���
�
�a��&�
'������	�9�=�=��>�>�E�9�,�,��
1s�A9c�$�|j|�S)z!od.copy() -> a shallow copy of od)r!r�s rr"zOrderedDict.copyds���>�>�$�'�'rc�,�|�}|D]}|||<�	|S)z�OD.fromkeys(S[, v]) -> New ordered dictionary with keys from S
            and values equal to v (which defaults to None).

            r1)rrr\�dr[s     rrzOrderedDict.fromkeyshs(����A��
����#��
��Hrc���t|t�r:t|�t|�k(xr!|j�|j�k(Stj||�S)z�od.__eq__(y) <==> od==y.  Comparison to another OD is order-sensitive
            while comparison to a regular mapping is order-insensitive.

            )rr<rVrar�__eq__�rfrks  rr�zOrderedDict.__eq__ssS��
�%��-��4�y�C��%��=�#�z�z�|�u�{�{�}�<�=��;�;�t�U�+�+rc��||k(Srbr1r�s  r�__ne__zOrderedDict.__ne__}s���u�}�$�$rc��t|�S)z@od.viewkeys() -> a set-like object providing a view on od's keys)r=r�s r�viewkeyszOrderedDict.viewkeys�s���D�>�!rc��t|�S)z<od.viewvalues() -> an object providing a view on od's values)r>r�s r�
viewvalueszOrderedDict.viewvalues�s
���d�#�#rc��t|�S)zBod.viewitems() -> a set-like object providing a view on od's items)r?r�s r�	viewitemszOrderedDict.viewitems�s���T�?�"r)Trb)"r.r/r0rirhrr)r,rrUr2r.r\r_rarcrWrhrerD�objectrmr0rorr{r"r3rr�r�r�r�r�r1rrr<r<�s���3�	)�"8<�7G�7G�	+�15�0@�0@�	%�	�	�
	�	�2	�	/�	6�	�	�
	#�
	"�>���8��#+�	�	�
	,�	-�	(�
�	�
�	�	,�	%�
	"�	$�	#rr<)�BaseConfigurator�valid_identz^[a-z_][a-z0-9_]*$c�N�tj|�}|std|z��y)Nz!Not a valid Python identifier: %rT)�
IDENTIFIERrBrT)rrs  rr�r��s)�����Q�����@�1�D�E�E�rc��eZdZdZd�Zdd�Zy)�ConvertingDictz A converting dictionary wrapper.c���tj||�}|jj|�}||ur/|||<t	|�t
ttfvr||_||_	|Srb)
rr	�configurator�convertr�r��ConvertingList�ConvertingTuple�parentr[�rfr[r\r�s    rr	zConvertingDict.__getitem__��f���$�$�T�3�/�E��&�&�.�.�u�5�F��F�"�"��S�	���<�N�N�$3�$5�5�$(�F�M�!$�F�J��MrNc���tj|||�}|jj|�}||ur/|||<t	|�t
ttfvr||_||_	|Srb)
rrUr�r�r�r�r�r�r�r[�rfr[r�r\r�s     rrUzConvertingDict.get�sf���H�H�T�3��0�E��&�&�.�.�u�5�F��F�"�"��S�	���<�N�N�$3�$5�5�$(�F�M�!$�F�J��Mrrb)r.r/r0rir	rUr1rrr�r��s��.�
	�
	rr�c���tj|||�}|jj|�}||ur*t	|�t
ttfvr||_||_	|Srb)
rr0r�r�r�r�r�r�r�r[r�s     rr0r0�s]������s�G�,���"�"�*�*�5�1������F�|��� /� 1�1� $��
� ��
��
rc��eZdZdZd�Zdd�Zy)r�zA converting list wrapper.c���tj||�}|jj|�}||ur/|||<t	|�t
ttfvr||_||_	|Srb)
rr	r�r�r�r�r�r�r�r[r�s    rr	zConvertingList.__getitem__�r�rc��tj||�}|jj|�}||ur#t	|�t
ttfvr||_|Srb)	rr0r�r�r�r�r�r�r�)rf�idxr\r�s    rr0zConvertingList.pop�sT���H�H�T�3�'�E��&�&�.�.�u�5�F��F�"���<�N�N�$3�$5�5�$(�F�M��MrN)���)r.r/r0rir	r0r1rrr�r��s��(�
	�	rr�c��eZdZdZd�Zy)r�zA converting tuple wrapper.c���tj||�}|jj|�}||ur*t	|�t
ttfvr||_||_	|Srb)
�tupler	r�r�r�r�r�r�r�r[r�s    rr	zConvertingTuple.__getitem__�s]���%�%�d�C�0�E��&�&�.�.�u�5�F��F�"���<�N�N�$3�$5�5�$(�F�M�!$�F�J��MrN)r.r/r0rir	r1rrr�r��s
��)�	rr�c��eZdZdZej
d�Zej
d�Zej
d�Zej
d�Z	ej
d�Z
ddd	�Zee
�Zd
�Zd�Zd�Zd
�Zd�Zd�Zd�Zy)r�zQ
        The configurator base class which defines some useful defaults.
        z%^(?P<prefix>[a-z]+)://(?P<suffix>.*)$z^\s*(\w+)\s*z^\.\s*(\w+)\s*z^\[\s*(\w+)\s*\]\s*z^\d+$�ext_convert�cfg_convert)r|�cfgc�F�t|�|_||j_yrb)r��configr�)rfr�s  rrhzBaseConfigurator.__init__s��(��0�D�K�'+�D�K�K�$rc��|jd�}|jd�}	|j|�}|D]}|d|zz
}	t||�}�|S#t$r |j|�t||�}Y�DwxYw#t
$r=t
j�dd\}}td|�d|���}||c|_	|_
|�wxYw)zl
            Resolve strings to objects using standard import and attribute
            syntax.
            r3rr4NzCannot resolve z: )r6r0�importerr�r��ImportErrorr�r�rT�	__cause__�
__traceback__)	rfrr��used�foundrK�e�tb�vs	         r�resolvezBaseConfigurator.resolves���
�7�7�3�<�D��8�8�A�;�D�
��
�
�d�+�� �5�D��C�$�J�&�D�5� '��t� 4��5����*�5��
�
�d�+� '��t� 4��5���
�����q�r�*���2��!�Q�?�@��/0�"�,���Q�_���	
�s0�A?�A�A?�&A<�9A?�;A<�<A?�?ACc�$�|j|�S)z*Default converter for the ext:// protocol.)r��rfr\s  rr�zBaseConfigurator.ext_converts���<�<��&�&rc�r�|}|jj|�}|�td|z��||j�d}|j|j�d}|r�|jj|�}|r||j�d}nb|jj|�}|rE|j�d}|jj|�s||}n	t|�}||}|r||j�d}ntd|�d|����|r��|S#t$r||}Y�<wxYw)z*Default converter for the cfg:// protocol.NzUnable to convert %rrzUnable to convert z at )�WORD_PATTERNrBrT�endr��groups�DOT_PATTERN�
INDEX_PATTERN�
DIGIT_PATTERN�intr�)rfr\�restrr~r��ns       rr�zBaseConfigurator.cfg_convert sD���D��!�!�'�'��-�A��y� �!7�%�!?�@�@��A�E�E�G�H�~���K�K����
�1�
�.����(�(�.�.�t�4�A���a�h�h�j��m�,�� �.�.�4�4�T�:���"#�(�(�*�Q�-�C�#'�#5�#5�#;�#;�C�#@�$%�c�F��!/�(+�(+�)&�A�)*�!��A��#�A�E�E�G�H�~��(�7<�d�*D�E�E�+�0�H��(1�!/�()�#��A�!/�s�)D%�%D6�5D6c�0�t|t�s$t|t�rt|�}||_|St|t�s$t|t
�rt	|�}||_|St|t�s$t|t�rt
|�}||_|St|t�ri|jj|�}|rL|j�}|d}|jj|d�}|r|d}t||�}||�}|S)z�
            Convert values to an appropriate type. dicts, lists and tuples are
            replaced by their converting alternatives. Strings are checked to
            see if they have a conversion format and are converted if they do.
            �prefixNr;)rr�rr�r�rr�r��string_types�CONVERT_PATTERNrB�	groupdict�value_convertersrUr�)rfr\rr~r��	converterr;s       rr�zBaseConfigurator.convertCs
���e�^�4���4�:!�&�u�-��%)��"�$�L�# ��~�6�:��4�<!�&�u�-��%)��"��L� ���7�J�u�e�<T�'��.��%)��"��L��E�<�0��(�(�.�.�u�5������
�A��x�[�F� $� 5� 5� 9� 9�&�$� G�I� �!"�8���$+�D�)�$<�	� )�&� 1���Lrc�@�|jd�}t|�s|j|�}|jdd�}t|D�cgc]}t	|�s�|||f��c}�}|di|��}|r%|j�D]\}}t
|||��|Scc}w)z1Configure an object with a user-supplied factory.rrr3Nr1)r0r�r�rr�ra�setattr)	rfr�r8�propsrfrgr�r�r\s	         r�configure_customz!BaseConfigurator.configure_custom`s����
�
�4� �A��A�;��L�L��O���J�J�s�D�)�E��6�L�a�[��^�A�v�a�y�>�L�M�F��[��[�F��#(�;�;�=�1�K�D�%��F�D�%�0�1��M��Ms�	B�	Bc�<�t|t�rt|�}|S)z0Utility function which converts lists to tuples.)rrr�r�s  r�as_tuplezBaseConfigurator.as_tuplens���%��&��e����LrN)r.r/r0rir<r?r�r�r�r�r�r��staticmethod�
__import__r�rhr�r�r�r�r�r�r1rrr�r��s���	�%�"�*�*�%M�N��!�r�z�z�/�2�� �b�j�j�!2�3��"��
�
�#9�:�
�"��
�
�8�,�
�!� �
�� �
�+��	,�	�.	'�!	�F	�:	�	rr�)r4)rqrb)��
__future__rrmr<�shutilr��sslr��version_infor�
basestringr�rr��typesr�	file_type�__builtin__�builtins�ConfigParser�configparserrrr	r
r�urllibrr
rrrrrr�urllib2rrrrr r!r"r#r$r%�httplib�	xmlrpclib�Queue�queuer&�htmlentitydefs�	raw_input�	itertoolsr'�filterr(r*�io�strr)�urllib.parse�urllib.request�urllib.error�http.client�client�request�
xmlrpc.client�html.parser�
html.entities�entities�inputr+r,rTrMr^r`r�rj�F_OK�X_OK�zipfiler�r�rjr��BaseZipExtFiler�r��	sysconfigr��	NameError�collections.abcr�r�r�r��getfilesystemencodingr�r��tokenizer��codecsr�r�r?r�r��htmlr=�cgir��collectionsr�r��reprlibr�r��importlib.utilr6r<�threadr�ru�dummy_thread�_abcollr=r>r?r�logging.configr�r��Ir�r�r0rr�r�r�r1rr�<module>rs:��'�	�	�
�
������A����!��;�L��I�+�"�'�L�L�G�G�G��
�<�<�<��(����%���I�+�5� ��4�L��I�-���?�?�?�C�C�C��/�F�F�!�$�%��&�*��I�%�
�F�`G�4�D
)�2�A��J+�
�;��$��G�4�	�^�	�$�+�$��.��)��H� 5��{�{�H��{�{�H�Bl(�(�^�����B�Q��&� ��|�$�$�H��L!�$�\�0�H#�'�Tc�<�<��A��
�C���V�^G�
�:�
�/#�b(G�m^G��F�)�)�F�)�)���?����"�'�'�)��=�?��N�
��
��"�)�(�)�)���5�,�#�+�+�-�8��K��f���	�%�	�5�5�-5��D�j(�'���
�
�4�5�I�	�Z(�!j(��`�������J!�*� '�=���'�	'�'��@e!�>�e!�KJ!��^�
��
���F#�9�2���9�8�9��
�;�;���
��
��x#�d�x#�F#��V�a�����0�"�$�$�7�J�����6����0�%��E�6�E�ya�sV�G7�5H�>H"�H8�:I!�I/�J�!J4�(K �K2� L&�'L6�.M=�7H�H�H�H�"H5�4H5�8"I�I�!I,�+I,�/J�?J�*J1�0J1�4%K�K� K/�.K/�2L#�>L�L#�	L�L#�L�L#�"L#�&	L3�2L3�6M:�<M�M:�M�M:�M�M:�
M �M:� M(�%M:�'M(�(M:�9M:�=AO�O
© 2025 GrazzMean