%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/lib/python3.12/__pycache__/
Upload File :
Create Path :
Current File : //usr/lib/python3.12/__pycache__/inspect.cpython-312.pyc

�

���f�����dZdZgd�ZddlZddlZddlZddlZddlZddl	Z
ddlZddlZddl
Z
ddlZddlZddlZddlZddlZddlZddlZddlmZddlmZddlmZmZe�Zej:j=�D]
\ZZ eede z<�[[ [d	Z!ddd
d�d�Z"d
�Z#d�Z$d�Z%d�Z&d�Z'e(ed�rd�Z)nd�Z)e(ed�rd�Z*nd�Z*d�Z+d�Z,d�Z-e.�Z/d�Z0d�Z1d�Z2d�Z3d�Z4d �Z5d!�Z6d"�Z7d#�Z8d$�Z9d%�Z:d&�Z;d'�Z<d(�Z=d)�Z>d*�Z?d�d+�Z@d�d,�ZAed-d.�ZBd/�ZCd0�ZDdd1�d2�ZEd3�ZFd4�ZGd5�ZHd6�ZId7�ZJd8�ZKd9�ZLd:�ZMd�d;�ZNiZOiZPd�d<�ZQGd=�d>eR�ZSGd?�d@ej��ZUdA�ZVdB�ZWGdC�dDeR�ZXGdE�dF�ZYdG�ZZdH�Z[dI�Z\dJ�Z]d�dK�Z^edLdM�Z_dN�Z`edOdP�ZadQ�ZbedRdS�ZcdT�Zdd�dU�ZedV�ZfegdW�dX�dY�fdZ�Zhd[�Zid\�Zjd]�Zked^d_�Zld`�Zmedadb�ZnGdc�dden�Zode�Zpdf�Zqd�dg�Zrdh�Zsedidjeoj�z�ZuGdk�dleu�Zvd�dm�Zwd�dn�Zxdo�Zyd�dp�Zzd�dq�Z{e.�Z|e}j�drj�Z�e}j�dsj�Z�dt�Z�du�Z�e�j�dv��Z�dw�Z�e|fdx�Z�dyZ�dzZ�d{Z�d|Z�d}�Z�d~�Z�dZ�d�Z�d�Z�d�Z�d��Z�d��Z�d�Z�d�Z�d�Z�d�Z�d��Z�d��Z�e�j4e�j6e�j8e�j:fZ�d��Z�d�d��Z�d��Z�d��Z�d��Z�d��Z�d�d��Z�d�d��Z�		d�d��Z�d��Z�d�d�ddd
d��d��Z�Gd��d��Z�Gd��d��Z�Gd��d�e�jX�Z�e��j\Z�e��j`Z�e��jdZ�e��jhZ�e��jlZ�Gd��d��Z�Gd��d��Z�Gd��d��Z�d�ddd
d��d��Z�Gd��d�e�jx�Z�d��Z�e�d�k(re��yy)�aFGet useful information from live Python objects.

This module encapsulates the interface provided by the internal special
attributes (co_*, im_*, tb_*, etc.) in a friendlier fashion.
It also provides some help for examining source code and class layout.

Here are some of the useful functions provided by this module:

    ismodule(), isclass(), ismethod(), isfunction(), isgeneratorfunction(),
        isgenerator(), istraceback(), isframe(), iscode(), isbuiltin(),
        isroutine() - check object types
    getmembers() - get members of an object that satisfy a given condition

    getfile(), getsourcefile(), getsource() - find an object's source code
    getdoc(), getcomments() - get documentation on an object
    getmodule() - determine the module that an object came from
    getclasstree() - arrange classes so as to represent their hierarchy

    getargvalues(), getcallargs() - get info about function arguments
    getfullargspec() - same, with support for Python 3 features
    formatargvalues() - format an argument spec
    getouterframes(), getinnerframes() - get info about frames
    currentframe() - get the current stack frame
    stack(), trace() - get info about frames on the stack or in a traceback

    signature() - get a Signature object for the callable

    get_annotations() - safely compute an object's annotations
)zKa-Ping Yee <ping@lfw.org>z'Yury Selivanov <yselivanov@sprymix.com>)h�AGEN_CLOSED�AGEN_CREATED�AGEN_RUNNING�AGEN_SUSPENDED�ArgInfo�	Arguments�	Attribute�BlockFinder�BoundArguments�BufferFlags�CORO_CLOSED�CORO_CREATED�CORO_RUNNING�CORO_SUSPENDED�CO_ASYNC_GENERATOR�CO_COROUTINE�CO_GENERATOR�CO_ITERABLE_COROUTINE�	CO_NESTED�CO_NEWLOCALS�	CO_NOFREE�CO_OPTIMIZED�
CO_VARARGS�CO_VARKEYWORDS�ClassFoundException�ClosureVars�
EndOfBlock�	FrameInfo�FullArgSpec�
GEN_CLOSED�GEN_CREATED�GEN_RUNNING�
GEN_SUSPENDED�	Parameter�	Signature�TPFLAGS_IS_ABSTRACT�	Traceback�classify_class_attrs�cleandoc�currentframe�
findsource�formatannotation�formatannotationrelativeto�formatargvalues�get_annotations�
getabsfile�getargs�getargvalues�getasyncgenlocals�getasyncgenstate�getattr_static�getblock�getcallargs�getclasstree�getclosurevars�getcomments�getcoroutinelocals�getcoroutinestate�getdoc�getfile�getframeinfo�getfullargspec�getgeneratorlocals�getgeneratorstate�getinnerframes�	getlineno�
getmembers�getmembers_static�	getmodule�
getmodulename�getmro�getouterframes�	getsource�
getsourcefile�getsourcelines�
indentsize�
isabstract�
isasyncgen�isasyncgenfunction�isawaitable�	isbuiltin�isclass�iscode�iscoroutine�iscoroutinefunction�isdatadescriptor�isframe�
isfunction�isgenerator�isgeneratorfunction�isgetsetdescriptor�ismemberdescriptor�ismethod�ismethoddescriptor�ismethodwrapper�ismodule�	isroutine�istraceback�markcoroutinefunction�	signature�stack�trace�unwrap�walktree�N)�	iskeyword)�
attrgetter)�
namedtuple�OrderedDict�CO_iF��globals�locals�eval_strc
��t|t�r�t|dd�}|r;t|d�r/|j	dd�}t|t
j�rd}nd}d}t|dd�}|r/tjj	|d�}|r
t|dd�}tt|��}	|}
npt|t
j�rt|dd�}t|d�}d}	d}
n8t|�rt|dd�}t|dd�}d}	|}
nt|�d���|�iSt|t�st|�d���|siS|st|�S|
�Z	t|
d	�r
|
j}
�t|
t j"�r
|
j$}
�A	t|
d�r|
j&}|�|}|�|	}|j)�D��cic]%\}}|t|t*�s|nt-|||���'}
}}|
Scc}}w)
a�Compute the annotations dict for an object.

    obj may be a callable, class, or module.
    Passing in an object of any other type raises TypeError.

    Returns a dict.  get_annotations() returns a new dict every time
    it's called; calling it twice on the same object will return two
    different but equivalent dicts.

    This function handles several details for you:

      * If eval_str is true, values of type str will
        be un-stringized using eval().  This is intended
        for use with stringized annotations
        ("from __future__ import annotations").
      * If obj doesn't have an annotations dict, returns an
        empty dict.  (Functions and methods always have an
        annotations dict; classes, modules, and other types of
        callables may not.)
      * Ignores inherited annotations on classes.  If a class
        doesn't have its own annotations dict, returns an empty dict.
      * All accesses to object members and dict values are done
        using getattr() and dict.get() for safety.
      * Always, always, always returns a freshly-created dict.

    eval_str controls whether or not values of type str are replaced
    with the result of calling eval() on those values:

      * If eval_str is true, eval() is called on values of type str.
      * If eval_str is false (the default), values of type str are unchanged.

    globals and locals are passed in to eval(); see the documentation
    for eval() for more information.  If either globals or locals is
    None, this function may replace that value with a context-specific
    default, contingent on type(obj):

      * If obj is a module, globals defaults to obj.__dict__.
      * If obj is a class, globals defaults to
        sys.modules[obj.__module__].__dict__ and locals
        defaults to the obj class namespace.
      * If obj is a callable, globals defaults to obj.__globals__,
        although if obj is a wrapped function (using
        functools.update_wrapper()) it is first unwrapped.
    �__dict__N�get�__annotations__�
__module__�__globals__z% is not a module, class, or callable.z+.__annotations__ is neither a dict nor None�__wrapped__)�
isinstance�type�getattr�hasattrrv�types�GetSetDescriptorType�sys�modules�dict�vars�
ModuleType�callable�	TypeError�
ValueErrorrz�	functools�partial�funcry�items�str�eval)�objrqrrrs�obj_dict�ann�obj_globals�module_name�module�
obj_localsrh�key�value�return_values              �/usr/lib/python3.12/inspect.pyr.r.�s��Z�#�t���3�
�D�1�����%�0��,�,�0�$�7�C��#�u�9�9�:����C����c�<��6����[�[�_�_�[�$�7�F��%�f�j�$�?���$�s�)�_�
���	�C��)�)�	*��c�,�d�3���c�:�.���
���	�#���c�,�d�3���c�=�$�7���
����3�'�!F�G�H�H�
�{��	��c�4� ��C�7�"M�N�O�O���	���C�y��
����v�}�-��+�+����&�)�"3�"3�4��������6�=�)� �,�,�K�����
�~����)�)�+�(��C�����s�+���e�W�f�1M�N�(�L�(����(s�*G=c�6�t|tj�S)z&Return true if the object is a module.)r{rr���objects r�rara#����f�e�.�.�/�/�c�"�t|t�S)z%Return true if the object is a class.)r{r|r�s r�rSrS's���f�d�#�#r�c�6�t|tj�S)z0Return true if the object is an instance method.)r{r�
MethodTyper�s r�r^r^+r�r�c��t|�st|�st|�ryt|�}t	|d�xr
t	|d�S)a�Return true if the object is a method descriptor.

    But not if ismethod() or isclass() or isfunction() are true.

    This is new in Python 2.2, and, for example, is true of int.__add__.
    An object passing this test has a __get__ attribute but not a __set__
    attribute, but beyond that the set of attributes varies.  __name__ is
    usually sensible, and __doc__ often is.

    Methods implemented via descriptors that also pass one of the other
    tests return false from the ismethoddescriptor() test, simply because
    the other tests promise more -- you can, e.g., count on having the
    __func__ attribute (etc) when an object passes ismethod().F�__get__�__set__�rSr^rYr|r~�r��tps  r�r_r_/sA���v��(�6�*�j��.@��	
�f��B��2�y�!�@�'�"�i�*@�&@�@r�c��t|�st|�st|�ryt|�}t	|d�xst	|d�S)a}Return true if the object is a data descriptor.

    Data descriptors have a __set__ or a __delete__ attribute.  Examples are
    properties (defined in Python) and getsets and members (defined in C).
    Typically, data descriptors will also have __name__ and __doc__ attributes
    (properties, getsets, and members have both of these attributes), but this
    is not guaranteed.Fr��
__delete__r�r�s  r�rWrWCs>���v��(�6�*�j��.@��	
�f��B��2�y�!�>�W�R��%>�>r��MemberDescriptorTypec�6�t|tj�S)��Return true if the object is a member descriptor.

        Member descriptors are specialized descriptors defined in extension
        modules.)r{rr�r�s r�r]r]S���
�&�%�"<�"<�=�=r�c��y)r�F�r�s r�r]r][���
r�r�c�6�t|tj�S)��Return true if the object is a getset descriptor.

        getset descriptors are specialized descriptors defined in extension
        modules.)r{rr�r�s r�r\r\dr�r�c��y)r�Fr�r�s r�r\r\lr�r�c�6�t|tj�S)a(Return true if the object is a user-defined function.

    Function objects provide these attributes:
        __doc__         documentation string
        __name__        name with which this function was defined
        __code__        code object containing compiled function bytecode
        __defaults__    tuple of any default values for arguments
        __globals__     global namespace in which this function was defined
        __annotations__ dict of parameter annotations
        __kwdefaults__  dict of keyword only parameters with defaults)r{r�FunctionTyper�s r�rYrYss���f�e�0�0�1�1r�c���t|�r|j}t|�r�tj|�}t	|�st|�syt
|jj|z�S)z�Return true if ``f`` is a function (or a method or functools.partial
    wrapper wrapping a function) whose code object has the given ``flag``
    set in its flags.F)	r^�__func__r��_unwrap_partialrY�_signature_is_functionlike�bool�__code__�co_flags)�f�flags  r��_has_code_flagr��sY���1�+�
�J�J���1�+��!�!�!�$�A��q�M�7��:����
�
�#�#�d�*�+�+r�c�"�t|t�S)z�Return true if the object is a user-defined generator function.

    Generator function objects provide the same attributes as functions.
    See help(isfunction) for a list of attributes.)r�r�r�s r�r[r[�s��
�#�|�,�,r�c��t|�r|j}t|�r�tj|�}t	|dd�t
uS)N�_is_coroutine_marker)r^r�r�r�r}r��r�s r��_has_coroutine_markr��sA��
�1�+�
�J�J���1�+��!�!�!�$�A��1�,�d�3�7K�K�Kr�c�L�t|d�r|j}t|_|S)zM
    Decorator to ensure callable is recognised as a coroutine function.
    r�)r~r�r�)r�s r�rdrd�s$���t�Z� ��}�}�� 4�D���Kr�c�<�t|t�xst|�S)z�Return true if the object is a coroutine function.

    Coroutine functions are normally defined with "async def" syntax, but may
    be marked via markcoroutinefunction.
    )r�rr�r�s r�rVrV�s���#�|�,�H�0C�C�0H�Hr�c�"�t|t�S)z�Return true if the object is an asynchronous generator function.

    Asynchronous generator functions are defined with "async def"
    syntax and have "yield" expressions in their body.
    )r�rr�s r�rPrP�s���#�1�2�2r�c�6�t|tj�S)z7Return true if the object is an asynchronous generator.)r{r�AsyncGeneratorTyper�s r�rOrO�s���f�e�6�6�7�7r�c�6�t|tj�S)aReturn true if the object is a generator.

    Generator objects provide these attributes:
        __iter__        defined to support iteration over container
        close           raises a new GeneratorExit exception inside the
                        generator to terminate the iteration
        gi_code         code object
        gi_frame        frame object or possibly None once the generator has
                        been exhausted
        gi_running      set to 1 when generator is executing, 0 otherwise
        next            return the next item from the container
        send            resumes the generator and "sends" a value that becomes
                        the result of the current yield-expression
        throw           used to raise an exception inside the generator)r{r�
GeneratorTyper�s r�rZrZ�s���f�e�1�1�2�2r�c�6�t|tj�S)z)Return true if the object is a coroutine.)r{r�
CoroutineTyper�s r�rUrU�s���f�e�1�1�2�2r�c�
�t|tj�xsht|tj�xr&t	|j
jtz�xs$t|tjj�S)z?Return true if object can be passed to an ``await`` expression.)r{rr�r�r��gi_coder�r�collections�abc�	Awaitabler�s r�rQrQ�se���v�u�2�2�3�
:��v�u�2�2�3�
F��V�^�^�,�,�/D�D�E�
:�
�v�{���8�8�9�;r�c�6�t|tj�S)abReturn true if the object is a traceback.

    Traceback objects provide these attributes:
        tb_frame        frame object at this level
        tb_lasti        index of last attempted instruction in bytecode
        tb_lineno       current line number in Python source code
        tb_next         next inner traceback object (called by this level))r{r�
TracebackTyper�s r�rcrc�s���f�e�1�1�2�2r�c�6�t|tj�S)a`Return true if the object is a frame object.

    Frame objects provide these attributes:
        f_back          next outer frame object (this frame's caller)
        f_builtins      built-in namespace seen by this frame
        f_code          code object being executed in this frame
        f_globals       global namespace seen by this frame
        f_lasti         index of last attempted instruction in bytecode
        f_lineno        current line number in Python source code
        f_locals        local namespace seen by this frame
        f_trace         tracing function for this frame, or None)r{r�	FrameTyper�s r�rXrX�s���f�e�o�o�.�.r�c�6�t|tj�S)a�Return true if the object is a code object.

    Code objects provide these attributes:
        co_argcount         number of arguments (not including *, ** args
                            or keyword only arguments)
        co_code             string of raw compiled bytecode
        co_cellvars         tuple of names of cell variables
        co_consts           tuple of constants used in the bytecode
        co_filename         name of file in which this code object was created
        co_firstlineno      number of first line in Python source code
        co_flags            bitmap: 1=optimized | 2=newlocals | 4=*arg | 8=**arg
                            | 16=nested | 32=generator | 64=nofree | 128=coroutine
                            | 256=iterable_coroutine | 512=async_generator
        co_freevars         tuple of names of free variables
        co_posonlyargcount  number of positional only arguments
        co_kwonlyargcount   number of keyword only arguments (not including ** arg)
        co_lnotab           encoded mapping of line numbers to bytecode indices
        co_name             name with which this code object was defined
        co_names            tuple of names other than arguments and function locals
        co_nlocals          number of local variables
        co_stacksize        virtual machine stack space required
        co_varnames         tuple of names of arguments and local variables)r{r�CodeTyper�s r�rTrT�s��.�f�e�n�n�-�-r�c�6�t|tj�S)a,Return true if the object is a built-in function or method.

    Built-in functions and methods provide these attributes:
        __doc__         documentation string
        __name__        original name of this function or method
        __self__        instance to which a method is bound, or None)r{r�BuiltinFunctionTyper�s r�rRrRs���f�e�7�7�8�8r�c�6�t|tj�S)z.Return true if the object is a method wrapper.)r{r�MethodWrapperTyper�s r�r`r`s���f�e�5�5�6�6r�c��t|�xs2t|�xs%t|�xst|�xst	|�S)z<Return true if the object is any kind of function or method.)rRrYr^r_r`r�s r�rbrbsG���f��
'��&�!�
'����
'�"�&�)�
'��v�&�	(r�c��t|t�sy|jtzryt	t|�t
j�syt|d�ry|jj�D]\}}t|dd�s�y|jD]1}t|dd�D]}t||d�}t|dd�s�y�3y)z:Return true if the object is an abstract base class (ABC).FT�__abstractmethods__�__isabstractmethod__r�N)r{r|�	__flags__r%�
issubclassr��ABCMetar~rur�r}�	__bases__)r��namer��bases    r�rNrNs����f�d�#��
���-�-���d�6�l�C�K�K�0���v�,�-�����,�,�.����e��5�0�%�8���� � ����D�"7��<�	�D��F�D�$�/�E��u�4�e�<��	��
r�c�l�g}t�}t|�}t|�rlt|�}	|jD]P}|j
j
�D]1\}}	t|	tj�s�!|j|��3�Rnd}|D]E}
	|||
�}|
|vrt�	|r||�r|j|
|f�|j|
��G|jd���|S#t$rY�jwxYw#t$r+|D]!}|
|j
vs�|j
|
}nY��Y��wxYw)Nr�c��|dS)Nrjr�)�pairs r��<lambda>z_getmembers.<locals>.<lambda>Ys
��$�q�'�r��r�)�set�dirrSrHr�rur�r{r�DynamicClassAttribute�append�AttributeError�add�sort)r��	predicate�getter�results�	processed�names�mror��k�vr�r�s            r��_getmembersr�2sN���G���I���K�E��v���V�n��	��(�(�
(�� �M�M�/�/�1�(�D�A�q�!�!�U�%@�%@�A����Q��(�
(������
	��6�3�'�E��i��$�$� ��I�e�,��N�N�C��<�(��
�
�c��)�*�L�L�)�L�*��N��5�	��	���	��
���$�-�-�'� �M�M�#�.�E��
��	�		�s0�A	C0�9C0�C?�0	C<�;C<�?D3�D3�2D3c�$�t||t�S)z�Return all members of an object as (name, value) pairs sorted by name.
    Optionally, only return members that satisfy a given predicate.)r�r}�r�r�s  r�rDrD\s���v�y�'�2�2r�c�$�t||t�S)a=Return all members of an object as (name, value) pairs sorted by name
    without triggering dynamic lookup via the descriptor protocol,
    __getattr__ or __getattribute__. Optionally, only return members that
    satisfy a given predicate.

    Note: this function may not be able to retrieve all members
       that getmembers can fetch (like dynamically created attributes)
       and may find members that getmembers can't (like descriptors
       that raise AttributeError). It can also return descriptor objects
       instead of instance members in some cases.
    )r�r4r�s  r�rErEas���v�y�.�9�9r�rzname kind defining_class objectc	�^�t|�}tt|��}td�|D��}|f|z}||z}t|�}|D]]}|jj�D]>\}}t
|tj�s�!|j��.|j|��@�_g}	t�}
|D�]R}d}d}
d}||
vrs	|dk(rtd��t||�}
t|
d|�}||vrEd}d}|D]}t||d�}||
us�|}�|D]}	|j||�}||
us�|}�|�|}	|D]'}||jvs�|j|}||vr|}n|���|
�|
n|}t
|t tj"f�rd}|}nJt
|t$tj&f�rd}|}n%t
|t(�rd}|}nt+|�rd	}nd
}|	jt-||||��|
j/|���U|	S#t$rY��wxYw#t$rY��wxYw)aNReturn list of attribute-descriptor tuples.

    For each name in dir(cls), the return list contains a 4-tuple
    with these elements:

        0. The name (a string).

        1. The kind of attribute this is, one of these strings:
               'class method'    created via classmethod()
               'static method'   created via staticmethod()
               'property'        created via property()
               'method'          any other flavor of method or descriptor
               'data'            not a method

        2. The class which defined this attribute (a class).

        3. The object as obtained by calling getattr; if this fails, or if the
           resulting object does not live anywhere in the class' mro (including
           metaclasses) then the object is looked up in the defining class's
           dict (found by walking the mro).

    If one of the items in dir(cls) is stored in the metaclass it will now
    be discovered and not have None be listed as the class in which it was
    defined.  Any items whose home class cannot be discovered are skipped.
    c3�>K�|]}|ttfvs�|���y�w�N)r|r�)�.0�clss  r��	<genexpr>z'classify_class_attrs.<locals>.<genexpr>�s����H�C�c�$���.G�C�H�s��Nruz)__dict__ is special, don't want the proxy�__objclass__z
static methodzclass method�property�method�data)rHr|�tupler�rur�r{rr��fgetr�r��	Exceptionr}�__getattr__r��staticmethod�BuiltinMethodType�classmethod�ClassMethodDescriptorTyperrbrr�)rr��metamro�class_bases�	all_basesr�r�r�r��resultr�r��homecls�get_obj�dict_obj�last_cls�srch_cls�srch_objr��kinds                    r�r'r'qs���6��+�C��T�#�Y��G��H�7�H�H�G��&�3�,�K��g�%�I���H�E�� ���M�M�'�'�)�	 �D�A�q��!�U�8�8�9�a�f�f�>P����Q��	 � ��F���I��D���������y� �
+��:�%�#�$O�P�P�!�#�t�,��"�'�>�7�C���+�-�#�G�#�H�$/�0��#*�8�T�4�#@��#�w�.�'/�H�0�
%,�0��%�'/�';�';�C��'F�H�$�w�.�'/�H�
0� �+�"*���	�D��t�}�}�$��=�=��.���'�)�"�G��	��?�
� �,�g�(���h��u�/F�/F� G�H�"�D��C�
��;��0O�0O�"P�
Q�!�D��C�
��(�
+��D��C�
�s�^��D��D��
�
�i��d�G�S�9�:��
�
�d��ID�J�M��C .�%�$�%��%�
��
�s$�H �H�	H�H� 	H,�+H,c��|jS)zHReturn tuple of base classes (including cls) in method resolution order.)�__mro__)rs r�rHrH�s���;�;�r���stopc�h�|}t|�|i}tj�}t|t�s~t|d�rr|�||�r	|S|j}t|�}||vst|�|k\rtdj|���|||<t|t�s
t|d�r�r|S)anGet the object wrapped by *func*.

   Follows the chain of :attr:`__wrapped__` attributes returning the last
   object in the chain.

   *stop* is an optional callback accepting an object in the wrapper chain
   as its sole argument that allows the unwrapping to be terminated early if
   the callback returns a true value. If the callback never returns a true
   value, the last object in the chain is returned as usual. For example,
   :func:`signature` uses this to stop unwrapping if any object in the
   chain has a ``__signature__`` attribute defined.

   :exc:`ValueError` is raised if a cycle is encountered.

    rzz!wrapper loop when unwrapping {!r})
�idr��getrecursionlimitr{r|r~rz�lenr��format)r�r r��memo�recursion_limit�id_funcs      r�rhrh�s��� 	
�A�
�q�E�1�:�D��+�+�-�O���t�$���}�)E����T�
���K������T�(���t�O��T��o�!=��@�G�G��J�K�K���W�
���t�$���}�)E��Kr�c�l�|j�}t|�t|j��z
S)zBReturn the indent size, in spaces, at the start of a line of text.)�
expandtabsr$�lstrip)�line�explines  r�rMrMs)���o�o��G��w�<�#�g�n�n�.�/�/�/r�c���tjj|j�}|�y|jjd�ddD]}t
||�}�t|�sy|S)N�.���)r�r�rvrx�__qualname__�splitr}rS)r�rr�s   r��
_findclassr3sb��

�+�+�/�/�$�/�/�
*�C�
�{���!�!�'�'��,�S�b�1�!���c�4� ��!��3�<���Jr�c�r�t|�r.|jD]}|tus�	|j}|��|cSyt|�rb|jj}|j}t|�r'tt||d�d�|jur|}�nR|j}�nDt|�r)|j}t|�}|�t||�|u�ryt|�rR|j}|j}t|�r"|jdz|z|jk(r|}n�|j}n�t|t �r4|j"}|j}t|�}|�t||�|urpyt%|�st'|�rX|j}|j(}t||�|uryt+|�r't|dd�}t|t,�r
||vr||Sy|jD]}	t||�j}|��|cSy#t$rY��wxYw#t$rY�>wxYw)Nr�r/�	__slots__)rSrr��__doc__r�r^r��__name__�__self__r}�	__class__rYr3rRr1r{rrr_rWrr]r�)r�r��docr��selfrr��slotss        r��_finddocr=s���s�|��K�K�	�D��6�!���,�,�C��?��J�	����}��|�|�$�$���|�|���D�M��G�D�$��-�z�:�c�l�l�J��C��.�.�C�	�C���|�|����o���;�'�#�t�,�C�7��	�3���|�|���|�|���D�M�����#�d�*�c�.>�.>�>��C��.�.�C�	�C��	"��x�x���}�}�������;�'�#�t�,�C�7��	�C�	 �$4�S�$9��|�|�������3���S�(���c�"��C��d�3�E��%��&�4�5�=��T�{�"�������	��$��%�-�-�C��?��J�
���m&�����d�	��	�s#�H�;H*�	H'�&H'�*	H6�5H6c��	|j}|�	t|�}t	|t
�syt
|�S#t$rYywxYw#ttf$rYywxYw)z�Get the documentation string for an object.

    All tabs are expanded to spaces.  To clean up docstrings that are
    indented to line up with blocks of code, any whitespace than can be
    uniformly removed from the second line onwards is removed.N)r6r�r=r�r{r�r()r�r:s  r�r<r<Xsk����n�n���{�	��6�"�C��c�3����C�=��������
�	�*�	��	�s �8�A�	A�A�A�Ac�@�	|j�jd�}tj}|ddD]8}t	|j��}|s�t	|�|z
}t
||�}�:|r|dj�|d<|tjkr%tdt	|��D]
}|||d||<�|r|ds|j�|r|ds�|r|ds|jd�|r|ds�dj|�S#t$rYywxYw)z�Clean up indentation from docstrings.

    Any whitespace that can be uniformly removed from the second line
    onwards is removed.�
�Nrjr0)r*r2r��maxsizer$r+�min�range�pop�join�UnicodeError)r:�lines�marginr,�content�indent�is       r�r(r(ks��
 ���� �&�&�t�,��
�����!�"�I�	-�D��$�+�+�-�(�G���T��W�,���V�V�,��		-���Q�x���(�E�!�H��C�K�K���1�c�%�j�)�G��e�A�h�v�w�6G�5��8�G��E�"�I��I�I�K��E�"�I��E�!�H��I�I�a�L��E�!�H��y�y�����)����s�D�	D�Dc���t|�r3t|dd�r|jStdj	|���t|�r�t
|d�r\tjj|j�}t|dd�r|jS|jdk(rtd��tdj	|���t|�r|j}t|�r|j}t!|�r|j"}t%|�r|j&}t)|�r|j*Stdj	t-|�j.���)	z@Work out which source or compiled file an object was defined in.�__file__Nz{!r} is a built-in modulerx�__main__�source code not availablez{!r} is a built-in classzVmodule, class, method, function, traceback, frame, or code object was expected, got {})rar}rNr�r%rSr~r�r�rvrx�OSErrorr^r�rYr�rc�tb_framerX�f_coderT�co_filenamer|r7)r�r�s  r�r=r=�s&������6�:�t�,��?�?�"��3�:�:�6�B�C�C��v���6�<�(��[�[�_�_�V�%6�%6�7�F��v�z�4�0����&�� � �J�.��9�:�:��2�9�9�&�A�B�B���������&�������6�������v������
�f�~��!�!�!�
�7�7=�v���L�)�)�8+�,�,r�c��tjj|�}tjj�D�cgc]}t
|�|f��}}|j�|D]\}}|j|�s�|d|cSycc}w)z1Return the module name for a given file, or None.N)	�os�path�basename�	importlib�	machinery�all_suffixesr$r��endswith)rW�fname�suffix�suffixes�neglens     r�rGrG�s����G�G���T�"�E�#,�"5�"5�"B�"B�"D�F���f�+��v�&�F�H�F��M�M�O�"�"�����>�>�&�!���&�>�!�"���
Fs�B
c�n��t|��tjjdd}|tjjddz
}t�fd�|D��rAtjj��dtjjdz�n-t�fd�tjjD��ry�tjvr�Stjj��r�St|��}t|dd���Stt|dd�dd���Sy)z�Return the filename that can be used to locate an object's source.
    Return None if no way can be identified to get the source.
    Nc3�@�K�|]}�j|����y�wr�r\�r�s�filenames  �r�rz getsourcefile.<locals>.<genexpr>�s�����
?�A�8���Q��
?���rjc3�@�K�|]}�j|����y�wrrcrds  �r�rz getsourcefile.<locals>.<genexpr>�s �����
9�a�X�
�
�q�
!�
9�rg�
__loader__�__spec__�loader)r=rYrZ�DEBUG_BYTECODE_SUFFIXES�OPTIMIZED_BYTECODE_SUFFIXES�anyrVrW�splitext�SOURCE_SUFFIXES�EXTENSION_SUFFIXES�	linecache�cache�existsrFr})r��all_bytecode_suffixesr�rfs   @r�rKrK�s����v��H�%�/�/�G�G��J���Y�0�0�L�L�Q�O�O��
�
?�)>�
?�?��G�G�$�$�X�.�q�1��'�'�7�7��:�;��	�
9��$�$�7�7�
9�
9���9�?�?�"���	�w�w�~�~�h����
�v�x�
(�F��v�|�T�*�6���	����T�2�H�d�	C�	O���
Pr�c��|�t|�xst|�}tjj	tjj|��S)z�Return an absolute path to the source or compiled file for an object.

    The idea is for each object to have a unique origin, so this routine
    normalizes the result as much as possible.)rKr=rVrW�normcase�abspath)r��	_filenames  r�r/r/�s?��
��!�&�)�<�W�V�_�	�
�7�7���B�G�G�O�O�I�6�7�7r�c��t|�r|St|d�r)tjj	|j
�S|�.|tvr&tjj	t|�S	t||�}|tvr&tjj	t|�Stjj�j�D]�\}}t|�s�t|d�s�|j}|tj	|d�k(r�E|t|<t|�}|jxt|<ttj j#|�<��|tvr&tjj	t|�Stjd}t|d�syt||j�rt%||j�}||ur|Stjd}t||j�rt%||j�}	|	|ur|Syy#ttf$rYywxYw)zAReturn the module an object was defined in, or None if not found.rxNrNrOr7�builtins)rar~r�r�rvrx�
modulesbyfiler/r��FileNotFoundError�copyr�rN�_filesbymodnamer7rVrW�realpathr})
r�ry�file�modnamer�r��main�
mainobject�builtin�
builtinobjects
          r�rFrF�s�������
��v�|�$��{�{���v�0�0�1�1����m�!;��{�{���}�Y�7�8�8���&�)�,���}���{�{���}�T�2�3�3��;�;�+�+�-�3�3�5�
7�����F����
� ;����A��O�'�'���6�6��'(�O�G�$��6�"�A�(.���
7�M�!��}���� � ��#� %�
7��}���{�{���}�T�2�3�3��;�;�z�"�D��6�:�&���t�V�_�_�%��T�6�?�?�3�
�����K��k�k�*�%�G��w����(������9�
��F�"��N�#�)��;
�(�)����s�4H5�5I�Ic��eZdZy)rN�r7rxr1r�r�r�rrs��r�rc�"�eZdZd�Zd�ZeZd�Zy)�_ClassFinderc� �g|_||_yr)rf�qualname)r;r�s  r��__init__z_ClassFinder.__init__
s����
� ��
r�c��|jj|j�|jjd�|j|�|jj	�|jj	�y)Nz<locals>)rfr�r��
generic_visitrE)r;�nodes  r��visit_FunctionDefz_ClassFinder.visit_FunctionDefsT���
�
���$�)�)�$��
�
���*�%����4� ��
�
�����
�
���r�c�x�|jj|j�|jdj	|j�k(rB|j
r|j
dj}n|j}|dz}t|��|j|�|jj�y)Nr/rjrA)
rfr�r�r�rF�decorator_list�linenorr�rE)r;r��line_numbers   r��visit_ClassDefz_ClassFinder.visit_ClassDefs����
�
���$�)�)�$��=�=�C�H�H�T�Z�Z�0�0��"�"�"�1�1�!�4�;�;��"�k�k��
�1��K�%�k�2�2����4� ��
�
���r�N)r7rxr1r�r��visit_AsyncFunctionDefr�r�r�r�r�r�s��!��/��
r�r�c�~�t|�}|rtj|�n8t|�}|j	d�r|jd�st
d��t||�}|r!tj||j�}ntj|�}|st
d��t|�r|dfSt|�rZ|j}dj|�}tj|�}t!|�}	|j#|�t
d��t)|�r|j*}t-|�r|j.}t1|�r|j2}t5|�r|j6}t9|�rkt;|d	�st
d
��|j<dz
}
t?j@d�}|
dkDr'	||
}|jE|�r	||
fS|
dz
}
|
dkDr�'||
fSt
d��#t$$r}|j&d}	||	fcYd}~Sd}~wwxYw#tB$rt
d
��wxYw)abReturn the entire source file and starting line number for an object.

    The argument may be a module, class, method, function, traceback, frame,
    or code object.  The source code is returned as a list of all the lines
    in the file and the line number indexes a line in that list.  An OSError
    is raised if the source code cannot be retrieved.�<�>rPzcould not get source coderj�zcould not find class definitionN�co_firstlinenoz"could not find function definitionrAz>^(\s*def\s)|(\s*async\s+def\s)|(.*(?<!\w)lambda(:|\s))|^(\s*@)zlineno is out of boundszcould not find code object)#rKrr�
checkcacher=�
startswithr\rQrF�getlinesrurarSr1rF�ast�parser��visitr�argsr^r�rYr�rcrRrXrSrTr~r��re�compile�
IndexError�match)
r�r�r�rHr��source�tree�class_finder�er��lnum�patr,s
             r�r*r*'s���� �D�����T�"��v�������$����s�);��5�6�6�
�v�t�
$�F�
��"�"�4����9���"�"�4�(����1�2�2�����a�x���v���&�&���������y�y�� ��#�H�-��	=����t�$�
�;�<�<���������&�������6�������v������
�f�~��v�/�0��>�?�?��$�$�q�(���j�j�Z�[���Q�h�
9��T�{���y�y�����d�{���!�8�D��Q�h��d�{��
�.�
/�/��9#�	&��&�&��)�K��+�%�%��	&��,�
9��7�8�8�
9�s*�G>�	H'�>	H$�H�H$�H$�'H<c�*�	t|�\}}t|�r�d}|r
|ddddk(rd}|t	|�kr>||j�dvr)|dz}|t	|�kr||j�dvr�)|t	|�kr{||dddk(rog}|}|t	|�krL||dddk(rA|j
||j��|dz}|t	|�kr||dddk(r�Adj|�Syy|dkD�rwt||�}|dz
}|dk\�r]||j�dddk(�rBt||�|k(�r/||j�j�g}|dkDr�|dz
}||j�j�}|dddk(r]t||�|k(rL|g|dd|dz
}|dkrn;||j�j�}|dddk(rt||�|k(r�L|r4|dj�dk(rg|dd|r|dj�dk(r�|r4|d	j�dk(rg|d	d|r|d	j�dk(r�dj|�Syyyy#ttf$rYywxYw)
zwGet lines of comments immediately preceding an object's source code.

    Returns None when source can't be found.
    Nrj�z#!rA)r��#r�r�r0)r*rQr�rar$�stripr�r*rFrMr+)r�rHr��start�comments�endrK�comments        r�r9r9ks���
� ��(���t�������U�1�X�b�q�\�T�)�1�5��c�%�j� �U�5�\�%7�%7�%9�Y�%F��A�I�E��c�%�j� �U�5�\�%7�%7�%9�Y�%F��3�u�:��%��,�r��"2�c�"9��H��C���E�
�"�u�S�z�"�1�~��'<�����c�
� 5� 5� 7�8��A�g����E�
�"�u�S�z�"�1�~��'<��7�7�8�$�$�
#:��
����E�$�K�(���Q�h���!�8��c�
�)�)�+�B�Q�/�3�6��u�S�z�"�f�,��c�
�-�-�/�6�6�8�9�H��Q�w��A�g����*�/�/�1�8�8�:���b�q�k�S�(�Z��c�
�-C�v�-M�$+�9�H�R�a�L���'�C��Q�w��#�C�j�3�3�5�<�<�>�G�	�b�q�k�S�(�Z��c�
�-C�v�-M�
�x��{�0�0�2�c�9�!���!���x��{�0�0�2�c�9��x��|�1�1�3�s�:� "����
��x��|�1�1�3�s�:��7�7�8�$�$�
-�7�8�
��%
�Y�����s�J�J�Jc��eZdZy)rNr�r�r�r�rr�s�r�rc��eZdZdZd�Zd�Zy)r	z@Provide a tokeneater() method to detect the end of a code block.c�f�d|_d|_d|_d|_d|_d|_d|_y)NrjFrA)rK�islambda�started�passline�indecorator�last�	body_col0�r;s r�r�zBlockFinder.__init__�s4�������
������
� �����	���r�c�R�|js?|js3|dk(rd|_d|_y|dvr|dk(rd|_d|_d|_y|tj
k(r8d|_|d|_|jrt�|jrd|_yy|jry|tjk(r>|j�|jr
|d|_	|jdz|_
d|_y|tjk(r*|jdz
|_
|jdkrt�y|tjk(r+|j�|d|jk\r|d|_yyy|jdk(r)|tjtjfvrt�yy)N�@T)�def�class�lambdar�FrjrA)r�r�r�r��tokenize�NEWLINEr�r�INDENTr�rK�DEDENT�COMMENT�NL)r;r|�token�srowcol�erowcolr,s      r��
tokeneaterzBlockFinder.tokeneater�s����|�|�D�$4�$4���|�#'�� �!�D�M�	�4�4��H�$�$(�D�M�#��� �D�M�
�X�%�%�
%�!�D�M���
�D�I��}�}� � ����#(�� � �
�]�]��
�X�_�_�
$��~�~�%�$�,�,�!(������+�+��/�D�K� �D�M�
�X�_�_�
$��+�+��/�D�K��{�{�a�� � � �
�X�%�%�
%��~�~�)�g�a�j�D�N�N�.J�#�A�J��	�/K�)��[�[�A�
�$�x�/?�/?����.M�"M���#N�
r�N)r7rxr1r6r�r�r�r�r�r	r	�s��J��)r�r	c��t�}	tjt|�j�}|D]}|j
|��	|d|jS#ttf$rY� t$rW}d|jvr|d�^}}	|j
tjg|���n#ttf$rYnwxYwYd}~�zd}~wwxYw)z@Extract the block of code at the top of the given list of lines.�	unmatchedN)r	r��generate_tokens�iter�__next__r�r�IndentationError�SyntaxError�msgr�r�)rH�blockfinder�tokens�_tokenr��_�_token_infos       r�r5r5�s����-�K�
��)�)�$�u�+�*>�*>�?���	,�F�"�K�"�"�F�+�	,��"�+�"�"�#�#��
�(�)�
�����a�e�e�#���� ���K�	�"�K�"�"�8�#3�#3�B�k�B���,�-�	��	���
�sA�>A�C
�+C
�3C�	!B+�*C�+B=�:C�<B=�=C�C
c���t|�}t|�\}}t|�r|j}t	|�s$t|�r|jjdk(r|dfSt||d�|dzfS)a�Return a list of source lines and starting line number for an object.

    The argument may be a module, class, method, function, traceback, frame,
    or code object.  The source code is returned as a list of the lines
    corresponding to the object and the line number indicates where in the
    original source file the first line of code was found.  An OSError is
    raised if the source code cannot be retrieved.z<module>rjNrA)	rhr*rcrRrarXrS�co_namer5�r�rHr�s   r�rLrL�sq���F�^�F��V�$�K�E�4��6������	���	���V�]�]�2�2�j�@��a�x����d�e��%�t�a�x�/�/r�c�@�t|�\}}dj|�S)aReturn the text of the source code for an object.

    The argument may be a module, class, method, function, traceback, frame,
    or code object.  The source code is returned as a single string.  An
    OSError is raised if the source code cannot be retrieved.r�)rLrFr�s   r�rJrJ�s ��!��(�K�E�4�
�7�7�5�>�r�c���g}|jtdd���|D]C}|j||jf�||vs�%|jt	||||���E|S)z-Recursive helper function for getclasstree().rxr7r�)r�rlr�r�ri)�classes�children�parentr��cs     r�ririsg���G��L�L�Z��j�9�L�:�
�?������1�;�;�'�(���=��N�N�8�H�Q�K��1�=�>�?��Nr�c�.�i}g}|D]c}|jr?|jD]/}||vrg||<|||vr||j|�|s�*||vs�/�L�N||vs�S|j|��e|D]}||vs�|j|��t||d�S)a�Arrange the given list of classes into a hierarchy of nested lists.

    Where a nested list appears, it contains classes derived from the class
    whose entry immediately precedes the list.  Each entry is a 2-tuple
    containing a class and a tuple of its base classes.  If the 'unique'
    argument is true, exactly one entry appears in the returned structure
    for each class in the given list.  Otherwise, classes using multiple
    inheritance and their descendants will appear multiple times.N)r�r�ri)r��uniquer��rootsr�r�s      r�r7r7s����H��E�
�	���;�;��+�+�
7����)�')�H�V�$��H�V�,�,��V�$�+�+�A�.��f��/��
7��e�^��L�L��O�	��!���� ��L�L�� �!��E�8�T�*�*r�rzargs, varargs, varkwc��t|�stdj|���|j}|j}|j
}t
|d|�}t
||||z�}||z
}d}|jtzr|j|}|dz}d}|jtzr|j|}t||z||�S)aGet information about the arguments accepted by a code object.

    Three things are returned: (args, varargs, varkw), where
    'args' is the list of argument names. Keyword-only arguments are
    appended. 'varargs' and 'varkw' are the names of the * and **
    arguments or None.z{!r} is not a code objectNrA)rTr�r%�co_varnames�co_argcount�co_kwonlyargcount�listr�rrr)�cor��nargs�nkwargsr��
kwonlyargs�varargs�varkws        r�r0r0)s����"�:��3�:�:�2�>�?�?��N�N�E��N�N�E��"�"�G���f�u�
��D��e�E�%��-�0�1�J�	�W��E��G�	�{�{�Z���.�.��'����	���E�	�{�{�^�#����u�%���T�J�&���7�7r�rzGargs, varargs, varkw, defaults, kwonlyargs, kwonlydefaults, annotationsc	��	t|ddtd��}g}d}d}g}g}i}d}	i}
|j|j
ur|j|d<|jj�D�]}|j}|j}
|tur:|j|
�|j|j
ur�|	|jfz
}	n�|tur:|j|
�|j|j
urg|	|jfz
}	nV|tur|
}nK|tur9|j|
�|j|j
ur|j|
|
<n
|t ur|
}|j"|j
us��|j"||
<��!|
sd}
|	sd}	t%||z|||	||
|�S#t$r}td�|�d}~wwxYw)a$Get the names and default values of a callable object's parameters.

    A tuple of seven things is returned:
    (args, varargs, varkw, defaults, kwonlyargs, kwonlydefaults, annotations).
    'args' is a list of the parameter names.
    'varargs' and 'varkw' are the names of the * and ** parameters or None.
    'defaults' is an n-tuple of the default values of the last n parameters.
    'kwonlyargs' is a list of keyword-only parameter names.
    'kwonlydefaults' is a dictionary mapping names from kwonlyargs to defaults.
    'annotations' is a dictionary mapping parameter names to annotations.

    Notable differences from inspect.signature():
      - the "self" parameter is always reported, even for bound methods
      - wrapper chains defined by __wrapped__ *not* unwrapped automatically
    F)�follow_wrapper_chains�skip_bound_arg�sigclsrszunsupported callableNr��return)�_signature_from_callabler$rr��return_annotation�empty�
parameters�valuesrr��_POSITIONAL_ONLYr��default�_POSITIONAL_OR_KEYWORD�_VAR_POSITIONAL�
_KEYWORD_ONLY�_VAR_KEYWORD�
annotationr)r��sig�exr�r�r��posonlyargsr��annotations�defaults�
kwdefaults�paramrr�s              r�r?r?Gs��� 8�"'�t�=B�6;�.7�05�	7���D��G��E��K��J��K��H��J�
���C�I�I�-� #� 5� 5��H�����&�&�(�1���z�z���z�z���#�#����t�$��}�}�E�K�K�/��U�]�]�,�,��
�+�
+��K�K����}�}�E�K�K�/��U�]�]�,�,��
�_�
$��G�
�]�
"����d�#��}�}�E�K�K�/�#(�=�=�
�4� �
�\�
!��E����5�;�;�.� %� 0� 0�K���-1�0��
�����{�T�)�7�E�8�!�:�{�<�<��g�8�
�.�/�R�7��8�s�F%�%	F?�.F:�:F?rzargs varargs keywords localsc�d�t|j�\}}}t||||j�S)a9Get information about arguments passed into a particular frame.

    A tuple of four things is returned: (args, varargs, varkw, locals).
    'args' is a list of the argument names.
    'varargs' and 'varkw' are the names of the * and ** arguments or None.
    'locals' is the locals dictionary of the given frame.)r0rSr�f_locals)�framer�r�r�s    r�r1r1�s.��#�5�<�<�0��D�'�5��4��%����8�8r�c�X�t|dd�dk(r#d�}tjd|t|��St	|t
j�rt|�St	|t�r8|jd|fvr|jS|jdz|jzSt|�S)Nrx�typingc�D�|j�}|jd�S)Nztyping.)�group�removeprefix)r��texts  r��replzformatannotation.<locals>.repl�s���;�;�=�D��$�$�Y�/�/r�z[\w\.]+r{r/)r}r��sub�reprr{r�GenericAliasr�r|rxr1)r�base_modulers   r�r+r+�s����z�<��.�(�:�	0��v�v�j�$��Z�(8�9�9��*�e�0�0�1��:����*�d�#�� � �Z��$=�=��*�*�*��$�$�S�(��)@�)@�@�@��
��r�c�,��t|dd���fd�}|S)Nrxc���t|��Sr)r+)rr�s �r��_formatannotationz5formatannotationrelativeto.<locals>._formatannotation�s����
�F�3�3r�)r})r�rr�s  @r�r,r,�s���
�V�\�4�
0�F�4��r�c��d|zS)N�*r��r�s r�r�r��s
��s�T�z�r�c��d|zS)N�**r�rs r�r�r��s
��T�D�[�r�c��dt|�zS)N�=)r)r�s r�r�r��s��c�D��K�.?�r�c�<�|||fd�}g}	tt|��D]}
|	j|||
���|r#|	j||�|||�z�|r#|	j||�|||�z�ddj|	�zdzS)afFormat an argument spec from the 4 values returned by getargvalues.

    The first four arguments are (args, varargs, varkw, locals).  The
    next four arguments are the corresponding optional formatting functions
    that are called to turn names and values into strings.  The ninth
    argument is an optional function to format the sequence of arguments.c�*�||�|||�zSrr�)r�rr�	formatarg�formatvalues    r��convertz formatargvalues.<locals>.convert�s������V�D�\�!:�:�:r��(�, �))rDr$r�rF)r�r�r�rrr%�
formatvarargs�formatvarkwr&r'�specsrLs           r�r-r-�s���$�#��;�
�E�
�3�t�9�
�'��
���W�T�!�W�%�&�'��
���]�7�+�k�&��/�.J�J�K��
���[��'�+�f�U�m�*D�D�E�����5�!�!�C�'�'r�c�.�|D�cgc]}||vs�t|���}}t|�}|dk(r|d}n@|dk(rdj|�}n+dj|dd�}|dd�=dj|�|z}t	d|||rd	nd
|dk(rdnd|fz��cc}w)
NrArjr�z	{} and {}z, {} and {}���r)z*%s() missing %i required %s argument%s: %s�
positional�keyword-onlyr�re)rr$r%rFr�)	�f_name�argnames�posr�r�r��missingre�tails	         r��_missing_argumentsr7�s���$,�C�D��F�0B�T�$�Z�C�E�C��%�j�G��!�|��!�H��	�A���K����&��#�}�#�#�U�2�3�Z�0���"�#�J��I�I�e��t�#��
�@��W�&)�l�~�#�q�L�b�c�1�6�6�7�7��
Ds
�	B�
Bc
�v�t|�|z
}t|D�cgc]	}||vs�|��c}�}	|r|dk7}
d|fz}n7|rd}
d|t|�fz}n"t|�dk7}
tt|��}d}|	rd}
|
|dk7rdnd|	|	dk7rdndfz}td|||
rdnd|||dk(r|	s	d	fz��d
fz��cc}w)NrAzat least %dTz
from %d to %dr�z7 positional argument%s (and %d keyword-only argument%s)rez5%s() takes %s positional argument%s but %d%s %s given�was�were)r$r�r�)r2r��kwonlyr��defcount�givenr��atleast�arg�kwonly_given�pluralr�
kwonly_sigr�s              r��	_too_manyrC�s���$�i�(�"�G��v�?������?�@�L���A����w�j�(��	�����#�d�)� 4�4���T��a����#�d�)�n���J��G���E�Q�J�S�B��$0�A�$5�S�2�?�?�
�
�K�
�S��#�R��
��q�j��U�
C�C�D�D�;A�
C�C�D�D��@s
�	B6�B6c	�P�t|�}|\}}}}}}	}
|j}i}t|�r|j�|jf|z}t	|�}
t	|�}|rt	|�nd}t|
|�}t
|�D]
}|||||<�|rt||d�||<t||z�}|ri||<|j�D]=\}}||vr|st|�d|����||||<�%||vrt|�d|����|||<�?|
|kDr|st||||||
|�|
|krH|d||z
}|D]}||vs�t||d|��t|||z
d�D]\}}||vs�||||<�d}|D]}||vs�|	r
||	vr	|	|||<�|dz
}�|rt||d|�|S)z�Get the mapping of arguments to values.

    A dict is returned, with keys the function argument names (including the
    names of the * and ** arguments, if any), and values the respective bound
    values from 'positional' and 'named'.Nrjz&() got an unexpected keyword argument z$() got multiple values for argument TrAF)r?r7r^r8r$rCrDr
r�r�r�rCr7�	enumerate)r�r0�named�specr�r�r�rr��kwonlydefaultsr�r2�	arg2value�num_pos�num_args�num_defaults�nrL�possible_kwargs�kwr��reqr?r5�kwargs                         r�r6r6sD���$��D�FJ�C�D�'�5�(�J���
�]�]�F��I���~�$�-�-�3��m�m�%�
�2�
��*�o�G��4�y�H�$,�3�x�=�!�L��G�X��A�
�1�X�+��'��]�	�$�q�'��+��"�:�a�b�>�2�	�'���$��+�,�O���	�%���[�[�]�
�	��E�
�_�$���!'��!-�.�.�#(�I�e��R� ��
��?��#�R�)�*�
*��	�"�
�
����'��&�$�
�G�\��I�	'�����+�H�|�+�,���	A�C��)�#�"�6�3��i�@�	A� ��X��%<�%=� >�?�	-�F�A�s��)�#�!)�!��	�#��	-��G�����	�!��%�>�"9�#1�%�#8�	�%� ��1������6�:�u�i�@��r�rz"nonlocals globals builtins unboundc��t|�r|j}t|�stdj	|���|j
}|j�i}n=t|j|j�D��cic]\}}||j��}}}|j}|jdtj�}t|�r|j}i}i}t�}	|j D]}
|
dvr�	||
||
<�t'||||	�Scc}}w#t"$r-	||
||
<n #t"$r|	j%|
�YnwxYwY�\wxYw)a
    Get the mapping of free variables to their current values.

    Returns a named tuple of dicts mapping the current nonlocal, global
    and builtin references as seen by the body of the function. A final
    set of unbound names that could not be resolved is also provided.
    �{!r} is not a Python function�__builtins__)�None�True�False)r^r�rYr�r%r��__closure__�zip�co_freevars�
cell_contentsryrvr{rurar��co_names�KeyErrorr�r)r��code�
nonlocal_vars�var�cell�	global_ns�
builtin_ns�global_vars�builtin_vars�
unbound_namesr�s           r�r8r8?sj����~��}�}���d���7�>�>�t�D�E�E��=�=�D������
�!��!1�!1�4�3C�3C�D�	���T�
�$�$�$�$�	�
�	�� � �I����~�x�/@�/@�A�J��
���(�(�
��K��L��E�M��
�
�(���,�,�
�	(� )�$��K���
(��}�k�#�]�4�4��7	��*�	(�
(�%/��%5��T�"���
(��!�!�$�'�
(��	(�s<�;D�;D�	E�#D,�+E�,E	�E�E	�	E�E�
_Tracebackz+filename lineno function code_context indexc�*��eZdZdd��fd�
Zd�Z�xZS)r&N��	positionsc�>��t�|�||||||�}||_|Sr��super�__new__rj)	rrfr��function�code_context�indexrj�instancer9s	        �r�rnzTraceback.__new__ws)����7�?�3��&�(�L�RW�X��&����r�c��dj|j|j|j|j|j
|j�S)NzcTraceback(filename={!r}, lineno={!r}, function={!r}, code_context={!r}, index={!r}, positions={!r}))r%rfr�rorprqrjr�s r��__repr__zTraceback.__repr__|s@��@�@F���
�
�t�{�{�D�M�M�4�;L�;L��
�
�D�N�N�A,�	-r��r7rxr1rnrt�
__classcell__�r9s@r�r&r&vs���SW��
-r�r&c�^�|jj|j}}t||�Sr)rRrS�tb_lasti�_get_code_position)�tbr^�instruction_indexs   r��_get_code_position_from_tbr}�s(�� �k�k�0�0�"�+�+�
�D��d�$5�6�6r�c�t�|dkry|j�}ttj||dzd��S)Nrj)NNNNr�)�co_positions�next�	itertools�islice)r^r|�
positions_gens   r�rzrz�s;���1��'��%�%�'�M��	� � ��0A�Q�0F��M�N�Nr�c
��t|�r$t|�}|j}|j}n,|j}t|j|j�}|d�
||g|dd��^}}n|g|��^}}|d}t|�stdj|���t|�xst|�}|dkDrM|dz
|dzz
}	t|�\}}tdt|t!|�|z
��}||||z}|dz
|z
}ndx}}t%|||jj&||t)j*|���S#t"$rdx}}Y�DwxYw)a�Get information about a frame or traceback object.

    A tuple of five things is returned: the filename, the line number of
    the current line, the function name, a list of lines of context from
    the source code, and the index of the current line within that list.
    The optional second argument specifies the number of lines of context
    to return, which are centered around the current line.rjNrAz'{!r} is not a frame or traceback objectr�ri)rcr}�	tb_linenorR�f_linenorzrS�f_lastirXr�r%rKr=r*�maxrCr$rQr&r��dis�	Positions)	r
�contextrjr�rfr�rHr�rqs	         r�r>r>�sq���5��.�u�5�	�������������&�u�|�|�U�]�]�C�	���|��"�F�;�Y�q�r�]�;���	�"�/�Y�/���	�
�q�\�F��5�>��A�H�H��O�P�P��U�#�5�w�u�~�H���{���
�W�a�Z�'��	'�$�U�+�K�E�4���3�u�c�%�j�7�&:�;�<�E��%��g�
�.�E��Q�J��&�E������X�v�u�|�|�';�';�U��c�m�m�Y�&?�A�A���	!� � �E�E�	!�s�	E�
E�Ec��|jS)zCGet the line number from a frame object, allowing for optimization.)r��r
s r�rCrC�s���>�>�r��
_FrameInfor�c�*��eZdZdd��fd�
Zd�Z�xZS)rNric	�@��t�	|�|||||||�}||_|Srrl)
rr
rfr�rorprqrjrrr9s
         �r�rnzFrameInfo.__new__�s+����7�?�3��x���<�Y^�_��&����r�c	��dj|j|j|j|j|j
|j|j�S)NzoFrameInfo(frame={!r}, filename={!r}, lineno={!r}, function={!r}, code_context={!r}, index={!r}, positions={!r}))r%r
rfr�rorprqrjr�s r�rtzFrameInfo.__repr__�sG��@�@F���
�
�D�M�M�4�;�;��
�
��!�!�4�:�:�t�~�~�A?�	@r�rurws@r�rr�s���Z^��
@r�rc��g}|rEt||�}|f|z}|jt|d|ji��|j}|r�E|S)z�Get a list of records for a frame and all higher (calling) frames.

    Each record contains a frame object, filename, line number, function
    name, a list of lines of context, and index within the context.rj)r>r�rrj�f_back)r
r��	framelist�traceback_info�	frameinfos     r�rIrI�sX��
�I�
�%�e�W�5���H�~�-�	�����I�R��9Q�9Q�R�S�����	�
�r�c��g}|rOt||�}|jf|z}|jt|d|ji��|j
}|r�O|S)z�Get a list of records for a traceback's frame and all lower frames.

    Each record contains a frame object, filename, line number, function
    name, a list of lines of context, and index within the context.rj)r>rRr�rrj�tb_next)r{r�r�r�r�s     r�rBrB�s\��
�I�
�%�b�'�2���[�[�N�^�3�	�����I�R��9Q�9Q�R�S�
�Z�Z��	
�
�r�c�P�ttd�rtjd�SdS)z?Return the frame of the caller or None if this is not possible.�	_getframerAN)r~r�r�r�r�r�r)r)�s��&�s�K�8�3�=�=���B�d�Br�c�@�ttjd�|�S)z@Return a list of records for the stack above the caller's frame.rA)rIr�r�)r�s r�rfrf�s���#�-�-��*�G�4�4r�c�b�tj�}|�dn|j}t||�S)zCReturn a list of records for the stack below the current exception.N)r��	exception�
__traceback__rB)r��excr{s   r�rgrg�s+��

�-�-�/�C����#�"3�"3�B��"�g�&�&r�rruc��i}	tj|d�}tj	||t
�S#t$rY�&wxYw�Nru)r��__getattribute__r�r�rv�	_sentinel)r��attr�
instance_dicts   r��_check_instancer��sG���M�
��/�/��Z�@�
��8�8�M�4��3�3���
��
�s�5�	A�Ac��t|�D]<}tt|��tus�||jvs�-|j|cStSr)�_static_getmro�_shadowed_dictr|r�ru)�klassr��entrys   r��_check_classr�sI����&�(���$�u�+�&�)�3�����8N��>�>�$�'�'�(��r�c��|D]S}t|�}d|vs�|d}t|�tjur|jdk(r|j
|ur�Q|cStSr�)�_get_dunder_dict_of_classr|rr�r7rr�)r�r��dunder_dict�
class_dicts    r��_shadowed_dict_from_mro_tupler�	sj���"��/��6����$�$�Z�0�J���$��(B�(B�B��'�'�:�5��+�+�u�4�!�!�"��r�c�*�tt|��Sr)r�r�)r�s r�r�r�s��(���)>�?�?r�c��t}t|�}tt|�vr=|}t|�}|tust|�tj
urt
||�}n|}t||�}|tur[|turStt|�d�tur8tt|�d�tustt|�d�tur|S|tur|S|tur|S||urStt|��D]<}tt|��tus�||jvs�-|j|cS|tur|St|��)a�Retrieve attributes without triggering dynamic lookup via the
       descriptor protocol,  __getattr__ or __getattribute__.

       Note: this function may not be able to retrieve all attributes
       that getattr can fetch (like dynamically created attributes)
       and may find attributes that getattr can't (like descriptors
       that raise AttributeError). It can also return descriptor objects
       instead of instance members in some cases. See the
       documentation for details.
    r�r�r�)
r�r|r�r�rr�r�r�rur�)	r�r�r��instance_result�objtyper��	dict_attr�klass_resultr�s	         r�r4r4s7�� �O��3�i�G��>�'�*�*���"�5�)�	���"���O�u�9�9�9�-�c�4�8�O�����t�,�L��i�'�L�	�,I���\�*�I�6�i�G���l�+�Y�7�y�H��D��.��=�Y�N����i�'����9�$���
�e�|�#�D��K�0�	,�E��t�E�{�+�y�8��E�N�N�*��~�~�d�+�+�	,��i����
��
�r�r r!r"rc�z�|jrtS|jrtS|j�t
StS)a#Get current state of a generator-iterator.

    Possible states are:
      GEN_CREATED: Waiting to start execution.
      GEN_RUNNING: Currently being executed by the interpreter.
      GEN_SUSPENDED: Currently suspended at a yield expression.
      GEN_CLOSED: Execution has completed.
    )�
gi_runningr!�gi_suspendedr"�gi_framerr )�	generators r�rArAQs:���������������!����r�c��t|�stdj|���t|dd�}|�|jj
SiS)z�
    Get the mapping of generator local variables to their current values.

    A dict is returned, with the keys the local variable names and values the
    bound values.z{!r} is not a Python generatorr�N)rZr�r%r}r�r)r�r
s  r�r@r@csN���y�!��8�?�?�	�J�K�K��I�z�4�0�E����!�!�*�*�*��	r�r
rrrc�z�|jrtS|jrtS|j�t
StS)a&Get current state of a coroutine object.

    Possible states are:
      CORO_CREATED: Waiting to start execution.
      CORO_RUNNING: Currently being executed by the interpreter.
      CORO_SUSPENDED: Currently suspended at an await expression.
      CORO_CLOSED: Execution has completed.
    )�
cr_runningr�cr_suspendedr�cr_framerr
)�	coroutines r�r;r;{s:���������������!����r�c�<�t|dd�}|�|jSiS)z�
    Get the mapping of coroutine local variables to their current values.

    A dict is returned, with the keys the local variable names and values the
    bound values.r�N)r}r)r�r
s  r�r:r:�s'��
�I�z�4�0�E����~�~���	r�rrrrc�z�|jrtS|jrtS|j�t
StS)a3Get current state of an asynchronous generator object.

    Possible states are:
      AGEN_CREATED: Waiting to start execution.
      AGEN_RUNNING: Currently being executed by the interpreter.
      AGEN_SUSPENDED: Currently suspended at a yield expression.
      AGEN_CLOSED: Execution has completed.
    )�
ag_runningr�ag_suspendedr�ag_framerr)�agens r�r3r3�s6�������������}�}�����r�c��t|�st|�d���t|dd�}|�|jjSiS)z�
    Get the mapping of asynchronous generator local variables to their current
    values.

    A dict is returned, with the keys the local variable names and values the
    bound values.z  is not a Python async generatorr�N)rOr�r}r�r)r�r
s  r�r2r2�sH���d���4�(�"B�C�D�D��D�*�d�+�E����}�}�%�%�%��	r�c��|dk(rt||d�}n
t||d�}|�t|t�ry|dk7rt	||�}|S)z�Private helper. Checks if ``cls`` has an attribute
    named ``method_name`` and returns it only if it is a
    pure python function.
    rnN)r}r4r{�_NonUserDefinedCallables�_descriptor_get)r�method_name�meths   r��"_signature_get_user_defined_methodr��sU��
�i���s�K��.���c�;��5���|�z�$�(@�A���i���t�S�)���Kr�c�h�|j}t|j��}|jxsd}|jxsi}|r||z}	|j
|i|��}d}
|j�D�]`\}}	|j|}
|jtur|j|��;|jtur8||vrd}
|j|
��||<n|j|j���|jt ur|j|
��||<	|
s��|jtusJ�|jtur1||jt ��}|||<|j%|���|jt t&fvr|j%|���2|jt(us��F|j|j���c|j|j+���S#t$r"}dj|�}	t|	�|�d}~wwxYw#t"$rY��wxYw)	z�Private helper to calculate how 'wrapped_sig' signature will
    look like after applying a 'functools.partial' object (or alike)
    on it.
    r�z+partial object {!r} has incorrect argumentsNFT)r��r�r�)r�rnr�r��keywords�bind_partialr�r%r��	argumentsrr�rEr��replacer�rr]�move_to_endrrr�)�wrapped_sigr��
