403Webshell
Server IP : 217.160.0.135  /  Your IP : 216.73.217.85
Web Server : Apache
System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64
User : sws1074145052 ( 1074145052)
PHP Version : 8.3.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/jedi/inference/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/jedi/inference/__pycache__/finder.cpython-311.pyc
�

p�{c����dZddlmZddlmZddlmZddlmZddl	m
Z
ddlmZddl
mZd	�Zd
�Zd�Zd�Zd
�Zd�ZdS)a�
Searching for names with given scope and name. This is very central in Jedi and
Python. The name resolution is quite complicated with descripter,
``__getattribute__``, ``__getattr__``, ``global``, etc.

If you want to understand name resolution, please read the first few chapters
in http://blog.ionelmc.ro/2015/02/09/understanding-python-metaclasses/.

Flow checks
+++++++++++

Flow checks are not really mature. There's only a check for ``isinstance``.  It
would check whether a flow has the form of ``if isinstance(a, type_or_tuple)``.
Unfortunately every other thing is being ignored (e.g. a == '' would be easy to
check for -> a is a string). There's big potential in these checks.
�)�search_ancestor)�Name)�settings)�
TreeArguments)�iterable)�	NO_VALUES)�is_scopec��t|t��r|jn|}g}|D]}|�|��}|rn�t	t|����S)zh
    Searches names that are defined in a scope (the different
    ``filters``), until a name fits.
    )�
isinstancer�value�get�list�_remove_del_stmt)�filters�name_or_str�string_name�names�filters     �7/usr/lib/python3/dist-packages/jedi/inference/finder.py�filter_namersp��
(2�+�t�'D�'D�U�+�#�#�+�K��E������
�
�;�'�'���	��E�	�� ��'�'�(�(�(�c#�xK�|D]4}|j�'|j���}|�|jdkr�0|V��5dS)N�del_stmt)�	tree_name�get_definition�type)r�name�
definitions   rrr+sZ���������>�%���6�6�8�8�J��%�*�/�Z�*G�*G���
�
�
�
��rc�"���tjsdSd}t���r�����}	|���|j}n#t$rYdSwxYwt��fd�|D����}|D]0}t|d��}|�t||j
|��}|�|cS�1�jdvrOd��jddd�D��}	t|	��D]%}
|j
|
jkrt||
|��cS�&|S)z� Try to find out the type of a variable just with the information that
    is given by the flows: e.g. It is also responsible for assert checks.::

        if isinstance(k, str):
            k.  # <- completion here

    ensures that `k` is a string.
    Nc�V��g|]%}�j|jcxkr
�p�jk� nn|��&S�)�	start_pos�end_pos)�.0�n�flow�poss  ��r�
<listcomp>z*check_flow_information.<locals>.<listcomp>IsP���
�
�
���~���D�D�D�D��0C�t�|�D�D�D�D�D�
�D�D�Dr�assert_stmt)�if_stmt�
while_stmtc��g|]
}|dk�|��S)�:r!)r$�cs  rr(z*check_flow_information.<locals>.<listcomp>Vs��D�D�D�q�1��8�8��8�8�8r��)r�dynamic_flow_informationr	�
get_root_node�get_used_namesr�KeyError�reversedr�_check_isinstance_type�	assertionr�childrenr"r#)rr&�search_namer'�result�module_noderr�ass�
potential_ifs�if_tests ` `       r�check_flow_informationr?5sw�����,���t�
�F���~�~�"��(�(�*�*��	��.�.�0�0��1B�C�E�E���	�	�	��4�4�	�����
�
�
�
�
��
�
�
����
�	"�	"�D�!�$�
�6�6�C���/��s�}�k�R�R���%�!�M�M�M���y�-�-�-�D�D�D�M�!�$�Q�$�$7�D�D�D�
��
�.�.�	K�	K�G��$�w��6�6�-�e�W�k�J�J�J�J�J�7��Ms�A�
A%�$A%c���|jdvrVt|j��dkr>|j\}}|jdkr)|jdkr|jdkr|jddkr|SdS)N)�power�	atom_expr�rr�trailerr�()r�lenr8r)�node�firstrDs   r�_get_isinstance_trailer_arglistrI]sq���y�*�*�*�s�4�=�/A�/A�Q�/F�/F�����w��:����E�K�<�$?�$?��L�I�-�-�'�2B�1�2E��2L�2L��N��4rc��d}t|��}|��t|j��dkr�|jd}t|j|||��}t|�����}t|��dkrXt|j��dkr@|\\}}	\}
}|�3|
�1t|��}t|jd��}
||
kr|}|�dSt}|�	��D]}t|tj��rL|j
dkrA|���D]+}||�	�����z}�,�h||���z}��|S)N�r/rCr�tuple)rIrFr8r�inference_stater�unpack�_get_call_stringr�inferrr�Sequence�
array_type�
py__iter__�execute_with_values)rrGr9�lazy_clsrD�arglist�args�
param_list�key1�_�key2�lazy_value_cls�call�is_instance_call�	value_set�
cls_or_tup�
lazy_values                 rr6r6gs����H�-�d�3�3�G���s�7�#3�4�4��9�9��"�1�%���U�2�E�7�G�L�L���$�+�+�-�-�(�(�
��z�?�?�a���C��(8�$9�$9�Q�$>�$>�0:�-�I�T�1�-��n��|���'��4�4��#3�G�4D�Q�4G�#H�#H� ��+�+�+�-�H����t��I��n�n�&�&�:�:�
��j�(�"3�4�4�	:��9N�RY�9Y�9Y�(�3�3�5�5�
F�
F�
��Z�-�-�/�/�C�C�E�E�E�	�	�
F�
��7�7�9�9�9�I�I��rc��|jjdkrt|j��Sd}|���}|���j}|j|kr)||jz
}|���}|j|k�)|S)NrB�)	�parentrrO�get_first_leaf�
get_last_leafr#r"r�
get_next_leaf)rG�code�leaf�ends    rrOrO�s����{��;�&�&����,�,�,�
�D���� � �D�
�
�
�
�
�
&�C�
�.�3�
�
���
����!�!�#�#���.�3�
�
��KrN)�__doc__�
parso.treer�parso.python.treer�jedir�jedi.inference.argumentsr�jedi.inference.valuer�jedi.inference.base_valuer�jedi.parser_utilsr	rrr?rIr6rOr!rr�<module>rss�����"'�&�&�&�&�&�"�"�"�"�"�"�������2�2�2�2�2�2�)�)�)�)�)�)�/�/�/�/�/�/�&�&�&�&�&�&�)�)�)����%�%�%�P������B
�
�
�
�
r

Youez - 2016 - github.com/yon3zu
LinuXploit