Skip to main content
Glama

ClickUp Operator

by noah-vh
utils.cpython-312.pyc18.8 kB
� lMg-.��V�dZddlZddlZddlZddlmZmZmZddlm Z ddl m Z ddl m Z ddlmZeeeef\ZZZZej.Zed�d D��Zed �d D��Zej8d �Z erddlZne� ej@d ��d(d�Z"Gd�de#�Z$Gd�de#�Z%Gd�de#�Z&Gd�de&�Z'Gd�de&�Z(Gd�de&�Z)d�Z*d�Z+d�Z,d�Z-d �Z.d!�Z/d"�Z0d#�Z1d$�Z2d%�Z3d&�Z4d'�Z5y#e!$rej@�Y��wxYw#e$rdZY��wxYw))z* General helpers required for `tqdm.std`. �N)�partial� partialmethod�wraps)� signature��east_asian_width)�warn��proxyc#�FK�|]}tj|����y�w�N��CUR_OS� startswith��.0�is �VC:\Users\noahv\Documents\GitHub\clickup-operator\.venv\Lib\site-packages\tqdm/utils.py� <genexpr>rs���� ?�+>�a�V� � �q� !�+>���!)�win32�cygwinc#�FK�|]}tj|����y�wr rrs rrrs���� Q�+P�a�V� � �q� !�+P�r)�aix�linux�darwin�freebsdz\x1b\[[;\d]*[A-Za-z]F)�stripc� ������i�t|�}tjj�D��cic]+\}}|j |�s�||dj �|��-c}}�|rt nt����fd�}|Scc}}w)a Override parameter defaults via `os.environ[prefix + param_name]`. Maps UPPER_CASE env vars map to lower_case param names. camelCase isn't supported (because Windows ignores case). Precedence (highest first): - call (`foo(a=3)`) - environ (`FOO_A=2`) - signature (`def foo(a=1)`) Parameters ---------- prefix : str Env var prefix, e.g. "FOO_" types : dict, optional Fallback mappings `{'param_name': type, ...}` if types cannot be inferred from function signature. Consider using `types=collections.defaultdict(lambda: ast.literal_eval)`. is_method : bool, optional Whether to use `functools.partialmethod`. If (default: False) use `functools.partial`. Examples -------- ``` $ cat foo.py from tqdm.utils import envwrap @envwrap("FOO_") def test(a=1, b=2, c=3): print(f"received: a={a}, b={b}, c={c}") $ FOO_A=42 FOO_C=1337 python -c 'import foo; foo.test(c=99)' received: a=42, b=2, c=99 ``` Nc���t|�j}�j�D��cic] \}}||vs� ||��}}}|D]�}||}|j|jur8t |jd|jf�D]} |||�||<�V�X|j�"t|j�||�||<�� � |||�||<���|fi|��Scc}}w#t $rY�rwxYw#t$rY��wxYw)N�__args__) r� parameters�items� annotation�empty�getattr� Exception�default�type�KeyError) �func�params�k�v� overrides�param�typ� env_overrides�part�typess ���r�wrapzenvwrap.<locals>.wrapLs(����4��+�+��&3�&9�&9�&;�K�&;�d�a��q�F�{�Q��T�&;� �K��A��1�I�E����u�{�{�2�"�5�#3�#3�Z�%�BR�BR�AT�U�C��'*�9�Q�<�'8� �!� �� V����*�2�t�E�M�M�2�9�Q�<�@� �!� ��#+�5��8�I�a�L�#9�I�a�L��"�D�&�I�&�&��'L��%����� ����s.� C$�C$�C*�C9�* C6�5C6�9 D�D)�len�os�environr#r�lowerrr) �prefixr4� is_methodrr-r.r5r2r3s ` @@r�envwrapr<"sx���H �}��� �F� �A�24�*�*�2B�2B�2D�]�2D�$�!�Q�� � �U[�H\�Q�q�r�U�[�[�]�A�%�2D�]�M�%�=�7�D�'�. �K��5^s �A?�A?c��eZdZdZdd�Zd�Zy)� FormatReplacezN >>> a = FormatReplace('something') >>> f"{a:5d}" 'something' c� �||_d|_y�Nr)�replace� format_called)�selfrAs r�__init__zFormatReplace.__init__ls���� ����c�D�|xjdz c_|jS)N�)rBrA)rC�_s r� __format__zFormatReplace.__format__ps�� ���a����|�|�rEN)�)�__name__� __module__� __qualname__�__doc__rDrI�rErr>r>fs��� �rEr>c�4�eZdZdZd�Zd�Zd�Zd�Zd�Zd�Z y) � Comparablez1Assumes child has self._comparable attr/@propertyc�4�|j|jkSr �� _comparable�rC�others r�__lt__zComparable.__lt__ws�����%�"3�"3�3�3rEc��||kxs||k(Sr rOrUs r�__le__zComparable.__le__zs���u� �0�$�%�-�0rEc�4�|j|jk(Sr rSrUs r�__eq__zComparable.__eq__}s�����5�#4�#4�4�4rEc��||k( Sr rOrUs r�__ne__zComparable.__ne__�����5�=� � rEc��||k Sr rOrUs r�__gt__zComparable.__gt__�r^rEc��||k Sr rOrUs r�__ge__zComparable.__ge__�s���%�<��rEN) rKrLrMrNrWrYr[r]r`rbrOrErrQrQus#��;�4�1�5�!�!� rErQc�*�eZdZd�Zd�Zd�Zd�Zd�Zy)� ObjectWrapperc�.�t|j|�Sr )r&�_wrapped�rC�names r� __getattr__zObjectWrapper.__getattr__�s���t�}�}�d�+�+rEc�0�t|j||�Sr )�setattrrf�rCrh�values r� __setattr__zObjectWrapper.__setattr__�s���t�}�}�d�E�2�2rEc�f� tj||�S#t$rt||�cYSwxYw)z7Actual `self.getattr` rather than self._wrapped.getattr)�objectri�AttributeErrorr&rgs r�wrapper_getattrzObjectWrapper.wrapper_getattr�s6�� '��%�%�d�D�1� 1��� '��4��&� &� '�s ��0�0c�0�tj|||�S)z7Actual `self.setattr` rather than self._wrapped.setattr)rprnrls r�wrapper_setattrzObjectWrapper.wrapper_setattr�s���!�!�$��e�4�4rEc�(�|jd|�y)z4 Thin wrapper around a given object rfN)rt)rC�wrappeds rrDzObjectWrapper.__init__�s�� ���Z��1rEN)rKrLrMrirnrrrtrDrOrErrdrd�s��,�3�'�5�2rErdc�.��eZdZdZ�fd�Zd�Zd�Z�xZS)�SimpleTextIOWrapperz� Change only `.write()` of the wrapped object by encoding the passed value and passing the result to the wrapped object's `.write()` method. c�H��t�|�|�|jd|�y)N�encoding)�superrDrt)rCrvrz� __class__s �rrDzSimpleTextIOWrapper.__init__�s ��� ����!� ���Z��2rEc�t�|jj|j|jd���S)zP Encode `s` and pass to the wrapped object's `.write()` method. rz)rf�write�encoderr)rC�ss rr~zSimpleTextIOWrapper.write�s-���}�}�"�"�1�8�8�D�,@�,@��,L�#M�N�NrEc�6�|jt|d|�k(S�Nrf�rfr&rUs rr[zSimpleTextIOWrapper.__eq__�����}�}���z�5� A�A�ArE)rKrLrMrNrDr~r[� __classcell__�r|s@rrxrx�s���� 3�O� BrErxc�8��eZdZdZed��Z�fd�Zd�Z�xZS)�DisableOnWriteErrorzO Disable the given `tqdm_instance` upon `write()` or `flush()` errors. c�,���t�����fd�}|S)zV Quietly set `tqdm_instance.miniters=inf` if `func` raises `errno=5`. c�8�� �|i|��S#t$r@}|jdk7r� td��_n#t$rYnwxYwYd}~yYd}~yd}~wt $r>}dt |�vr� td��_n#t$rYnwxYwYd}~yYd}~yd}~wwxYw)N��inf�closed)�OSError�errno�float�miniters�ReferenceError� ValueError�str)�args�kwargs�er+� tqdm_instances ��r�innerz7DisableOnWriteError.disable_on_exception.<locals>.inner�s���� ��T�,�V�,�,��� ��7�7�a�<���-2�5�\�M�*��%������+��� ��3�q�6�)���-2�5�\�M�*��%������+��  �sc� � B�A�6�A� A�A�A�A� B�B�*A;�:B�; B�B�B�B�Br )r�r+r�s`` r�disable_on_exceptionz(DisableOnWriteError.disable_on_exception�s��� �m�,� � �"� rEc���t�|�|�t|d�r,|jd|j ||j ��t|d�r-|jd|j ||j ��yy)Nr~�flush)r{rD�hasattrrtr�r~r�)rCrvr�r|s �rrDzDisableOnWriteError.__init__�ss��� ����!� �7�G� $� � � ���2�2�=�'�-�-�P� R� �7�G� $� � � ���2�2�=�'�-�-�P� R� %rEc�6�|jt|d|�k(Sr�r�rUs rr[zDisableOnWriteError.__eq__�r�rE) rKrLrMrN� staticmethodr�rDr[r�r�s@rr�r��s(��������2R�BrEr�c� ��eZdZd�fd� Z�xZS)�CallbackIOWrapperc�����t�|�|�t||��|dk(r't����fd��}|j d|�y|dk(r't����fd��}|j d|�yt d��)z{ Wrap a given `file`-like object's `read()` or `write()` to report lengths to the given `callback` r~c�B���|g|��i|��}�t|��|Sr �r6)�datar�r��res�callbackr+s ��rr~z)CallbackIOWrapper.__init__.<locals>.write�s(����4�1�$�1�&�1����T��#�� rE�readc�:���|i|��}�t|��|Sr r�)r�r�r�r�r+s ��rr�z(CallbackIOWrapper.__init__.<locals>.read�s#����T�,�V�,����T��#�� rEz Can only wrap read/write methodsN)r{rDr&rrtr*)rCr��stream�methodr~r�r+r|s ` @�rrDzCallbackIOWrapper.__init__�s���� ���� ��v�v�&�� �W� � �4�[� �� � � � ��%� 0� �v� � �4�[� �� � � � ��� .��=�>� >rE)r�)rKrLrMrDr�r�s@rr�r��s ���?�?rEr�c��� dj|�y#t$rYyt$r: |j�j d�xsd|k(cYS#t$rYYywxYwwxYw)Nu█▉TFzutf-�U8)r�UnicodeEncodeErrorr'r9r)rzs r�_is_utfr��so�� ����x�(��� ��� �� ��>�>�#�.�.�v�6�L�4�8�;K� L��� �� ���s1�� A!�A!�%A� A!� A�A!�A�A!c�L� t|j�S#t$rYywxYw�NF)r�rzrq)�fps r�_supports_unicoder� s(����r�{�{�#�#�� ����s �� #�#c�h�t|t�r|D]}t|�dkDs�yyt|�S)N��FT)� isinstancer��ordr�)r��cs r� _is_asciir�s4���!�S���A��1�v��|���� �Q� �rEc�J�d}trt}|�t}trt}|S)zy Return a function which returns console dimensions (width, height). Supported: linux, osx, windows, cygwin. N)�IS_WIN�_screen_shape_windows�_screen_shape_tput�IS_NIX�_screen_shape_linux)� _screen_shapes r�_screen_shape_wrapperr�s*�� �M� �-� � � �.�M� �+� � �rEc �V� ddl}ddlm}m}ddlm}m}d}||k(rd}n||k(rd}|jj|�}|d�}|jj||�} | r2|jd|j�\ } } } } }}}}}}}||z ||z fS y #t$rYy wxYw) Nr)�create_string_buffer�windll)�stdin�stdouti����i����i������ hhhhHhhhhhh�NN) �struct�ctypesr�r��sysr�r��kernel32� GetStdHandle�GetConsoleScreenBufferInfo�unpack�rawr')r�r�r�r�r�r�� io_handle�h�csbir��_bufx�_bufy�_curx�_cury�_wattr�left�top�right�bottom�_maxx�_maxys rr�r�)s��� ��7�%�� � ��;��I� �6�\��I� �O�O� (� (�� 3��#�B�'���o�o�8�8��D�A�� �#�]�]�=�$�(�(�C� �U�E�5�%���s�E�6� �E��4�<��#��-� -� � �� � � � � �s�BB� B(�'B(c �� ddl}ddlm}dD�cgc](}t||j d|z���dz ��*c}Scc}w#t $rYywxYw)zcygwin xterm (windows)rN)� check_call)�cols�linesztput rGr�)�shlex� subprocessr��int�splitr')rHr�r�rs rr�r�Asc�� ��)�*�,�*�A��J�u�{�{�7�Q�;�7�8�9�A�=�*�,� ,��,�� � � � � �s!�A�-A�A�A� A�Ac�0� ddlm}ddlm}ddlm} |d|||d��dd\}}||fS#t $rM dD�cgc]!}t tj|�d z ��#ncc}wc}cYS#ttf$rYYy wxYwwxYw#t$rYy wxYw) Nr)�array)�ioctl)� TIOCGWINSZr�z�)�COLUMNS�LINESrGr�) r��fcntlr��termiosr�r'r�r7r8r*r�� ImportError)r�r�r�r��rowsr�rs rr�r�Ms���"���&� "��s�E�"�j�(�$C�D�R�a�H�J�D�$���:� ��� "� "�8L�M�8L�1��B�J�J�q�M�*�Q�.�8L��M�M���j�)� "�!� "�� "�� ����sH�B �0� B�A/�&A%�$A/�,B�/B�>B�B�B� B�Bc�l��tdtd��t���syt���fd��}|S)zd Return a function which returns console width. Supported: linux, osx, windows, cygwin. zQUse `_screen_shape_wrapper()(file)[0]` instead of `_environ_cols_wrapper()(file)`r�)� stacklevelNc����|�dSr@rO)r��shapes �rr�z$_environ_cols_wrapper.<locals>.innerks����R�y��|�rE)r �DeprecationWarningr�r)r�r�s @r�_environ_cols_wrapperr�`sC���  � ,�-?�A�O� !� #�E� �� �5�\���� �LrEc�<�tjdk(rt�dSdS)N�ntrJz)r7rh�coloramarOrEr� _term_move_upr�rs���'�'�T�/��(8�2�G�x�GrEc�8�td�t|�D��S)Nc3�>K�|]}t|�dvrdnd���y�w)�FWr�rGNr)r�chs rrz_text_width.<locals>.<genexpr>ws#����I�&�B�$�R�(�D�0�q�a�7�&�s�)�sumr�)r�s r� _text_widthrvs�� �I�#�a�&�I� I�IrEc�@�ttjd|��S)zp Returns the real on-screen length of a string which may contain ANSI control codes and wide chars. rJ)r�RE_ANSI�sub)r�s r�disp_lenrzs�� �w�{�{�2�t�,� -�-rEc�.�t|�t|�k(r|d|Sttj |��}t|�|kDr|dd}t|�|kDr�|r6ttj |��r|j d�r|S|dzS|S)zB Trim a string which may contain ANSI control characters. N�����z)r6r�boolr�search�endswith)r��length� ansi_presents r� disp_trimr�s��� �4�y�H�T�N�"��G�V�}������t�,�-�L� �4�.�6� !��C�R�y�� �4�.�6� !���W�^�^�D�1�2��}�}�Y�/�t�E�T�I�5E�E� �KrEr�)6rNr7�rer�� functoolsrrr�inspectr� unicodedatar�warningsr �weakrefr �range�chrr��_range�_unich�_unicode� _basestring�platformr�anyr�r��compilerr�r��init� TypeErrorr<rpr>rQrdrxr�r�r�r�r�r�r�r�r�r�r�rrrrOrEr�<module>r sg��� � � �3�3��(���(-�s�C��(<�%����+� ���� � ?�+>� ?� ?�� � Q�+P� Q� Q�� �"�*�*�,� -�� � ���� � ��� � �E�"� A�H �F� � �� �*2�F�2�2B�-�B�((B�-�(B�V?� �?�4 �� � ��0 �"�&�$H�J�.� ��I ���� � ���� ���H��s$�9 D�D�D�D�D(�'D(

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/noah-vh/mcp-server-clickup'

If you have feedback or need assistance with the MCP directory API, please join our Discord server