
    k7ii                        S r SSKrSSKrSSKrSSKJrJrJr  SSKJ	r	J
r
JrJrJr  \	(       a  SSKJr  SSKJr  SSKJr  SSKJr  SS	KJr  SS
KJr  SSKJrJr  SSKJr  SSKJ r J!r!J"r"J#r#J$r$J%r%  \" S5      r& " S S\'\   5      r(SSS.S\S\
4   S\S-  S\S-  S\S-  S\'\   4
S jjr)S\S   S\(4S jr* S#S\+S\,S\(S\S   S-  S \\,   S!\-4S" jjr.g)$z3ArgumentCollection class and related functionality.    N)CallableIterableSequence)TYPE_CHECKINGAnySupportsIndexTypeVaroverload)App)UnknownOptionError)signature_parameters)Group)	Parameter)Token)UNSETis_iterable   )Argument)KIND_PARENT_CHILD_REASSIGNMENTPARAMETER_SUBKEY_BLOCKERextract_docstring_helpresolve_parameter_nameto_cli_option_namewalk_leavesTc                     ^  \ rS rSrSrU 4S jrS8S jr\S\S\	4S j5       r
\S\S\\	   4S j5       r
\S\S\	4S	 j5       r
S\\-  \-  S\	\\	   -  4U 4S
 jjr
S\S\4U 4S jjr\ S9SSS.S\\-  S\\   S\\/\4   S-  S\S\	4
S jjj5       r\SSS.S\\-  S\S\\/\4   S-  S\S\	\-  4
S jj5       r\4SSS.S\\-  S\S\\/\4   S-  S\S\	\-  4
S jjjrSSS.S\\-  S\\/\4   S-  S\S\\	\\S4   \4   4S jjrS\4S jrS r\SSSSS.S\\S4   S\S-  S\\\4   S \S!\S"\S#\\\S4   \4   S-  S$\S-  S%\4S& jj5       r \SSSSSS'.S(\S\S-  S\\\4   S-  S \S-  S!\S-  S"\S%\4S) jj5       r!\"S* 5       r#\"S+ 5       r$\"S\S-  4S, j5       r%SSSSSSSSS-.S.\S-  S/\S-  S0\S-  S1\\S4   S-  S2\&RN                  S-  S3\S-  S4\S-  S5\S-  SS 4S6 jjr(S7r)U =r*$ ):ArgumentCollection$   z,A list-like container for :class:`Argument`.c                     > [         TU ]  " U6   g N)super__init__)selfargs	__class__s     W/home/james-whalen/.local/lib/python3.13/site-packages/cyclopts/argument/_collection.pyr"   ArgumentCollection.__init__'   s    $    returnc                 $    [        U 5      " U 5      $ )z:Returns a shallow copy of the :class:`ArgumentCollection`.)typer#   s    r&   copyArgumentCollection.copy*   s    Dz$r(   termc                    g r     r#   r/   s     r&   __getitem__ArgumentCollection.__getitem__.   s    ?Br(   c                    g r    r1   r2   s     r&   r3   r4   0   s    =@r(   c                    g r    r1   r2   s     r&   r3   r4   2   s    58r(   c                 z   > [        U[        [        45      (       a  [        TU ]  U5      $ U R                  U5      $ r    )
isinstancer   slicer!   r3   get)r#   r/   r%   s     r&   r3   r4   4   s5     d]E2337&t,,xx~r(   itemc                x   > [        U[        5      (       a   X     g[        TU ]  U5      $ ! [         a     gf = f)aO  Check if an argument or argument name exists in the collection.

Parameters
----------
item : Argument | str
    Either an Argument object or a string name/alias to search for.

Returns
-------
bool
    True if the item is in the collection.

Examples
--------
>>> argument_collection = ArgumentCollection(
...     [
...         Argument(parameter=Parameter(name="--foo")),
...         Argument(parameter=Parameter(name=("--bar", "-b"))),
...     ]
... )
>>> "--foo" in argument_collection
True
>>> "-b" in argument_collection  # Alias matching
True
>>> "--baz" in argument_collection
False
TF)r8   strKeyErrorr!   __contains__)r#   r;   r%   s     r&   r?   ArgumentCollection.__contains__=   sE    8 dC  
 7'--  s   , 