extra_args�
old_params�
new_params�partial_args�partial_keywords�barr��transform_to_kwonly�
param_namer
�	arg_value�	new_params               r��_signature_get_partialr��s���'�'�J��Z�-�-�/�0�J��<�<�%�2�L��'�'�-�2���!�L�0��&�
%�[�
%�
%�|�
H�7G�
H�� ��'�-�-�/�0+��
�E�#	J����Z�0�I��z�z�-�-����z�*���z�z�3�3��!1�1�+/�'�-2�]�]�9�]�-M�J�z�*��N�N�5�:�:�.���z�z�]�*�).���y��)I�
�:�&���:�:�%5�5�5�5��z�z�3�3�&�z�2�:�:�
�:�N�	�)2�
�:�&��&�&�z�2����
�|�<�<��&�&�z�2�����.����u�z�z�*�a0+�d���*�*;�*;�*=��>�>��q�&�;�B�B�7�K����o�2�%��&���	��	�s*�G6�:H$�6	H!�?H�H!�$	H1�0H1c�(�t|jj��}|r|djtt
fvrt
d��|dj}|ttfvr|dd}n|turt
d��|j|��S)zWPrivate helper to transform signatures for unbound
    functions to bound methods.
    rjzinvalid method signaturerANzinvalid argument typer�)r
