OwlCyberSecurity - MANAGER
Edit File: compat.cpython-311.pyc
� ������h�3��������������� �����������U�d�Z�ddlmZ�ddlZddlZddlZddlZddlZddlZddlm Z �ddlm Z �ddlmZ�ddl mZ�ddl mZ�dd l mZ�dd l mZ�ddl mZ�ddl mZ�ddlZ �ddl mZ�erddlmZ��ed������������Z�ed������������Zej��������j��������ZdXd�Z�G�d��dej��������������������Zej ��������Z!de"d<���ej#��������dk����rddl$Z%e%j&��������Z'nddl'Z'dYd�Z(dZd"�Z)dZd#�Z*dZd$�Z+d[d\d'�Z,d]d)�Z-d*d+dd,�d^d3�Z.d_d4�Z/d5���e0d6������������D���������������Z1e1�2���������������������e3d7������������d8�e3d9������������d:�e3d;������������d<i�������������d`d>�Z4e5e6fZ7dadA�Z8dbdC�Z9ej:���������G�dD��dE��������������������������Z;dF��Z<dG��Z=dH��Z>dcdK�Z?dddM�Z@erej#��������dk����rddNl mAZA�nddNlmAZA�nej#��������dk����rddNl mAZA�ndO��ZAej#��������dk����rddPlmBZB�n�G�dQ��dReeef���������������������ZBdedT�ZCdfdW�ZDdS�)gz"Python version compatibility code.�����)�annotationsN)� Parameter)� signature)�Path)�Any)�Callable)�Generic)�NoReturn)� TYPE_CHECKING)�TypeVarT)�overload)�Final�_T�_S�path�str | os.PathLike[str]�return�LEGACY_PATHc����������������� �����t����������|�������������S�)zBInternal wrapper to prepare lazy proxies for legacy_path instances)r���)r���s��� �_/builddir/build/BUILD/cloudlinux-venv-1.0.8/venv/lib/python3.11/site-packages/_pytest/compat.py�legacy_pathr���0���s�������t��������c������������������������e�Zd�ZdZdS�)� NotSetTyper���N)�__name__� __module__�__qualname__�token��r���r���r���r���8���s�������������� �E�E�Er���r���r����NOTSET)���������func�Callable[..., Any]�strc�����������������:�����t����������t����������|�������������������������S��N)r%���r����r#���s��� r����_format_argsr)���E���s�������y������r����object�boolc�����������������N�����t����������j��������|�������������}|ot����������|��������������S�r'���)�inspect�isgeneratorfunction�iscoroutinefunction)r#����genfuncs��� r����is_generatorr1���I���s)�������)�$�/�/�G��4�.�t�4�4�4�4r���c�����������������L�����t����������j��������|�������������pt����������|�dd������������S�)a{��Return True if func is a coroutine function (a function defined with async def syntax, and doesn't contain yield), or a function decorated with @asyncio.coroutine. Note: copied and modified from Python 3.5's builtin couroutines.py to avoid importing asyncio directly, which in turns also initializes the "logging" module as a side-effect (see issue #8). � _is_coroutineF)r-���r/����getattrr(���s��� r���r/���r/���N���s&��������&�t�,�,�U���o�u�0U�0U�Ur���c�����������������H�����t����������|�������������pt����������j��������|�������������S�)zZReturn True if the given function seems to be an async function or an async generator.)r/���r-����isasyncgenfunctionr(���s��� r����is_async_functionr7���Z���s"��������t�$�$�H��(B�4�(H�(H�Hr����curdir� str | Nonec�����������������������t����������|�������������}�t����������t����������j��������|�������������������������}|�j��������j��������}|�0 �|���������������������|������������}d||dz���fz��S�#�t����������$�r�Y�nw�xY�wd||dz���fz��S�)Nz%s:%d����)� get_real_funcr���r-����getfile�__code__�co_firstlineno�relative_to� ValueError)�functionr8����fn�lineno�relfns��� r����getlocationrF���`���s��������X�&�&�H� �g�o�h�'�'� (� (�B� � � -�F� �� 1��N�N�6�*�*�E���e�V�a�Z�0�0�0����� �� �� ��D� ������b�&�1�*�%�%�%s�����A�� A,�+A,�intc�����������������P������t����������|�dd������������}|sdS�t����������t����������j�����������������������������d������������dt �������������������������������������t����������t����������j�����������������������������d������������dt �������������������������������������t������������fd�|D���������������������������S�)z>Return number of arguments used up by mock arguments (if any).� patchingsNr����mock�DEFAULTz unittest.mockc�����������������F������g�|�]}|j���������s|j���������u�s |j���������u��|��S�r���)�attribute_name�new)�.0�p� mock_sentinel�ut_mock_sentinels��� ��r���� <listcomp>z'num_mock_patch_args.<locals>.<listcomp>x���sM�������� �� �� ���#� ����-�'�'�1�5�4D�+D�+D�� ��,E�+D�+Dr���)r4����sys�modules�getr*����len)rB���rI���rQ���rR���s��� @@r����num_mock_patch_argsrX���n���s�����������+�t�4�4�I�����q��C�K�O�O�F�3�3�Y����I�I�M��s�{����?�?��F�H�H�U�U��� �� �� �� �� �� �� �� �����r�����F)�name� is_method�clsrB���rZ���r[���r\����type | None�tuple[str, ...]c��������������������� �t����������|�������������j��������}n7#�t����������t����������f$�r#}ddlm}��|d|��d|���d��������������Y�d}~nd}~ww�xY�wt ����������d��|�����������������������������������D���������������������������}|s|�j��������}|s,|r4t����������t����������j��������||d� ������������t����������������������s |d d����������}t����������|�d������������r|t����������|�������������d����������}|S�)aL��Return the names of a function's mandatory arguments. Should return the names of all function arguments that: * Aren't bound to an instance or type as in instance or class methods. * Don't have default values. * Aren't bound with functools.partial. * Aren't replaced with mocks. The is_method and cls arguments indicate that the function should be treated as a bound method even though it's not unless, only in the case of cls, the function is a static method. The name parameter should be the original name in which the function was collected. r���)�failz!Could not determine arguments of z: F)�pytraceNc��������������3������K����|�]D}|j���������t����������j��������u�s|j���������t����������j��������u�r|j��������t����������j��������u��;|j��������V����Ed�S�r'�����kindr����POSITIONAL_OR_KEYWORD�KEYWORD_ONLY�default�emptyrZ����rO���rP���s��� r���� <genexpr>z"getfuncargnames.<locals>.<genexpr>����sa�������������� � �F�i�5�5�5��v��/�/�/� �I���(�(� � ��� )�(�(�(���r���)rg���r;����__wrapped__)r���� parametersrA���� TypeError�_pytest.outcomesr`����tuple�valuesr���� isinstancer-����getattr_static�staticmethod�hasattrrX���)rB���rZ���r[���r\���rl����er`���� arg_namess��� r����getfuncargnamesrw�������sa�����< ��x�(�(�3� � ��� �"�� �� �� �)�)�)�)�)�)���A��A�A�a�A�A�� �� �� �� �� �� �� �� �� ����� �����������"�"�$�$����������I����!�� �� ���"�� �"����"�3��d�;�;�;�\� �� � "���a�b�b�M� ��x��'�'��?��1�(�;�;�=�=�>� ��s������A�A�Ac�����������������|�����t����������d��t����������|�������������j�������������������������������������������D���������������������������S�)Nc��������������3������K����|�]=}|j���������t����������j��������t����������j��������fv�r|j��������t����������j��������u�4|j��������V����>d�S�r'���rc���ri���s��� r���rj���z(get_default_arg_names.<locals>.<genexpr>����sY�������������� ��6�i�5�y�7M�N�N�N� �I�Y�_�,�,�� ��� -�,�,�,� ��r���)ro���r���rl���rp���)rB���s��� r����get_default_arg_namesrz�������sI�������������8�$�$�/�6�6�8�8�����������r���c�����������������@�����i�|�]}|t����������d�d������������v�|d|d����S�)� �������z\x�02x)�range)rO����is��� r���� <dictcomp>r��������s;�������(��(��(��A�U�2�s�^�^�,C�,C�A�}�Q�}�}�}�,C�,C�,Cr�������� z\t� z\r� z\n�sc�����������������6�����|�����������������������t����������������������S�r'���)� translate�$_non_printable_ascii_translate_table)r����s��� r����_translate_non_printabler��������s�������;�;�;�<�<�<r����val�bytesc�����������������.�����|�����������������������dd������������S�)N�ascii�backslashreplace)�decode)r����s��� r����_bytes_to_asciir��������s�������:�:�g�1�2�2�2r����bytes | strc����������������������t����������|�t����������������������rt����������|�������������}n(|����������������������d���������������������������������d������������}t����������|������������S�)a��If val is pure ASCII, return it as an str, otherwise, escape bytes objects into a sequence of escaped bytes: b'\xc3\xb4\xc5\xd6' -> r'\xc3\xb4\xc5\xd6' and escapes unicode objects into a sequence of escaped unicode ids, e.g.: r'4\nV\U00043efa\x0eMXWB\x1e\u3028\u15fd\xcd\U0007d944' Note: The obvious "v.decode('unicode-escape')" will return valid UTF-8 unicode if it finds them in bytes, but we want to return escaped bytes for any byte, even if they match a UTF-8 string. �unicode_escaper����)rq���r����r�����encoder����r����)r�����rets��� r���� ascii_escapedr��������sS������"��#�u����;��c�"�"����j�j�)�*�*�1�1�'�:�:��#�C�(�(�(r���c������������������������e�Zd�ZU�dZded<���dS�)�_PytestWrappera%��Dummy wrapper around a function object for internal use only. Used to correctly unwrap the underlying function object when we are creating fixtures, because we wrap the function object ourselves with a decorator to issue warnings when the fixture function is called directly. r����objN)r���r���r����__doc__�__annotations__r���r���r���r����r��������s%�������������������� �H�H�H�H�Hr���r����c�����������������t����|�}t����������d������������D�]H}t����������|�dd������������}t����������|t����������������������r |j��������}��nTt����������|�dd������������}|��n?|}��Iddlm}�t����������d����������������������||�������������||���������������������������������������t����������|�t����������j ��������������������r|�j��������}�|�S�) zjGet the real function object of the (possibly) wrapped object by functools.wraps or functools.partial.�d����__pytest_wrapped__Nrk���r���)�safereprz<could not find real function of {start} stopped at {current})�start�current)r���r4���rq���r����r�����_pytest._io.safereprr����rA����format� functools�partialr#���)r����� start_objr�����new_objr����s��� r���r<���r<��� ��s���������I� �3�Z�Z�� �� ����#�3�T�:�:���g�~�.�.�� ��+�C��E��#�}�d�3�3���?��E����1�1�1�1�1�1�� L�T�T��h�y�)�)�8�8�C�=�=�� U�� �� � �� �� � ��#�y�(�)�)����h���Jr���c����������������������� �t����������|�d������������}t����������|�������������}�n#�t����������$�r�|�cY�S�w�xY�w|r9t����������|�d������������r)t����������|�j��������������������r|����������������������|������������}�|�S�)z�Attempt to obtain the real function object that might be wrapping ``obj``, while at the same time returning a bound method to ``holder`` if the original object was a bound method.�__func__�__get__)rt���r<���� Exception�callabler����)r�����holderr[���s��� r����get_real_methodr����'��s���������C��,�,� ��C� � ������������ � � �������"�W�S�)�,�,��"��#�+�1F�1F��"��k�k�&�!�!���Js����"��1�1c�����������������6����� �|�j���������S�#�t����������$�r�|�cY�S�w�xY�wr'���)r�����AttributeErrorr(���s��� r���� getimfuncr����5��s3��������}�����������������s���� ���r���rg���c�����������������L�����ddl�m}� �t����������|�||������������S�#�|$�r�|cY�S�w�xY�w)aR��Like getattr but return default upon any Exception or any OutcomeException. Attribute access can potentially fail for 'evil' Python objects. See issue #214. It catches OutcomeException because of #2490 (issue #580), new outcomes are derived from BaseException instead of Exception (for more details check #2707). r���)�TEST_OUTCOME)rn���r����r4���)r*���rZ���rg���r����s��� r����safe_getattrr����<��sQ�������.�-�-�-�-�-���v�t�W�-�-�-����������������s������#�#r����c�����������������N����� �t����������j��������|�������������S�#�t����������$�r�Y�dS�w�xY�w)z0Ignore any exception via isinstance on Python 3.F)r-����isclassr����)r����s��� r����safe_isclassr����M��s9���������s�#�#�#����������u�u����s������ $�$)�finalc����������������������|�S�r'���r���)�fs��� r���r����r����^��s�������r���)�cached_propertyc�������������������X�����e�Zd�ZdZdd�Ze �ddd���������������Zeddd���������������Zdd�ZdS�)r�����r#���r����r#����Callable[[_S], _T]r����Nonec�����������������,�����||�_���������|j��������|�_��������d�S�r'���r����)�selfr#���s��� r����__init__zcached_property.__init__i��s�������D�I��<�D�L�L�Lr���.�instance�owner�type[_S] | None�cached_property[_S, _T]c����������������������d�S�r'���r����r����r����r����s��� r���r����zcached_property.__get__m��s ������� �Cr���r���r���c����������������������d�S�r'���r���r����s��� r���r����zcached_property.__get__s��s�������Cr���Nc�����������������`�����|�|�S�|�����������������������|������������x}|j��������|�j���������j��������<���|S�r'���)r#����__dict__r���)r����r����r�����values��� r���r����zcached_property.__get__w��s5����������<@�I�I�h�<O�<O�O�E�H�%�d�i�&8�9��Lr���)r#���r����r���r����).)r����r����r����r����r���r����)r����r���r����r����r���r���r'���)r���r���r���� __slots__r����r ���r����r���r���r���r����r����f��s���������������'� � (�� (�� (�� (�� �;>� �� �� �� �� �� � � � �� �� �� �� �� � �� �� �� �� �� r���r����� int | Nonec������������������\�����t�����������j��������dv�rdS�t����������j����������������������}�|�dk����r|�ndS�)zYReturn the current user id, or None if we cannot get it reliably on the current platform.)�win32� emscriptenN���)rT����platform�os�getuid)�uids��� r����get_user_idr����~��s6��������|�.�.�.��t�� �)�+�+�C���)�)�3�3��%r���r����r ���c�����������������H�����J�d|���dt����������|�������������j����������d����������������)NFzUnhandled value: z (�))�typer���)r����s��� r����assert_neverr�������s,������F�F�e�F�F�t�E�{�{�/C�F�F�F�F�F�5r���)r���r���r���r���)r#���r$���r���r%���)r#���r*���r���r+���r'���)r8���r9���r���r%���)r���rG���) rB���r$���rZ���r%���r[���r+���r\���r]���r���r^���)rB���r$���r���r^���)r����r%���r���r%���)r����r����r���r%���)r����r����r���r%���)r*���r���rZ���r%���rg���r���r���r���)r����r*���r���r+���)r���r����)r����r ���r���r ���)Er����� __future__r����dataclasses�enumr����r-���r����rT���r���r����pathlibr����typingr���r���r ���r ���r���r����pyr ����typing_extensionsr���r���r���r����localr���r����Enumr���r���r ���r�����version_info�importlib.metadata� importlib�metadata�importlib_metadatar)���r1���r/���r7���rF���rX���rw���rz���r���r�����update�ordr����r����r%����STRING_TYPESr����r����� dataclassr����r<���r����r����r����r����r����r����r����r����r���r���r����<module>r�������s������(��(��(��"��"��"��"��"��"���������������������������� � � � �� � � � �������������������������������������������������������������������������������������� �� �� �� �� �� �������������� � � � �,�+�+�+�+�+�+���(�'�'�'�'�'�'�� �W�T�]�]���W�T�]�]����g�n��������������������������� ��� �� �� �� ����v�������"�+���3�3�3�3� �� �� �� �5��5��5��5� V�� V�� V�� V�I��I��I��I�&��&��&��&��&��������,����C��C��C��C��C��C�L �� �� �� �(��(�#�e�C�j�j�(��(��(��$��%��+��+��S��Y�Y��s�s�4�y�y�%���T���E�:������ =��=��=��=���c�z��3��3��3��3�)��)��)��)�0� �� �� �� �� �� �� �� ���� ������:�����������������"���������� � ��6�!�!�)�)�)�)�)�)�)�4�4�4�4�4�4�4������%�%�%�%�%�%�%���������v���<�<�<�<�<�<�<����������'�"�b�&�/�������0 &�� &�� &�� &�VG��G��G��G��G��Gr���