99.N.	transform	delimiterdefaultrC   rD   c                    g r    r1   r#   r/   rE   rC   rD   s        r&   r:   ArgumentCollection.getb   s     r(   c                    g r    r1   rG   s        r&   r:   rH   k   s     r(   c                     U R                  XUS9u  n  nU$ ! [         aB    U[        L a4  [        U[        5      (       a  [        SU 35      Se[        SU S35      SeUs $ f = f)a  Get an :class:`Argument` by name or index.

This is a convenience wrapper around :meth:`match` that returns just
the :class:`Argument` object instead of a tuple.

Parameters
----------
term : str | int
    Either a string keyword or an integer positional index.
default : Any
    Default value to return if term not found. If :data:`~cyclopts.utils.UNSET` (default),
    will raise :exc:`KeyError`/:exc:`IndexError`.
transform : Callable[[str], str] | None
    Optional function to transform string terms before matching.
delimiter : str
    Delimiter for nested field access.

Returns
-------
Argument | None
    The matched :class:`Argument`, or ``default`` if provided and not found.

Raises
------
:exc:`KeyError`
    If ``term`` is a string and not found (when ``default`` is :data:`~cyclopts.utils.UNSET`).
:exc:`IndexError`
    If ``term`` is an int and is out-of-range (when ``default`` is :data:`~cyclopts.utils.UNSET`).

See Also
--------
:meth:`match` : Returns a tuple of (:class:`Argument`, keys, value) with more detailed information.
rB   zNo such Argument: NzArgument index z out of range)match
ValueErrorr   r8   r=   r>   
IndexError)r#   r/   rE   rC   rD   argument_s          r&   r:   rH   t   sz    R		!ZZYZWNHaO 	%dC(("%7v#>?TI$tfM%JKQUUN	s    A	A$#A$c                    SS[         penU  H@  n UR                  XUS9u  pUb  [        U5      [        U5      :  a  UnUnU	nU(       a  M@    O   Ub  Uc  [        SU< 35      eXEU4$ ! [         a     Mj  f = f)a	  Matches CLI keyword or index to their :class:`Argument`.

Parameters
----------
term: str | int
    One of:

    * :obj:`str` keyword like ``"--foo"`` or ``"-f"`` or ``"--foo.bar.baz"``.

    * :obj:`int` global positional index.

Raises
------
ValueError
    If the provided ``term`` doesn't match.

Returns
-------
Argument
    Matched :class:`Argument`.
tuple[str, ...]
    Python keys into :class:`Argument`. Non-empty iff :class:`Argument` accepts keys.
Any
    Implicit value (if a flag). :obj:`~.UNSET` otherwise.
NrB   zNo Argument matches )r   rK   rL   len)
r#   r/   rC   rD   best_match_argumentbest_match_keysbest_implicit_valuerN   
match_keysimplicit_values
             r&   rK   ArgumentCollection.match   s    @ EI$PU.AH-5^^Daj^-k*
 &#j/C<P*P",&.#&4#:  &/*A3D8<=="5HHH  s   A))