r�r�rrrr�r�r�rr�)r�paramsrs   r��_signature_bound_methodr�/s���
�3�>�>�(�(�*�
+�F��V�A�Y�^�^��m�'D�D��3�4�4��!�9�>�>�D��&�(8�9�9��������&��4�5�5��;�;�&�;�)�)r�c�v�t|�xs-t|�xs t|t�xs|tt
fvS)zxPrivate helper to test if `obj` is a callable that might
    support Argument Clinic's __text_signature__ protocol.
    )rRr_r{r�r|r�r�s r��_signature_is_builtinr�Is@��
�c�N�
"��s�#�
"��s�4�5�
"�

�D�&�>�!�#r�c��t|�rt|�ryt|dd�}t|dd�}t|dt�}t|dt�}t|dd�}t	|t
j�xrXt	|t�xrF|duxst	|t�xr.|duxst	|t�xrt	|t�xs|duS)z�Private helper to test if `obj` is a duck type of FunctionType.
    A good example of such objects are functions compiled with
    Cython, which have all attributes that a pure Python function
    would have, but have their code statically compiled.
    Fr7Nr��__defaults__�__kwdefaults__rw)
r�rSr}�_voidr{rr�r�r
r�)r�r�r^rr	rs      r�r�r�Us����C�=�G�C�L���3�
�D�)�D��3�
�D�)�D��s�N�E�2�H���.��6�J��#�0�$�7�K��t�U�^�^�,�
E��t�S�!�
E�
��
�
<��H�e�!<�
E��4�
�
?�:�j�$�#?�
E���d�
,�
C��t�0C�	Gr�c��|s|dfSd}|jd�D�cgc]}|s�|jd���}}t|�j}t	j|�}g}|j
}d}tj}	tj}
t|�}|jtjk(sJ�|D]P}|j|j}
}||	k(r
|
dk(r|dz
}||	k(r|
dk(r|�J�|}�;||
�|
dk(s�I|d��Rd	j|�j�jdd	�}||fScc}w)
aI
    Private helper function. Takes a signature in Argument Clinic's
    extended signature format.

    Returns a tuple of two things:
      * that signature re-rendered in standard Python syntax, and
      * the index of the "self" parameter (generally 0), or None if
        the function does not have a "self" parameter.
    Nr@�asciirj�,rA�$� r�)r2�encoder�r�r�r�r��OP�
