HEX
Server: LiteSpeed
System: Linux shams.tasjeel.ae 5.14.0-611.5.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Nov 11 08:09:09 EST 2025 x86_64
User: infowars (1469)
PHP: 8.2.29
Disabled: NONE
Upload Files
File: //usr/lib/python3.9/site-packages/argcomplete/__pycache__/my_argparse.cpython-39.opt-1.pyc
a

�]�;�@svddlmZmZmZmZddlmZmZmZmZm	Z	ddlm
Z
mZiZdd�Z
dd�Zdd	d
�ZGdd�de�Zd
S)�)�ArgumentParser�
ArgumentError�SUPPRESS�_SubParsersAction)�OPTIONAL�ZERO_OR_MORE�ONE_OR_MORE�	REMAINDER�PARSER)�_get_action_name�_cCs\t�|d�}|jtttfvr dS|jtkr2|dkS|jtkr@dS|jdurR|dkS||jkS)zt Returns False if the parse would raise an error if no more arguments are given to this action, True otherwise.
    rT�FN)�_num_consumed_args�get�nargsrrr	rr
��action�num_consumed_args�r�;/usr/lib/python3.9/site-packages/argcomplete/my_argparse.py�action_is_satisfieds


rcCsHt�|d�}|jttttfvr"dS|jtks6|jdur>|dkS||jkS)zV Returns True if action could consume more arguments (i.e., its pattern is open).
    rTN)rrrrrr
r	rrrrr�action_is_opensrFcCsBt�|d�}|jr,|s"t|�s"dS|jtkS|jtko<|dkSdS)z� Returns True if action will necessarily consume the next argument.
    isoptional indicates whether the argument is an optional (starts with -).
    rTr
N)rr�option_stringsrrr	)rZ
isoptionalrrrr�action_is_greedy-s
rc@seZdZdZdd�ZdS)�IntrospectiveArgumentParserz� The following is a verbatim copy of ArgumentParser._parse_known_args (Python 2.7.3),
    except for the lines that contain the string "Added by argcomplete".
    cs�t����	_g�	_�	jdur(�	����i���	_�	jD]R}|j}t	|j�D]<\}}��
|g�}|�|d|��|�||dd��qLq8i�g}t��}	t	|	�D]^\}}
|
dkr�|�
d�|	D]}
|�
d�q�q��	�|
�}|dur�d}n|�|<d}|�
|�q�d�|��t��t����	_d�����	fdd�	������	�fd	d
�}
�	�������	�fdd�}g�d
�
��r�t��}nd}�
|k�r�t�
fdd��D��}�
|k�r�|�
�}|�
k�r�|�
�q�n|�
�
�v�r��
|�}��|�|�
|
�
��
�q�|�
�}���|d����r<�	j�
�d
��	�td���	jD]2}|j�rB|�v�rBt|�}�	�td�|��qB�	jD]X}|j�r||jD]}|�v�r��q|�q�dd�|jD�}td�}�	�|d�|���q|��fS)Nr
z--�-�A�O�c
s���|���||�}||jurb��|���|g�D]*}|�vr6td�}t|�}t|||��q6|tustt|t	�r�z|��||�WnJt|t	�r�|j
|dj}t|��
�D]\}}	t�||	�q��Yn0dS)Nznot allowed with argument %sr)�add�_get_values�defaultrrrrr�
isinstancer�_name_parser_map�_argcomplete_namespace�vars�items�setattr)
r�argument_strings�
option_string�argument_values�conflict_action�msg�action_name�subnamespace�key�value)�action_conflicts�	namespace�seen_actions�seen_non_default_actions�selfrr�take_actionts(


�
zBIntrospectiveArgumentParser._parse_known_args.<locals>.take_actioncs��|}|\}}}�j}g}|dur:���|�|dS|du�r||d�}�j}|dkr�|d|vr�|�|g|f�|d}	|	|d}|dd�p�d}
�j}||vr�||}|
}ntd�}t|||��nB|dkr�|d}
|g}|�|||f��q�ntd�}t|||��q|d}�|d�}|g�_dt|<|||�}||}
�||
�}t|�t|<t	|��sx�j�
|�|�|||f��q�q|D]\}}}�|||��q�|
S)Nr
rrzignored explicit argument %r)�_match_argument�append�prefix_chars�_option_string_actionsrr�active_actionsr�lenr�remove)�start_index�option_tuplerr)�explicit_arg�match_argument�
action_tuples�	arg_count�chars�char�new_explicit_arg�
optionals_mapr,�stop�args�start�selected_patterns)�arg_strings�arg_strings_pattern�extras�option_string_indicesr5r6rr�consume_optional�sV




zGIntrospectiveArgumentParser._parse_known_args.<locals>.consume_optionalcs��j}�|d�}|�|�}t�|�D]\}}�j�|�q&t�|�D]6\}}�|||�}||7}t|�t|<�||�qF�t|�d��dd�<|S)N)�_match_arguments_partial�zipr;r8r<r)r>�
match_partial�selected_pattern�
arg_countsrrCrI)rLrM�positionalsr5r6rr�consume_positionals�s
zJIntrospectiveArgumentParser._parse_known_args.<locals>.consume_positionalsr���csg|]}|�kr|�qSrr)�.0�index)r>rr�
<listcomp>s�zAIntrospectiveArgumentParser._parse_known_args.<locals>.<listcomp>ztoo few argumentszargument %s is requiredcSsg|]}|jturt|��qSr)�helprr)rYrrrrr[Ds
�z#one of the arguments %s is required� )N)r�clearr$r;�fromfile_prefix_chars�_read_args_from_filesZ_action_conflicts�_mutually_exclusive_groups�_group_actions�	enumerate�
setdefault�extend�iterr8�_parse_optional�join�setZ_seen_non_default_actions�_get_positional_actions�max�min�errorr�_actions�requiredr)r5rLr2�mutex_group�
group_actions�i�mutex_action�	conflicts�arg_string_pattern_parts�arg_strings_iter�
arg_stringr?�patternrPrW�max_option_string_index�next_option_string_index�positionals_end_index�strings�
stop_indexr�name�group�namesr,r)r1rLrMrNr2rOrVr3r4r5r>r6r�_parse_known_args@s�





"U

�









�z-IntrospectiveArgumentParser._parse_known_argsN)�__name__�
__module__�__qualname__�__doc__r�rrrrr;srN)F)�argparserrrrrrrr	r
rrrrrrrrrrr�<module>s