A76A7valc                 "    U  H	  nXl         M     g r    )_marked)r#   rX   rN   s      r&   
_set_marksArgumentCollection._set_marks   s    H" r(   c                     U R                  S5        [        U S S9 H&  nUR                  (       a  M  UR                  5         M(     g)z"Convert and validate all elements.Fc                     U R                   $ r    keys)xs    r&   <lambda>-ArgumentCollection._convert.<locals>.<lambda>   s    166r(   )keyN)r[   sortedrZ   convert_and_validater#   rN   s     r&   _convertArgumentCollection._convert   s8    t)9:H))+ ;r(   T)parse_docstringdocstring_lookuppositional_index_resolve_groupsr`   default_parametersgroup_lookupgroup_argumentsgroup_parametersrj   rk   rl   rm   c                (  ^" SSK Jn  U " 5       nUc  0 n/ nUR                  nU" U5      u  pUR                  U5        U(       dM  UR                  UR
                  L a  [        [        U4   nO$UR                  UR                  L a  [        US4   nU	(       Ga;  / nU GH1  m"/ nT"R                   HI  n[        U[        5      (       a  UU   nUR                  U5        UR                  UR                  5        MK     UR                  T"5        U(       d  My  [        S U 5       5      n[        S U 5       5      nU(       a  UR                  [!        US95        M  U(       aT  UR                  UR"                  UR                  4;   a  UOUnU4[        U5      -   nUR                  [!        US95        GM  UR                  [!        US95        GM4     OUn[         R$                  " UR                  UR"                  UR                  4;   a	  [!        US9O[!        US9/U
Q76 n[         R$                  " U6 nU(       a  [         R$                  " U[&        U5      m"[         R$                  " T"[!        [)        UR*                  UR*                  =(       d    [        U"4S jUR,                   5       5      T"R.                  -   5      S95      m"GO[         R$                  " UU5      m"[        T"R.                  [        5      (       d   eT"R*                  (       aq  UR0                  (       a_  [        T"R*                  [        5      (       d   e[         R$                  " T"[!        [)        T"R*                  T"R.                  -   5      S95      m"OUR                  UR"                  UR                  4;   a0  [         R$                  " T"[!        S	 UR,                   5       S95      m"OUR                  UR
                  L a  [         R$                  " T"[!        S
S95      m"O`T"R2                  c   e[         R$                  " T"[!        [        U"4S jUR,                   5       5      [)        T"R.                  5      -   S95      m"UR4                  (       a  S n[7        UT"X.S9nUb.  UR8                  (       a  UR:                  (       a  UUl        US-  nUR                  U5        UR8                  (       Ga  U(       a  [?        UR                  5      O0 nURA                  U5        URB                  RE                  5        GHZ  u  nn[F        URH                  R                  UR                  4   nUc  M5  UUl        UR4                  (       a  S nURE                  5        VVs0 s H(  u  nnUS   U:X  d  M  [K        U5      S:  d  M"  USS  U_M*     n nnU RM                  UUU4-   T"URN                  (       a  [!        URN                  S9OURQ                  U45      [!        URR                  URR                  -  S9UUUUU UU	S9n!U!(       d  GM  URT                  R                  U!S   5        UR                  U!5        Uc  GMC  U!RV                  nUc  GMU  US-  nGM]     U$ s  snnf )Nr   )get_parameters.c              3   8   #    U  H  oR                   v   M     g 7fr    )show.0gs     r&   	<genexpr>0ArgumentCollection._from_type.<locals>.<genexpr>  s     +LOqFFOs   c              3   B   #    U  H  oR                   (       + v   M     g 7fr    namerv   s     r&   ry   rz     s     &K?a66zz?s   )groupc              3   F   >#    U  H  nTR                  U5      v   M     g 7fr    name_transform)rw   ra   cparams     r&   ry   rz   :  s#     :n]mXY6;P;PQR;S;S]ms   !r|   c              3   @   #    U  H  oR                  5       v   M     g 7fr    )upper)rw   r}   s     r&   ry   rz   M  s     Fq`pX\zz||`ps   )z--[KEYWORD]c              3   L   >#    U  H  nS TR                  U5      -   v   M     g7f)z--Nr   )rw   r}   r   s     r&   ry   rz   U  s#     &gVfdtf.C.CD.I'IVfs   !$)
field_info	parameterr`   hintr   help)required)ro   rp   rq   rj   rk   rl   rm   ),cyclopts.parameterrs   r   extendkindVAR_KEYWORDdictr=   VAR_POSITIONALtupler~   r8   appenddefault_parameteranyallr   POSITIONAL_ONLYcombiner   r   r}   namesalias
is_keywordr   is_keyword_onlyr   _accepts_keywords_enum_flag_typeindexr   update_lookupitemsr   r   rQ   
_from_typer   r:   r   children
_max_index)#clsr   r`   ro   rp   rq   rj   rk   rl   rm   rn   rs   outcyclopts_parameters_no_groupr   hint_parameterscyclopts_parametersresolved_groupsr~   has_visible_groupall_namelessdefault_group
all_groupsupstream_parameterimmediate_parameterrN   hint_docstring_lookupsub_field_namesub_field_infoupdated_kindkvsubkey_docstring_lookupsubkey_argument_collectionr   s#                                     @r&   r   ArgumentCollection._from_type   s    	6e#!')$ .t 4$++O<*"8"88CIJ$=$==T3Y'"$6"$#\\E!%-- ,U 3#**51'..u/F/FG	 *
 $**62"?(++LO+L(L%#&&K?&K#KL(+229?3ST%  *:3M3MzOhOh2ii ,!1 &
 '4%5o8N%N
+229:3NO+229?3ST1 74 #?&.. ??z'A'A:C\C\&]] 0%56	
  
 (//1DE&&"(#F
 &&/*//,11nU:n]g]m]m:n5n ,,'	F &&"#F fllE2222{{((%fkk59999&..	/EfkkTZT`T`F`/a bF ??z'A'A:C\C\&]]&..vyFq`j`p`pFq7rsF__
(>(>>&..vyFV7WXF!00<<<&..!!&&gV`VfVf&g!g4V\\B"CF %%#zV$Z'--1I1I!1 A% 

8%%%M\$:8==$Ibd!!(()9:2:2B2B2H2H2J.=x?R?R?W?WYgYlYl>mn'&2#!11'+$ *?)D)D)F+)FA!A$R`J`HehijeknoeoHAabE1H)F ( + .1^^"N,, *.. "~':':;2667HIx'8'8>;R;R'RS!-$3%5$3%<%5$3! .< .*$ .-%%,,-G-JKJJ9:'3+E+P+P(+7,1,O 3KR 
?+s   Z#Z4
Z)ro   rp   rq   rj   rm   funcc                   U " 5       nUc  [         R                  " 5       nUc  [         R                  " 5       nU(       a,  [        U/UQ7UUS.6 V	s0 s H  n	U	R                  U	_M     nn	O0 nU(       a  [        U5      O0 n
Sn[        U5      R                  5        H  nU(       aO  U
R                  5        VVs0 s H1  u  pUS   UR                  :X  d  M  [        U5      S:  d  M+  USS  U_M3     nnnOS nU R                  " US/UQUR                  (       a  [        UR                  S9OU
R                  UR                  45      P7UUUUUUUS.6nUb  UR                  nUb  US-  nUR                  U5        M     U$ s  sn	f s  snnf )Nrp   rq   r   r   r1   r   )ro   rp   rq   rl   rj   rk   rm   )r   create_default_argumentscreate_default_parameters_resolve_groups_from_callabler}   r   r   valuesr   rQ   r   r   r   r:   r   r   )r   r   ro   rp   rq   rj   rm   rn   r   r~   rk   rl   r   r   r   r   iparam_argument_collections                    r&   _from_callable!ArgumentCollection._from_callable  s    e"#<<>O#$>>@ ;' %4%5	E 

E!  L L;J1$7PR.t4;;=J)9)?)?)A+)AQqTZ__E\HadefagjkakHAabE1H)A ( +' +/'),* $* 4>??	z/HXH\H\^h^m^m]oHp	*
 * /!1!1 /!8 /*&  +#=#H#H #/$)$JJ121 >4 
Q +s   F9FF'
Fc                     / nU  Hc  n[        UR                  R                  [        5      (       d   eUR                  R                   H  nX1;  d  M
  UR	                  U5        M     Me     U$ r    )r8   r   r~   r   r   )r#   groupsrN   r~   s       r&   r   ArgumentCollection.groups  s_    Hh0066>>>>!++11&MM%( 2 
 r(   c              #   L   #    U  H  nUR                   (       a  M  Uv   M     g 7fr    r_   rg   s     r&   _root_arguments"ArgumentCollection._root_arguments  s     H=== s   $	$c                 $    [        S U  5       S S9$ )Nc              3   V   #    U  H  oR                   c  M  UR                   v   M!     g 7fr    )r   )rw   ra   s     r&   ry   0ArgumentCollection._max_index.<locals>.<genexpr>  s     ATWWGAGGTs   )))rE   )maxr,   s    r&   r   ArgumentCollection._max_index  s    ATA4PPr(   )r~   
has_tokenshas_tree_tokenskeys_prefixr   parseru   	value_setr~   r   r   r   r   r   ru   r   c                  ^^^^^^^^ U R                  5       n	[        U 5      n
Tb  U
" U4S jU	 5       5      n	Tb  U
" U4S jU	 5       5      n	Tb  U
" U4S jU	 5       5      n	Tb  U
" U4S jU	 5       5      n	Tb  U
" U4S jU	 5       5      n	Tb  U
" U4S jU	 5       5      n	Tb  U
" U4S jU	 5       5      n	Tb  U
" U4S jU	 5       5      n	U	$ )	a  Filter the :class:`ArgumentCollection`.

All non-None filters will be applied.

Parameters
----------
group: Group | None
    The :class:`.Group` the arguments should be in.
has_tokens: bool | None
    Immediately has tokens (not including children).
has_tree_tokens: bool | None
    :class:`Argument` and/or it's children have parsed tokens.
kind: inspect._ParameterKind | None
    The :attr:`~inspect.Parameter.kind` of the argument.
parse: bool | None
    If the argument is intended to be parsed or not.
show: bool | None
    The :class:`Argument` is intended to be show on the help page.
value_set: bool | None
    The converted value is set.
c              3   `   >#    U  H#  nTUR                   R                  ;   d  M  Uv   M%     g 7fr    )r   r~   rw   ra   r~   s     r&   ry   /ArgumentCollection.filter_by.<locals>.<genexpr>
  s$     A1eq{{/@/@&@QQs   .	.c              3   ^   >#    U  H"  oR                   R                  T:X  d  M  Uv   M$     g 7fr    )r   r   )rw   ra   r   s     r&   ry   r     s"     @1ll&7&74&?QQ   -	-c              3   x   >#    U  H/  n[        UR                  5      [        T5      -  (       a  M+  Uv   M1     g 7fr    booltokens)rw   ra   r   s     r&   ry   r     s'     N14>D<L+LQQ   *:	:c              3   x   >#    U  H/  n[        UR                  5      [        T5      -  (       a  M+  Uv   M1     g 7fr    r   )rw   ra   r   s     r&   ry   r     s'     S14>D<Q+QQQr   c              3   b   >#    U  H$  oR                   S [        T5       T:X  d  M   Uv   M&     g 7fr    )r`   rQ   )rw   ra   r   s     r&   ry   r     s)     P1ff-?s;/?&@K&OQQs   /	/c              3   d   >#    U  H%  oR                   [        T5      -  (       a  M!  Uv   M'     g 7fr    )ru   r   )rw   ra   ru   s     r&   ry   r     s      @166DJ+>QQs    0	0c              3   p   >#    U  H+  oR                   [        L [        T5      -  (       d  M'  Uv   M-     g 7fr    )valuer   r   )rw   ra   r   s     r&   ry   r     s%     M15(8DO'KQQs   &6	6c              3   f   >#    U  H&  oR                   R                  T-  (       a  M"  Uv   M(     g 7fr    )r   r   )rw   ra   r   s     r&   ry   r     s"     F1;;+<+<u+DQQs   !1	1)r-   r+   )r#   r~   r   r   r   r   r   ru   r   acr   s    ````````  r&   	filter_byArgumentCollection.filter_by  s    B YY[4jAAAB@@@B!NNNB&SSSB"PPPB@@@B MMMBFFFB	r(   r1   )r)   r   ).)+__name__
__module____qualname____firstlineno____doc__r"   r-   r
   r   r   r3   r9   listr=   objectr   r?   intr+   r   r   r:   r   r   r   rK   r[   rh   classmethodr   r   r   r   r   propertyr   r   r   inspect_ParameterKindr   __static_attributes____classcell__)r%   s   @r&   r   r   $   sv   6   BBXB B@@T(^@ @8888 8M!E) 
DN	"#. #.t #.J   #
 26Ci e
 SE3J'$.  
   26Ci 
 SE3J'$.  
A  2
 262Ci2 2
 SE3J'$.2 2 
C2p 260ICi0I SE3J'$.	0I
 0I 
xsCx#-	.0Id#d #,  !%DH'+ $k CHok '-	k
 3:&k k  k k uS#X	9:TAk *k k kZ 
 15(,)- $ $:: '-: 3:&-	:
 :  $,: : : :x    
 QC$J Q Q #"&'+.2.2! !%5 t|5 4K	5
 5 38_t+5 $$t+5 d{5 Tk5 $;5 
5 5r(   r   r   r   .rn   rp   rq   r)   c                .  ^ [         R                  " U /UQ7UUSSS.6n/ nUb  UR                  U5        Ub  UR                  U5        U H  nUR                  R                   H  m[        T[        5      (       d  M  [        U4S jU 5       5      (       a  [        S5      eTR                  b&  TR                  R                  (       a  [        S5      e [        U4S jU 5       5        M     M     U HM  nUR                  R                   H0  m[        T[        5      (       d  M   [        U4S jU 5       5        M2     MO     U$ ! [         a    UR                  T5         GM  f = f! [         a    UR                  [        T5      5         M  f = f)NF)rp   rq   rj   rm   c              3   n   >#    U  H*  nTU:g  =(       a    UR                   TR                   :H  v   M,     g 7fr    _namer   s     r&   ry   0_resolve_groups_from_callable.<locals>.<genexpr>7  s*     R/Q5A:8!''U[["88/s   25z8Cannot register 2 distinct Group objects with same name.z6Group.default_parameter cannot have a specified group.c              3   ^   >#    U  H"  oR                   TR                   :X  d  M  Uv   M$     g 7fr    r   r   s     r&   ry   r   >  s      J177ekk3IQQr   c              3   J   >#    U  H  oR                   T:X  d  M  Uv   M     g 7fr    r|   r   s     r&   ry   r   G  s     C166U?QQs   #	#)r   r   r   r   r~   r8   r   r   rL   r   nextStopIterationr=   )r   rp   rq   rn   argument_collectionr   rN   r~   s          @r&   r   r     s{    -;;	 () O"/#/0'''--EeU++R/RRR ![\\&&2u7N7N7T7T !YZZ.JJJ . (  (''--EeS))5CCC	 . (  ! .&&u--. ! 5&&uU|45s$   E	*E,	E)(E),$FFappsr   c                     [        5       nU  H;  nUR                  c  M  UR                  UR                  R                  5       5        M=     U$ r    )r   _metar   assemble_argument_collection)r  r   apps      r&   _meta_argumentsr  N  sE    ,.99""399#I#I#KL  r(   configsource	arguments	root_keysallow_unknownc                   [        U=(       d    S5      n0 nU R                  5        He  u  p[        U	5       HQ  u  p[        U/U
Q76 nSR	                  S [
        R                  " XH4U
5       5       5      n UR                  U5        MS     Mg     g! [         a     Of = fSnSn UR                  U5      u  pnGO! [         Ga    U
(       Ga  U H  n[        U
5      [        UR                  5      :w  a  M'  Sn[        [        U
UR                  SS95       H  u  nu  nnUU:X  a  M  U[        UR                  5      S-
  :X  a   UUR                  R                  ;  a  Sn  O^MM  UR                  SUS-    nSnU H3  nUR                  U:X  d  M  UUR                  R                  ;   d  M1  Sn  O   U(       a  M  Sn  O   U(       d  M  UnSn   O    Of = fU(       d:  U(       a  GM  U(       a  US	   R                  (       a  GM  [!        [#        XS
9US9SeUR%                  ['        U5      [)        UR*                  5      5      (       a  GM  [-        U5      (       d  U4nU(       a  [        U5       Hs  u  nnUc  [#        USUUUS9nOK[/        U[0        [2        -  5      (       a  [4        R6                  " U5      nO[9        U5      n[#        UUUUUS9nUR;                  U5        Mu     GM  [#        XUSUS9nUR;                  U5        GM  )a  Updates an argument collection with values from a configuration dictionary.

This function takes configuration data (typically from JSON, TOML, YAML files
or environment variables) and populates the corresponding arguments in the
ArgumentCollection with tokens representing those values.

The function handles various naming conventions, including:
- Exact matches (e.g., "storage_class" matches "storage_class")
- Transformed matches (e.g., "storage-class" matches "storage_class")
- Pydantic aliases (e.g., "storageClass" matches field with alias "storageClass")

Parameters
----------
config : dict
    Configuration dictionary with nested structure mapping to CLI arguments.
source : str
    Source identifier (e.g., file path or "env") for error messages and tracking.
arguments : ArgumentCollection
    Collection of arguments to populate with configuration values.
apps : Optional[Sequence[App]]
    Stack of App instances for meta-argument handling.
    We need to know all the meta-apps leading up to the current application so that we can
    properly detect unknown keys.
root_keys : Iterable[str]
    Base path keys to prepend to all configuration keys.
allow_unknown : bool
    If True, ignore unrecognized configuration keys instead of raising errors.

Raises
------
UnknownOptionError
    If a configuration key doesn't match any argument and allow_unknown is False.

Notes
-----
Arguments that already have tokens are skipped to preserve command-line
precedence over configuration files.
r1    c              3   .   #    U  H  nS U S3v   M     g7f)[]Nr1   )rw   r   s     r&   ry   -update_argument_collection.<locals>.<genexpr>  s     &l9kA1#Qx9ks   NTF)strictr   )keywordr  )tokenr   )r  rV   r  r   r`   )r  r   r  r   r`   r   )r  r   r   r   join	itertoolschainrK   rL   rQ   r`   	enumeratezipr   r   _meta_parentr   r   
setdefaultidr   r   r   r8   r   r   jsondumpsr=   r   )r  r  r	  r  r
  r  meta_argumentsdo_not_update
option_keyoption_valuesubkeysr   cli_option_namecomplete_keywordrN   remaining_keysrO   arg	all_matchisubkeyarg_keyparent_keysalias_found
parent_argr   r  	value_strs                               r&   update_argument_collectionr1  W  s   ^ %TZR0NM$*LLN 
),7NG0FgFO!ww&lTacj9k&ll$$_5 8 %3   HN".7ooo.N+! "(w<3sxx=8$$(	4=c'388\a>b4c0A0%0 ( CMA$55#)1E1E#E05I$) $F /2hhwQ.?.32;J'1+'E&T^TiTiToToJo6:(- 3< (3{05I$)# 5d& %9'*H-/N!7  )">  DH11((8H^g ''8d8??6KLLu%%%e,DAqy %$4+/#)"#!/! &a55(,

1I(+AI %$4If\]dr! OOE*% -( ,6YZao &sC   7B
BB&B<<CGG,G;G
GGGr    )/r   r   r  r  collections.abcr   r   r   typingr   r   r   r	   r
   cyclopts.corer   cyclopts.exceptionsr   cyclopts.field_infor   cyclopts.groupr   r   r   cyclopts.tokenr   cyclopts.utilsr   r   	_argumentr   utilsr   r   r   r   r   r   r   r   r   r   r  r   r=   r   r1  r1   r(   r&   <module>r<     s*   9    8 8 G G! ! (   -   CLvh vx %)%)	.
38
."T). T\. dl	.
 
%[.b(5/ .@  $(	H'H'H' "H' 5/D
 	H' }H' H'r(   