ERRORTOKENr�r|�ENCODING�stringrFr�r�)re�self_parameter�lrHr��token_streamrr��current_parameterr�r��tr|r��clean_signatures               r��"_signature_strip_non_python_syntaxr�nsM����$����N�(1����(=�C�1��Q�X�X�g�
�C�E�C��U��$�$�I��$�$�Y�/�L�
�D�
�+�+�C���	���B��!�!�J�	
�\��A��6�6�X�&�&�&�&�&�
����v�v�q�x�x�f���2�:���}�!�Q�&�!��B�J�V�s�]�!�)�)�)�.�N���F���c�M���H���g�g�d�m�)�)�+�3�3�D�"�=�O��N�*�*��?
Ds
�E�ETc� �����������|j�t|�\}}d|zdz}	tj|�}t|tj�stdj����|jd}g��j�d}i�t�dd�}	|	r.tjj|	d�}|r|j�tjj!��d����fd��G�fd	�d
tj"���f�������fd�	}
t%|j&j(�t%|j&j&�z}|t%|j&j*�z
}t-j.t-j0d|�|j&j*�}
�j2�t5|j&j(|
�D]\}}|
||���j6�t5|j&j&|
�D]\}}|
||��|j&j8r)�j:�|
|j&j8���j<�t5|j&j>|j&j@�D]\}}|
||��|j&jBr)�jD�|
|j&jB��|�\�sJ�t�dd�}|du}tG|�}|r|s|r�jId�n$�djK�j2�
�}
|
�d<|�|j��S#t$rd}Y��IwxYw)zdPrivate helper to parse content of '__text_signature__'
    and return a Signature based on it.
    zdef fooz: passN�"{!r} builtin has invalid signaturerjrxc��t|tj�sJ�|j�t	d��|jS)Nz'Annotations are not currently supported)r{r�r?rr�)r�s r��
parse_namez&_signature_fromstr.<locals>.parse_name�s5���$����(�(�(��?�?�&��F�G�G��x�x�r�c���	t|��}t|tt
ttttd�f�rtj|�St�#t$r$	t|��}n#t$rt�wxYwY�vwxYwr)r��	NameErrorr�r{r��int�float�bytesr�r|r��Constant)rer��module_dict�sys_module_dicts  ��r��
wrap_valuez&_signature_fromstr.<locals>.wrap_value�s����	!���K�(�E��e�c�3��u�d�D��J�G�H��<�<��&�&�����	!�
!��Q��0����
!� � �
!���	!�s)�A�	B�#A0�/B�0B�B�Bc�(��eZdZ�fd�Z�fd�Zd�Zy)�,_signature_fromstr.<locals>.RewriteSymbolicsc�~��g}|}t|tj�rB|j|j�|j
}t|tj�r�Bt|tj�st�|j|j�djt|��}�|�S)Nr/)r{r�rr�r�r��Namer�r"rF�reversed)r;r��arMr�r
s     �r��visit_Attributez<_signature_fromstr.<locals>.RewriteSymbolics.visit_Attribute�s�����A��A��Q��
�
�.������� ��G�G���Q��
�
�.��a����*� � �
�H�H�Q�T�T�N��H�H�X�a�[�)�E��e�$�$r�c���t|jtj�s
t	���|j
�Sr)r{�ctxr��Loadr�r")r;r�r
s  �r��
visit_Namez7_signature_fromstr.<locals>.RewriteSymbolics.visit_Name�s,����d�h�h����1� �l�"��d�g�g�&�&r�c���|j|j�}|j|j�}t|tj
�rt|tj
�st�t|jtj�r,t	j
|j|jz�St|jtj�r,t	j
|j|jz
�St|jtj�r,t	j
|j|jz�St�r)r��left�rightr{r�rr��op�Addr��Sub�BitOr)r;r�rrs    r��visit_BinOpz8_signature_fromstr.<locals>.RewriteSymbolics.visit_BinOp�s����:�:�d�i�i�(�D��J�J�t�z�z�*�E��d�C�L�L�1��E�3�<�<�9X� � ��$�'�'�3�7�7�+��|�|�D�J�J����$<�=�=��D�G�G�S�W�W�-��|�|�D�J�J����$<�=�=��D�G�G�S�Y�Y�/��|�|�D�J�J����$<�=�=��r�N)r7rxr1rrr)r
s�r��RewriteSymbolicsr�s���
	%�	'�

	r�rc����
|�}|r4|tur,	��j|�}tj|�}�	j
�|�|����y#t$rt	dj���d�wxYw)Nr��r�r)�_emptyr�r��literal_evalr�r%r�)�	name_node�default_noder�r�r#rr�rr�r�rs    �������r��pz_signature_fromstr.<locals>.p�s�����)�$���L��6�
]�/�1�7�7��E���*�*�<�8��	���)�D�$��E�R�S���
]� �!E�!L�!L�S�!Q�R�X\�\�
]�s�+A�%Br8r��r�)&�_parameter_clsr�r�r�r�r{�Moduler�r%�bodyr�r}r�r�rvrur~�NodeTransformerr$r�rrr��chain�repeat�POSITIONAL_ONLYrY�POSITIONAL_OR_KEYWORD�vararg�VAR_POSITIONAL�KEYWORD_ONLYr��kw_defaultsrQ�VAR_KEYWORDrarEr�)rr�rer�r�r��programr�r�r�r%�total_non_kw_args�required_non_kw_argsrr�r��_self�self_isbound�
self_ismoduler#rr�rrr�rr	r
s `                 @@@@@@@@@r��_signature_fromstrr:�s�����"�"�I�&H��&K�#�O�^��/�)�H�4�G�����7�#���f�c�j�j�)��=�D�D�S�I�J�J����A��A��J��O�O�E�
�F��K��#�|�T�2�K��������d�3��� �/�/�K��k�k�&�&�(�O����3�.�.��B,1�T�T��A�F�F�.�.�/�#�a�f�f�k�k�2B�B��,�s�1�6�6�?�?�/C�C�����y�/�/��6J�K�Q�V�V�_�_�]�H��$�$�D��q�v�v�1�1�8�<����w�	�$�����*�*�D��q�v�v�{�{�H�5����w�	�$����	�v�v�}�}��'�'��	�!�&�&�-�-����!�!�D��Q�V�V�.�.����0B�0B�C��
��g�	�$����	�v�v�|�|��$�$��	�!�&�&�,�,����!���z���Z��.���D�(�� ���
��]�n��N�N�1���1�
�%�%�9�+D�+D�%�E�A��J�q�M��z�S�Y�Y�7�7�������s�M>�>N
�N
c��t|�stdj|���t|dd�}|st	dj|���t||||�S)zHPrivate helper function to get signature for
    builtin callables.
    z%{!r} is not a Python builtin function�__text_signature__Nz#no signature found for builtin {!r})r�r�r%r}r�r:)rr�r�res    r��_signature_from_builtinr=.	sc��
!��&��#�#)�6�$�<�1�	1�	��*�D�1�A���>�E�E�d�K�L�L��c�4��N�;�;r�c
��d}t|�s(t|�rd}ntdj|���t	|dd�}|rt||||�S|j}|j}	|	j}
|	j}|	j}|d|
}
|	j}||
|
|z}t||||��}|j}|j}|rt|�}nd}g}|
|z
}|}|
d|D]H}|rt nt"}|j%|t&�}|j)||||���|s�D|d	z}�Jt+|
|d�D]O\}}|rt nt"}|j%|t&�}|j)||||||�
��|s�K|d	z}�Q|	j,t.zr<||
|z}|j%|t&�}|j)|||t0���|D]U}t&}|�|j%|t&�}|j%|t&�}|j)|||t2|�
���W|	j,t4zrV|
|z}|	j,t.zr|d	z
}||}|j%|t&�}|j)|||t6���|||j%dt&�|��S)
zCPrivate helper: constructs Signature for the given python function.FTrSr<Nrprj)rrrA)rrr�r��r��__validate_parameters__)rYr�r�r%r}r:r'r�r�r��co_posonlyargcountr�r.r�r�r$r�r�rvr!r�rEr�rrrrr)rr�r�rqrrrs�is_duck_functionrer#�	func_code�	pos_count�	arg_names�
posonly_countr0�keyword_only_count�keyword_onlyrrr	�pos_default_countr��non_default_count�posonly_leftr�rr�offsetr�rqs                             r��_signature_from_functionrM>	s
�����d��%�d�+�#���;�B�B�4�H�I�I���*�D�1�A��!�#�t�Q��?�?��"�"�I��
�
�I��%�%�I��%�%�I��0�0�M��:�I�&�J�"�4�4���Y�y�3E�'E�F�L�!�$���QY�Z�K�� � �H��$�$�J����M�����J�!�$5�5�� �L��-�-�.���#/��5K�� �_�_�T�6�2�
����)�D�Z�)-�/�	0���A��L�
�"�*�->�-?�"@�A�����#/��5K�� �_�_�T�6�2�
����)�D�Z�)-�,4�V�,<�>�	?���A��L�����J�&���%7�7�8�� �_�_�T�6�2�
����)�D�Z�)8�:�	;��6�����!� �n�n�T�6�2�G� �_�_�T�6�2�
����)�D�Z�)6�,3�5�	6�
6����N�*��.�.�����
�*��Q�J�E����� �_�_�T�6�2�
����)�D�Z�)5�7�	8�
�z�!,����6�!B�'7�9�9r�c��t|�r|Stt|�dt�}|tur|S|||t|��S)Nr�)rSr}r|r�)�
descriptorr�rvs   r�r�r��	sD���z����
�$�z�"�I�y�
9�C�
�i�����z�3��S�	�*�*r�)r�r�rqrrrsc	�v�tjt||||||��}t|�st	dj|���t
|tj�r!||j�}|rt|�S|S|r0t|d���}t
|tj�r||�S	|j}|�s|}	t
|ttf�st|�r|�}t
|t�r
t|||�}t
|t�st	dj|	���|S	|j"}
t
|
tj$�r�||
j&�}t)||
d�}t+|j,j/��d}|j0t2j4ur|St+|j,j/��}
|
r	||
dusJ�|f|
z}|j7|�	�St9|�st;|�rt=||||||�
�St?|�rtA|||��St
|tj�r||j&�}t)||�St
|tB��r7tEtC|�d�}|�||�StE|d
�}tE|d�}|jFD]F}|�'d
|jHvr||�}|rt|�}|cS|��/d|jHvs�>||�cS|jFddD] }	|jJ}|s�t|||�cStB|jFvr�|jLtNjLur1|jPtNjPur|jStN�StUdj|���tWtC|�dd�}|�tY||�}||�StUdj|���#t $rY���wxYw#t $rY��"wxYw#t $rY��wxYw)zQPrivate helper function to get signature for arbitrary
    callable objects.
    )r�r�rqrrr�rsz{!r} is not a callable objectc�R�t|d�xst|tj�S)N�
__signature__)r~r{rr�r�s r�r�z*_signature_from_callable.<locals>.<lambda>�	s&��'�!�_�*E�+C�#-�a��1A�1A�#B�r�rNz1unexpected object {!r} in __signature__ attributerrjr�)r�rqrrrs)r��__call__rnr�r0z(no signature found for builtin type {!r}z+callable {!r} is not supported by signature)-r�r�r�r�r�r%r{rr�r�r�rhrRr$r�r:r��_partialmethod�
partialmethodr�r�r
r�r�rr#r0r�rYr�rMr�r=r|r�rrur<r�r�rn�
from_callabler�r4r�)r�r�r�rqrrrsr��_get_signature_ofr�o_sigrUr��first_wrapped_param�
sig_paramsr��call�new�initr��text_sigs                    r�r�r��	sC��"�)�)�*B�6K�/=�(/�'-�'-�)1�
3���C�=��7�>�>�s�C�D�D��#�u�'�'�(� ����-���*�3�/�/��J���S�!C�E���c�5�+�+�,�%�S�)�)�������?��E��c�I�s�#3�4��#���e���#�s�#�(���c�:���c�9�-�� � &��u�
�/�/��J�:��*�*�
��m�Y�%<�%<�=�,�M�,>�,>�?�K�(��m�W�M�C�"'��(>�(>�(E�(E�(G�"H��"K��"�'�'�9�+C�+C�C��
�"�3�>�>�#8�#8�#:�;�
�&�+�:�a�=�@�B�A�1�3�j�@�
��{�{�j�{�9�9��#��4�S�9�(���7E�07��QY�[�	[��S�!�&�v�s�6D�F�	F��#�y�(�(�)�'����1��%�k�3�7�7��#�t��
2�$�s�)�Z�H����$�T�*�*�0��i�@��1�#�z�B���K�K�		/�D���9��
�
�#=�'��,��!�1�#�6�C��
��!�j�D�M�M�&A�(��.�.�		/��K�K���$�	F�D�
F��2�2���.�f�d�H�E�E�!	F�*�s�{�{�"�������/����v�~�~�-��+�+�F�3�3� �>�E�E�c�J�L�L�
�d�3�i��T�:����"�4��-�D�$�T�*�*�
�B�I�I�#�N�
O�O��A�
��
��(�
��
��^"�
��
�s6�4P�6P�-P+�	P�P�	P(�'P(�+	P8�7P8c��eZdZdZy)r�z1A private marker - used in Parameter & Signature.N�r7rxr1r6r�r�r�r�r�X
s��;r�r�c��eZdZdZy)r!z6Marker object for Signature.empty and Parameter.empty.Nr`r�r�r�r!r!\
s��@r�r!c�,�eZdZdZdZdZdZdZd�Zd�Z	y)	�_ParameterKindzpositional-onlyzpositional or keywordzvariadic positionalr1zvariadic keywordc�x�t|j�}tj||�}||_||_|Sr)r$�__members__rrn�_value_�description)rrgr��members    r�rnz_ParameterKind.__new__g
s4���C�O�O�$�����S�%�(�����(����
r�c��|jSrrr�s r��__str__z_ParameterKind.__str__n
s���y�y�r�N)
r7rxr1r-r.r0r1r3rnrjr�r�r�rcrc`
s&��'�O�3��*�N�!�L�$�K��r�rcc��eZdZdZdZeZeZe	Z
eZe
ZeZeed�d�Zd�Zd�Zed��Zed��Zed	��Zed
��Zeeeed�d�Zd
�Zd�Zd�Zd�Zy)r#aRepresents a parameter in a function signature.

    Has the following public attributes:

    * name : str
        The name of the parameter as a string.
    * default : object
        The default value for the parameter if specified.  If the
        parameter has no default value, this attribute is set to
        `Parameter.empty`.
    * annotation
        The annotation for the parameter if specified.  If the
        parameter has no annotation, this attribute is set to
        `Parameter.empty`.
    * kind : str
        Describes how argument values are bound to the parameter.
        Possible values: `Parameter.POSITIONAL_ONLY`,
        `Parameter.POSITIONAL_OR_KEYWORD`, `Parameter.VAR_POSITIONAL`,
        `Parameter.KEYWORD_ONLY`, `Parameter.VAR_KEYWORD`.
    )�_name�_kind�_default�_annotationr c�d�	t|�|_|turJ|jtt
fvr2d}|j
|jj�}t|��||_||_	|turtd��t|t�s/dj
t|�j�}t|��|ddk(rw|ddj�rd|jt k7r2d	}|j
|jj�}t|��t"|_d
j
|dd�}t%|�xr|jt"u}|s|j'�stdj
|���||_y#t$rtd|�d���wxYw)Nzvalue z is not a valid Parameter.kindz({} parameters cannot have default valuesz*name is a required attribute for Parameterzname must be a str, not a {}rjr/rAzLimplicit arguments must be passed as positional or keyword arguments, not {}z
implicit{}z"{!r} is not a valid parameter name)rcrmr�r!rrr%rgrnror{r�r|r7r��isdigitr�r�rk�isidentifierrl)r;r�rr�rr��
is_keywords       r�r�zParameter.__init__�
s���	N�'��-�D�J��&� ��z�z�o�|�<�<�@���j�j����!7�!7�8�� ��o�%���
�%����6�>��I�J�J��$��$�0�7�7��T�
�8K�8K�L�C��C�.� ���7�c�>�d�1�2�h�.�.�0�
�z�z�3�3�>���j�j����!7�!7�8�� ��o�%�)�D�J��&�&�t�A�B�x�0�D��t�_�K����;K�)K�
��T�.�.�0��A�H�H��N�O�O���
��M�	N��v�d�X�-K�L�M�M�	N�s�F�F/c�x�t|�|j|jf|j|jd�fS)N�rnro)r|rlrmrnror�s r��
__reduce__zParameter.__reduce__�
s8���T�
����T�Z�Z�(�!�]�]� $� 0� 0�2�3�	3r�c�,�|d|_|d|_y)Nrnroru�r;�states  r��__setstate__zParameter.__setstate__�
s���j�)��
� ��/��r�c��|jSr)rlr�s r�r�zParameter.name�
����z�z�r�c��|jSr)rnr�s r�r�zParameter.default�
s���}�}�r�c��|jSr)ror�s r�rzParameter.annotation�
������r�c��|jSr)rmr�s r�rzParameter.kind�
r|r�)r�rrr�c���|tur|j}|tur|j}|tur|j}|tur|j}t|�||||��S)z+Creates a customized copy of the Parameter.r )r�rlrmrornr|)r;r�rrr�s     r�r�zParameter.replace�
s_���5�=��:�:�D��5�=��:�:�D�����)�)�J��e���m�m�G��t�D�z�$��g�*�M�Mr�c��|j}|j}|jtur%dj	|t|j��}|jtur]|jtur&dj	|t|j��}n%dj	|t|j��}|tk(rd|z}|S|tk(rd|z}|S)Nz{}: {}z{} = {}z{}={}rr )
rrlror!r%r+rnrrr)r;r�	formatteds   r�rjzParameter.__str__�
s����y�y���J�J�	����6�)� ���	�'7��8H�8H�'I�K�I��=�=��&����v�-�%�,�,�Y��T�]�]�8K�L�	�#�N�N�9�d�4�=�=�6I�J�	��?�"��i��I����\�
!��y�(�I��r�c�N�dj|jj|�S)Nz	<{} "{}">�r%r9r7r�s r�rtzParameter.__repr__s���!�!�$�.�.�"9�"9�4�@�@r�c�p�t|j|j|j|jf�Sr)�hashrlrmrornr�s r��__hash__zParameter.__hash__s(���T�Z�Z����T�-=�-=�t�}�}�M�N�Nr�c��||uryt|t�stS|j|jk(xrO|j|jk(xr4|j
|j
k(xr|j|jk(S�NT)r{r#�NotImplementedrlrmrnro�r;�others  r��__eq__zParameter.__eq__sv���5�=���%��+�!�!��
�
�e�k�k�)�6��
�
�e�k�k�)�6��
�
����/�6�� � �E�$5�$5�5�	7r�N)r7rxr1r6r5r�r-r�r.rr0rr1rr3r!r�r�rvrzrr�r�rrr�r�rjrtr�r�r�r�r�r#r#x
s����*>�I�.�O�4��-�N�+�L�*�K��E�.4��)�V3�0���������� �� �����$�%� �%�N�$�,A�O�7r�r#c�h�eZdZdZdZd�Zed��Zed��Zed��Z	d�Z
d�Zd	�Zd
�Z
d�Zy)
r
a�Result of `Signature.bind` call.  Holds the mapping of arguments
    to the function's parameters.

    Has the following public attributes:

    * arguments : dict
        An ordered mutable mapping of parameters' names to arguments' values.
        Does not contain arguments' default values.
    * signature : Signature
        The Signature object that created this instance.
    * args : tuple
        Tuple of positional arguments values.
    * kwargs : dict
        Dict of keyword arguments values.
    )r��
_signature�__weakref__c� �||_||_yr)r�r�)r;rer�s   r�r�zBoundArguments.__init__)s��"���#��r�c��|jSr)r�r�s r�rezBoundArguments.signature-s�����r�c�|�g}|jjj�D]o\}}|jtt
fvrt|�S	|j|}|jtk(r|j|��_|j|��qt|�S#t$rYt|�SwxYwr)r�r�r�rrrr�r�extendr�r]r
)r;r�r�r
r?s     r�r�zBoundArguments.args1s�����!%���!;�!;�!A�!A�!C�	%��J���z�z�l�M�:�:�� �T�{��
%��n�n�Z�0���:�:��0��K�K��$��K�K��$�!	%�$�T�{����
���T�{��
�s�B$�$	B;�:B;c�Z�i}d}|jjj�D]p\}}|s,|jtt
fvrd}n||jvrd}�4|s�7	|j|}|jtk(r|j|��l|||<�r|S#t$rY��wxYw)NFT)	r�r�r�rrrr��updater])r;�kwargs�kwargs_startedr�r
r?s      r�r�zBoundArguments.kwargsHs�������!%���!;�!;�!A�!A�!C�	-��J��!��:�:�,�
�!>�>�%)�N�!����7�)-�� �!��

-��n�n�Z�0���:�:��-��M�M�#�&�*-�F�:�&�-	-�0�
���
��
�s�!B�	B*�)B*c��|j}g}|jjj�D]\}}	|j	|||f��t|�|_y#t
$ra|jtur
|j}n,|jturd}n|jturi}nY��|j	||f�Y��wxYw)z�Set default values for missing arguments.

        For variable-positional arguments (*args) the default is an
        empty tuple.

        For variable-keyword arguments (**kwargs) the default is an
        empty dict.
        r�N)r�r�r�r�r�r]r�r!rrrr�)r;r��
new_argumentsr�r
�vals      r��apply_defaultszBoundArguments.apply_defaultsfs����N�N�	��
��?�?�5�5�;�;�=�	2�K�D�%�

2��$�$�d�I�d�O�%<�=�	2��m�,�����
2��=�=��.��-�-�C��Z�Z�?�2��C��Z�Z�<�/��C���$�$�d�C�[�1�
2�s�A#�#AC
�7C
�C
c��||uryt|t�stS|j|jk(xr|j|jk(Sr�)r{r
r�rer�r�s  r�r�zBoundArguments.__eq__�sF���5�=���%��0�!�!����%�/�/�1�2����%�/�/�1�	3r�c�,�|d|_|d|_y)Nr�r��r�r�rxs  r�rzzBoundArguments.__setstate__�s����-����{�+��r�c�4�|j|jd�S)Nr�r�r�s r��__getstate__zBoundArguments.__getstate__�s��"�o�o�D�N�N�K�Kr�c��g}|jj�D]&\}}|jdj||���(dj|jj
dj
|��S)Nz{}={!r}z	<{} ({})>r))r�r�r�r%r9r7rF)r;r�r?r�s    r�rtzBoundArguments.__repr__�se�����.�.�.�.�0�	6�J�C���K�K�	�(�(��e�4�5�	6��!�!�$�.�.�"9�"9�4�9�9�T�?�K�Kr�N)r7rxr1r6r5r�rrer�r�r�r�rzr�rtr�r�r�r
r
sj��� ;�I�$���������,����:-�83�,�L�Lr�r
c��eZdZdZdZeZeZe	Z
de	dd�d�Zeddddd�d	��Z
ed
��Zed��Zeed�d
�Zd�Zd�Zd�Zdd�d�Zd�Zd�Zd�Zd�Zd�Zd�Zy)r$aA Signature object represents the overall signature of a function.
    It stores a Parameter object for each parameter accepted by the
    function, as well as information specific to the function itself.

    A Signature object has the following public attributes and methods:

    * parameters : OrderedDict
        An ordered mapping of parameters' names to the corresponding
        Parameter objects (keyword-only arguments are in the same order
        as listed in `code.co_varnames`).
    * return_annotation : object
        The annotation for the return type of the function if specified.
        If the function has no annotation for its return type, this
        attribute is set to `Signature.empty`.
    * bind(*args, **kwargs) -> BoundArguments
        Creates a mapping from positional and keyword arguments to
        parameters.
    * bind_partial(*args, **kwargs) -> BoundArguments
        Creates a partial mapping from positional and keyword arguments
        to parameters (simulating 'functools.partial' behavior.)
    )�_return_annotation�_parametersNTr?c��|�t�}n�|r�t�}t}d}|D]�}|j}|j}	||kr3d}
|
j	|j
|j
�}
t
|
��||kDr|}|ttfvr#|jtur|rd}
t
|
��d}|	|vrdj	|	�}
t
|
��|||	<��ntd�|D��}tj|�|_||_
y)z�Constructs Signature from the given list of Parameter
        objects and 'return_annotation'.  All arguments are optional.
        NFz7wrong parameter order: {} parameter before {} parameterz-non-default argument follows default argumentTzduplicate parameter name: {!r}c3�8K�|]}|j|f���y�wrr�rr
s  r�rz%Signature.__init__.<locals>.<genexpr>�s����$Q�U�e�j�j�%�%8�$Q�s�)rnr�rr�r%rgr�r�r�r!r�MappingProxyTyper�r�)r;r�r�r@r��top_kind�seen_defaultr
rr�r�s           r�r�zSignature.__init__�s���� �]�F�&�$���+��$��'�)�E� �:�:�D� �:�:�D��h��(��"�j�j��)=�)=�)-�)9�)9�;��(��o�-����#'��� 0�2H�I�I� �=�=�F�2�+�'1��&0��o� 5�,0�L��v�~�>�E�E�d�K��(��o�-�#(�F�4�L�?)�B%�$Q�j�$Q�Q�� �1�1�&�9���"3��r�F��follow_wrappedrqrrrsc�$�t||||||��S)z3Constructs Signature for the given callable object.)r�r�rqrrrs)r�)rr�r�rqrrrss      r�rVzSignature.from_callable�s"��(��C�>L�07��QY�[�	[r�c��|jSr)r�r�s r�r�zSignature.parameters�rr�c��|jSr�r�r�s r�r�zSignature.return_annotation�s���&�&�&r�)r�r�c��|tur|jj�}|tur|j}t	|�||��S)z�Creates a customized copy of the Signature.
        Pass 'parameters' and/or 'return_annotation' arguments
        to override them in the new copy.
        r&)r�r�r�r�r|)r;r�r�s   r�r�zSignature.replace�sJ��������/�/�1�J���%� $� 7� 7���t�D�z�*�,=�?�	?r�c��td�|jj�D��}|jj�D�cic]"}|jtk(r
|j
|��$}}|||jfScc}w)Nc3�FK�|]}|jtk7r|���y�wr)rrr�s  r�rz(Signature._hash_basis.<locals>.<genexpr>
s#����=�� %�
�
�m� ;��=�s�!)r
r�r�rrr�r�)r;r�r
�
kwo_paramss    r��_hash_basiszSignature._hash_basis	s����=�$�/�/�*@�*@�*B�=�=��6:�_�_�5K�5K�5M�H�E�+0�:�:��+F��j�j�%�'�H�
�H��z�4�#9�#9�9�9��Hs�'A?c�x�|j�\}}}t|j��}t|||f�Sr)r��	frozensetr�r�)r;r�r�r�s    r�r�zSignature.__hash__s>��04�0@�0@�0B�-��
�-��z�0�0�2�3�
��V�Z�):�;�<�<r�c�z�||uryt|t�stS|j�|j�k(Sr�)r{r$r�r�r�s  r�r�zSignature.__eq__s9���5�=���%��+�!�!����!�U�%6�%6�%8�8�8r��r�c	���i}t|jj��}d}t|�}		t|�}	t|�}	|	jt
tfvrtd�d�|	jtk(r-|g}
|
j|�t|
�||	j<nW|	j|vr9|	jtk7r&tdj|	j���d�|||	j<��d}
t#j$||�D]�}	|	jt
k(r|	}
�|	jtk(r�-|	j}	|j'|�}|	jtk(r%tdj|	j����|||<��|r?|
�|||
j<n-tdjtt|������|j+||�S#t$r
td�d�wxYw#t$r�	t|�}	|	jtk(rY��9|	j|vrC|	jtk(r*d}|j|	j��}t|�d�|	f}Y���|	jt
k(s|	jt ur|	f}Y���|r|	f}Y���|	jtk(rd}nd}d	}|j|	j|�
�}t|�d�#t$rYY��
wxYwwxYw#t($rG|sA|	jtk7r.|	jt urtdj|���d�Y��LwxYw)
z#Private method. Don't use directly.r�ztoo many positional argumentsNz$multiple values for argument {arg!r})r?zA{arg!r} parameter is positional only, but was passed as a keywordz
 keyword-onlyr�z-missing a required{argtype} argument: {arg!r})r?�argtypez$missing a required argument: {arg!r}z*got an unexpected keyword argument {arg!r})r�r�r�r�rrrr�rr�r
r�r�r%�
StopIterationr�r!r�r+rEr]�_bound_arguments_cls)r;r�r�r�r�r��
parameters_ex�arg_vals�arg_valr
r�r�r��kwargs_paramr�s               r��_bindzSignature._binds����	��$�/�/�0�0�2�3�
��
���:���G
4��x�.��Z4� ��,�E��z�z�l�M�%B�B�(�;�=�BF�G��z�z�_�4�#*����
�
�h�/�05�f�
�	�%�*�*�-���z�z�V�+��
�
�>N�0N�'�B�I�I�$)�J�J�J�0�1�6:�;�-4�I�e�j�j�)�U�\���_�_�]�J�?�"	0�E��z�z�\�)�$����z�z�_�,�����J�
0� �*�*�Z�0���:�:�!1�1�$�%B�$*�F�u�z�z�F�$:�<�<�)0�	�*�%�E"	0�H��'�/5�	�,�+�+�,��@�G�G� ��f��.�H�0�1�1��(�(��y�9�9��S%�O�#�$C�D�$�N�O��]!�)
;�';� ��,�E��z�z�_�4�����v�-� �:�:�)9�9�#@�C�"%�*�*����*�"<�C�"+�C�.�d�:�).��
���*�*��4�05�
�
�V�0K�*/��
��#�-2�H�M�!�$�z�z�]�:�*9��*,��"Q�C�"%�*�*����W�*�"M�C�"+�C�.�d�:��K%�����	)
;��r�
F�
 �E�J�J�/�$A�49�M�M�V�4K�#�$J�$*�F�z�F�$:�<�AE�F��
F�sh�H�G<�L�<H�	L�L�*L�AL�(L�<L�AL�	L�L�L�L�AM,�+M,c�&�|j||�S)z�Get a BoundArguments object, that maps the passed `args`
        and `kwargs` to the function's signature.  Raises `TypeError`
        if the passed arguments can not be bound.
        �r��r;r�r�s   r��bindzSignature.bind�s��
�z�z�$��'�'r�c�*�|j||d��S)z�Get a BoundArguments object, that partially maps the
        passed `args` and `kwargs` to the function's signature.
        Raises `TypeError` if the passed arguments can not be bound.
        Tr�r�r�s   r�r�zSignature.bind_partial�s��
�z�z�$���z�5�5r�c�z�t|�t|jj��fd|jifS�Nr�)r|r
r�r�r�r�s r�rvzSignature.__reduce__�s=���T�
��t�'�'�.�.�0�1�3�%�t�'>�'>�?�A�	Ar�c��|d|_yr�r�rxs  r�rzzSignature.__setstate__�s��"'�(<�"=��r�c�N�dj|jj|�S)Nz<{} {}>r�r�s r�rtzSignature.__repr__�s�������� 7� 7��>�>r�c��g}d}d}|jj�D]u}t|�}|j}|tk(rd}n|r|jd�d}|tk(rd}n|tk(r|r|jd�d}|j|��w|r|jd�djdj|��}|jtur)t|j�}|dj|�z
}|S)NFT�/rz({})r)z -> {})
r�r�r�rr�r�rrr%rFr�r!r+)	r;r�render_pos_only_separator�render_kw_only_separatorr
r�r�rendered�annos	         r�rjzSignature.__str__�s����$)�!�#'� ��_�_�+�+�-�	%�E��E�
�I��:�:�D��'�'�,0�)�*��
�
�c�"�,1�)���&�,1�(���&�+C��
�
�c�"�,1�(��M�M�)�$�5	%�8%�
�M�M�#���=�=����6�!2�3���!�!��/�#�D�$:�$:�;�D������-�-�H��r�r)r7rxr1r6r5r#r'r
r�r!r�r�rrVrr�r�r�r�r�r�r�r�r�r�rvrzrtrjr�r�r�r$r$�s����,6�I��N�)���E�24�V�)-�24�h�%)�4��u�[��[�� �� ��'��'�%*�U�
?�:�=�
9�.3�E:�N(�6�A�
>�?�+r�r$r�c�6�tj|||||��S)z/Get a signature object for the passed callable.r�)r$rV)r�r�rqrrrss     r�rere�s'���"�"�3�~�+2�6�H�#�V�Vr�c��eZdZdZdZdZdZdezZdezZdezZ	dezZ
d	ezZeezZeZ
eezZeZeezezZeezZeezezZeezZd	Zd
Zy)rrjrA���� �@��iN)r7rxr1�SIMPLE�WRITABLE�FORMAT�ND�STRIDES�C_CONTIGUOUS�F_CONTIGUOUS�ANY_CONTIGUOUS�INDIRECT�CONTIG�	CONTIG_RO�STRIDED�
STRIDED_RO�RECORDS�
RECORDS_RO�FULL�FULL_RO�READ�WRITEr�r�r�rr�s���
�F��H�
�F�	�B��R�i�G��'�>�L��'�>�L��G�^�N��w��H�
�(�]�F��I��� �G��J��� �6�)�G��6�!�J��h���'�D����G��D��Er�rc� �ddl}ddl}|j�}|jdd��|jdddd	�
�|j	�}|j
}|j
d�\}}}	|j|�x}}	|r&|j!d�}	}|D]}
t#||
�}�	jtj$vr0tdtj�
�tjd�|j&r�tdj|��tdjt)|	���tdj|	j*��|	ur^tdjt-|	j.���t1|	d�rNtdj|	j2��n)	t5|�\}}tdj|��td�ytt7��y#t$ra}
dj|t|
�j|
�}t|tj�
�tjd�Yd}
~
���d}
~
wwxYw#t$rY��wxYw)z6 Logic for inspecting an object given at command line rjNr�zCThe object to be analysed. It supports the 'module:qualname' syntax)�helpz-dz	--details�
store_truez9Display info about the module rather than its source code)�actionr��:zFailed to import {} ({}: {}))r�r�r/z#Can't get info for builtin modules.rAz
Target: {}z
Origin: {}z
Cached: {}z
Loader: {}�__path__zSubmodule search path: {}zLine: {}r@)�argparserY�ArgumentParser�add_argument�
parse_argsr��	partition�
import_modulerr%r|r7�printr��stderr�exitr2r}�builtin_module_names�detailsrK�
__cached__rrir~r�r*rJ)r�rY�parserr��target�mod_name�	has_attrs�attrsr�r�r�r��parts�part�__r�s                r��_mainr

s/����
�
$�
$�
&�F�
����9��:�����k�,�
H��J�����D�
�[�[�F�!'�!1�!1�#�!6��H�i���.�y�.�.�x�8�8��f�����C� �����	%�D��#�t�$�C�	%����#�2�2�2�
�3�#�*�*�E�������|�|�
�l�!�!�&�)�*�
�l�!�!�-��"7�8�9�
�l�!�!�&�"3�"3�4�5��&�=��,�%�%�d�6�+<�+<�&=�>�?��v�z�*��1�8�8����I�J�
1�'��_�
��F��j�'�'��/�0�
�d��
�i��n���G��,�3�3�H�48��I�4F�4F�47�9��	�c��
�
�#����������8�
��
�s+�3H�J�	I>�AI9�9I>�	J
�J
rOr)F)rA)r�)T)TNNF)�r6�
__author__�__all__r�r�r��collections.abcr��enum�importlib.machineryrYr�rrrVr�r�r�r�rr�r{�keywordrk�operatorrlrmrnrq�mod_dict�COMPILER_FLAG_NAMESr�r�r�r%r.rarSr^r_rWr~r]r\rYr�r[r�r�r�rdrVrPrOrZrUrQrcrXrTrRr`rbrNr�rDrErr'rHrhrMr3r=r<r(r=rGrKr/r|rrFrr�NodeVisitorr�r*r9rr	r5rLrJrir7rr0rr?rr1r+r,r�r-r7rCr6rr8rgr&r}rzr>rC�_fieldsr�rrIrBr)rfrgr�r|rur�r�r�r�r��	lru_cacher�r�r4r r!r"rrAr@r
rrrr;r:rrrrr3r2�WrapperDescriptorTyper�rr�r�r�r�r�r�r�r�r:r=rMr�r�r�r!�IntEnumrcr-r�r.r�r0rr1rr3rr#r
r$re�IntFlagrr
r7r�r�r��<module>rs:���@9�
�i��X�
�
������	�	�
��������/��9���#�#�)�)�+��D�A�q��H�U�Q�Y����q�(���%)���p�h0�$�0�A�(?��5�(�)�>���5�(�)�>��2�	,�-��x��L��I�3�8�3�"3�;�3�/�.�29�7�(��0(�T3�
:�
�{�$E�F�	�p�h���@0�
�<�|�& �:,�8
��28��
���,�^	�)�	��3�?�?��>B0�H+%�Z"��!�4�4�l$�&0�*��+�6
�{�$:�;�	�8�6��M�O��Z<�z�Y� >�
?��9���"�"9� 8� ?�	(�.7� D�*:�x��(L�M��14�j��&S�
T�
�
-�
�
-�7�O�)A�V�
��j�9�3D�3D�&D�
E�
�
@�
�
@���C�5�'�
�H�	����y�)�1�1�� �M�M�*�5�=�=��4�������	��	�@�'0�/�h�����
�
�
��$�&����!�����$
�����!�����$�."�7�7�!�3�3�!�;�;�!�5�5�7���$I?�X*�4	#�G�2/+�dK8�\
<� 8<�AF�\9�~+�48�,0�%)�$(�&+�oP�d<�<�A�A��T�\�\��"*�9�9��)�?�?��)�8�8��)�6�6�
�)�5�5��[7�[7�|L�L�DQ�Q�h
&*�4��u�V��$�,�,��,7�t�z��	�G�r�

Zerion Mini Shell 1.0