
    i                    r	   % S SK Jr  S SK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JrJrJrJrJrJrJrJrJrJrJrJrJrJrJrJ r J!r!J"r"J#r#J$r$J%r%J&r&J'r'  S SK(J)r)J*r*  S SK+J,r,J-r-  \(       a  S S	KJ.r.  S S
KJ/r/J0r0  S SK1J2r2  S SK3J4r4  0 S\,Rj                  _S\,Rj                  _S\,Rj                  _S\,Rj                  _S\,Rl                  _S\,Rl                  _S\,Rl                  _S\,Rl                  _S\,Rl                  _S\,Rl                  _S\,Rn                  _S\,Rn                  _S\,Rn                  _S\,Rn                  _S\,Rp                  _S\,Rp                  _S\,Rr                  _\,Rt                  \,Rv                  \,Rx                  \,Rz                  \,R|                  \,R|                  \,R~                  \,R                  \,R                  \,R                  \,R                  S.ErC\D\E\F\G   4   rH\F\H   rI\D\I\E4   rJ\R                  " S\R                  5      rMS \NS!'   \R                  " S"5      rOS \NS#'   \R                  " S$5      rPS \NS%'   \R                  " S&5      rQS \NS''   S(S).SMS* jjrRSNS+ jrSS(S(S(S,.             SOS- jjrT        SPS. jrUS(S/.         SQS0 jjrVS(S/.         SRS1 jjrWS(S).         SSS2 jjrXS(S).         STS3 jjrYS(S).         SUS4 jjrZ        SVS5 jr[S(S).         SWS6 jjr\S(S).         SXS7 jjr]S(S).         SYS8 jjr^S(S9.         SZS: jjr_S(S(S;.           S[S< jjr`S=S S>.         S\S? jjraS(S(S(S(S@.               S]SA jjrbS(S(S(S(S@.               S^SB jjrcS(S(S(S(SC.               S_SD jjrdS(SE.         S`SF jjreSaSG jrf\,Rj                  \U\,Rl                  \V\,Rn                  \W\,Rp                  \]\,R                  \^\,Rx                  \e\,Rz                  \X\,R|                  \Y\,R~                  \Z\,R                  \[\,R                  \\\,Rr                  \b\,Rt                  \c\,Rv                  \d0rg " SH SI\S=SJ9rhS=S(S(S(S=S(S(S(S(S(SK.
                         SbSL jjrig)c    )annotationsN)suppress)TYPE_CHECKING	TypedDict)warn)DocstringAttributeDocstringClassDocstringFunctionDocstringModuleDocstringParameterDocstringRaiseDocstringReceiveDocstringReturnDocstringSectionDocstringSectionAdmonitionDocstringSectionAttributesDocstringSectionClassesDocstringSectionExamplesDocstringSectionFunctionsDocstringSectionModulesDocstringSectionOtherParametersDocstringSectionParametersDocstringSectionRaisesDocstringSectionReceivesDocstringSectionReturnsDocstringSectionTextDocstringSectionTypeAliasesDocstringSectionTypeParametersDocstringSectionWarnsDocstringSectionYieldsDocstringTypeAliasDocstringTypeParameterDocstringWarnDocstringYield)docstring_warningparse_docstring_annotation)DocstringSectionKindLogLevel)Pattern)AnyLiteral)Expr)	Docstringargs	argumentsparams
parameterszkeyword argszkeyword argumentsz
other argszother argumentszother paramszother parametersz	type argsztype argumentsztype paramsztype parametersraises
exceptionsreturns)yieldsreceivesexamples
attributes	functionsmethodsclassesztype aliasesmoduleswarnswarningsz4^(?P<type>[\w][\s\w-]*):(\s+(?P<title>[^\s].*))?\s*$r)   _RE_ADMONITIONz=^(?:(?P<name>\w+)?\s*(?:\((?P<type>.+)\))?:\s*)?(?P<desc>.*)$_RE_NAME_ANNOTATION_DESCRIPTIONz^\s*<BLANKLINE>\s*$_RE_DOCTEST_BLANKLINEz(\s*#\s*doctest:.+)$_RE_DOCTEST_FLAGST)r>   c                  U R                   nU[        U5      :  a  / U4$ Un/ n[        XE   5      (       a  US-  n[        XE   5      (       a  M  [        XE   5      [        XE   R                  5       5      -
  nUS:X  a  / US-
  4$ XTU   US  /4nUS-  nU[        U5      :  Ga'  XE   n	[        U	5      (       a  US   R	                  S5        OU	R                  US-  S-  5      (       a  US   R	                  XS-  S  5        OU	R                  US-   S-  5      (       ab  [        U	5      [        U	R                  5       5      -
  n
US   R	                  XS  5        U(       a  [        U USUS-    SU SUS-   S	U
 35        O3U	R                  US-  5      (       a  UR	                  U5        XYUS  /4nOOUS-  nU[        U5      :  a  GM'  U(       a  UR	                  U5        XeS-
  4$ )
N   r        z,Confusing indentation for continuation line z in docstring, should be z * 2 = z spaces, not )lineslen_is_empty_linelstripappend
startswithr%   )	docstringoffsetr>   optionsrH   
new_offsetitemsindentcurrent_itemlinecont_indents              \/home/james-whalen/.local/lib/python3.13/site-packages/griffe/_internal/docstrings/google.py_read_block_itemsrX   ]   s   OOEU6zJE *
+
+a
 *
+
+ "#c%*;*B*B*D&EEF{:>!! z!267!; <=L!OJ s5z
! $O""2&__VaZ#-..O""4
#56__fqjC/00d)c$++-&88KO""4#56!B:PQ>BR S!!'
|=W __Vc\**LL&&fg8L a
A s5z
!D \"q.      c                  U R                   nU[        U5      :  a  SUS-
  4$ Un/ n[        X4   5      (       a  US-  n[        X4   5      (       a  M  [        X4   5      [        X4   R                  5       5      -
  nUS:X  a  SUS-
  4$ UR	                  X4   R                  5       5        US-  nU[        U5      :  a  X4   R                  US-  5      (       d  [        X4   5      (       a[  UR	                  X4   US  5        US-  nU[        U5      :  a1  X4   R                  US-  5      (       a  MG  [        X4   5      (       a  M[  SR                  U5      R                  S5      US-
  4$ )NrE   rD   r   rG   
)rH   rI   rJ   rK   rL   rM   joinrstrip)rN   rO   rP   rH   rQ   blockrS   s          rW   _read_blockr_      sa   OOEU6A:~JE *
+
+a
 *
+
+ "#c%*;*B*B*D&EEF{6A:~ 
LL"))+,!OJ s5z
!u'8'C'CFSL'Q'QUcdiduUvUvU&vw/0a
 s5z
!u'8'C'CFSL'Q'QUcdiduUvUv 99U""4(*q.88rY   )warn_unknown_paramswarn_missing_typesr>   c          
        / n[        U 4XS.UD6u  pxU GH  u  p U
S   R                  SS5      u  pSR	                  UR                  5       /U
SS  Q5      R                  S5      nSU;   at  UR                  S	5      (       a^  UR                  SS5      u  pUR                  5       nUR                  S	5      R                  S
5      R                  5       n[        X5      nO&Un U R                  R                  U   R                  n U R                  R                  U   R                   nU(       a  U(       a  Uc  [        X	SU S35        U(       ao  U(       ah  [#        [        5         U R                  R                  nUU;  a4  SU S3nSU 3SU 34 H  nUU;   d  M  USU S3-  n  O   [        X	U5        S S S 5        UR%                  ['        XXS95        GM     Xh4$ ! [         a     U(       a  [        U U	SU
S    S35         GM  f = f! [        [        4 a    S n GNf = f! [        [        4 a    S n GNf = f! , (       d  f       N= f)NrO   r>   r   :rD   -Failed to get 'name: description' pair from ''r[   ()
, optionalz%No type or annotation for parameter 'zParameter 'z+' does not appear in the function signature***. Did you mean ''?namevalue
annotationdescription)rX   split
ValueErrorr%   r\   rK   r]   endswithstripremovesuffixr&   parentr1   rq   AttributeErrorKeyErrordefaultr   rL   r   )rN   rO   r`   ra   r>   rP   r1   r^   rQ   line_numberparam_linesname_with_typerr   ro   rq   r{   r0   messagestarred_names                      rW   _read_parametersr      sv    J *)aFaY`aE %* 		*5a.*>*>sA*F'N ii!3!3!5 HAB HIPPQUV . ^%<%<S%A%A-33C;D::<D#005BB<PVVXJ3JJJ!D"&--88>II
	&&11$7??G *z/Ai8]^b]ccd6ef+.)"))44v% +D61\]G+,TFr$[(A'61#)9,r'JJG! )B &igF * 	,$R\vwc %*f !!_  	!CKPQNCSSTU
 	. #H- "!
"
 ) 	G	 *)sG   G#$#H#H))4I!I#%HHH&%H&)H?>H?
I	c               <    [        U 4SU0UD6u  p4[        U5      U4$ NrO   )r   r   )rN   rO   rP   r1   rQ   s        rW   _read_parameters_sectionr     s+     .iRR'RJ%j1:==rY   )r`   c               >    [        U 4USS.UD6u  pE[        U5      U4$ )NF)rO   r`   )r   r   )rN   rO   r`   rP   r1   rQ   s         rW   _read_other_parameters_sectionr     s/     .im\amelmJ*:6
BBrY   c          
     Z   / n[        U 4SU0UD6u  pVU GH  u  px US   R                  SS5      u  pSR	                  U
R                  5       /USS  Q5      R                  S5      n
SU	;   aQ  U	R                  SS5      u  pUR                  S	5      (       a  UR                  S
5      (       a  USS n[        X5      nO&U	n U R                  R                  U   R                  n U R                  R                  U   R                  nU(       a  [!        [        5         U R                  R                  nX;  aU  SU SU R                  R"                  R$                   S3nSU 3SU 34 H  nUU;   d  M  USU S3-  n  O   [        XU5        S S S 5        UR'                  [)        UUUU
S95        GM     [+        U5      U4$ ! [         a    [        U USUS    S35         GM  f = f! [        [        4 a    S n GNf = f! [        [        4 a    S n GNf = f! , (       d  f       N= f)NrO   r   rd   rD   re   rf   r[   rG   rg   rh   zType parameter 'z' does not appear in the z
 signaturerj   rk   rl   rm   rn   )rX   rs   rt   r%   r\   rK   r]   rM   ru   r&   rx   type_parametersrq   ry   rz   r{   r   kindrp   rL   r"   r   )rN   rO   r`   rP   r   r^   rQ   r|   type_param_linesname_with_boundrr   ro   boundr{   type_paramsr   r   s                    rW   _read_type_parameters_sectionr     se    O *)NFNgNE).%	+;A+>+D+DS!+L(O ii!3!3!5 M8H8L MNUUVZ[ /!)//Q7KD$$)<)<a.u@E"D!((88>II	&&66t<DDG .)'..>>* 06OPYP`P`PePePkPkOllvwG+,TFr$[(A';6#)9,r'JJG! )B &igF * 	" '		
[ */l */:JFFe  	?@PQR@S?TTUV
 	, #H- 
 ) 	G	 *)sH   G#G*%#HAH6HG'&G'*H ?H HH
H*	c          	        / n[        U 4XS.UD6u  pVS nU H  u  p U	S   R                  SS5      u  pSR	                  UR                  5       /U	SS  Q5      R                  S5      nSU
;   aB  U
R                  SS5      u  pUR                  S	5      nUR                  S
5      n[        Xp5      nO=U
n[        [        [        [        5         U R                  U   R                  nS S S 5        UR!                  [#        XUS95        M     [%        U5      U4$ ! [         a     U(       a  [        U USU	S    S35         GM)  f = f! , (       d  f       Ne= f)Nrc   r   rd   rD   re   rf   r[   rG   z()ri   ro   rq   rr   )rX   rs   rt   r%   r\   rK   r]   rv   rw   r&   r   ry   rz   	TypeErrorrx   rq   rL   r   r   )rN   rO   r>   rP   r8   r^   rQ   rq   r|   
attr_linesr~   rr   ro   s                rW   _read_attributes_sectionr   [  sc    J))aFaY`aE$(J#(		*4Q-*=*=c1*E'N ii!3!3!5 G
12 GHOOPTU. -33C;D#))$/J#00>J3JJJ!D.(I>&--d3>>
 ? 	,$[fgh5 $)8 &j1:==3  	!CJqM?RST
 	& ?>s   DE%E E
E	c          	        / n[        U 4XS.UD6u  pVS nU H  u  p U	S   R                  SS5      u  pSR	                  UR                  5       /U	SS  Q5      R                  S5      nSU
;   a  U
R                  SS5      S   nU
nOU
nS nUR                  [        XUS	95        M     [        U5      U4$ ! [         a    U(       a  [        U USU	S    S35         M  f = f
Nrc   r   rd   rD   z2Failed to get 'signature: description' pair from 'rf   r[   rg   r   )
rX   rs   rt   r%   r\   rK   r]   rL   r
   r   )rN   rO   r>   rP   r9   r^   rQ   	signaturer|   
func_linesname_with_signaturerr   ro   s                rW   _read_functions_sectionr     s    I))aFaY`aE#'I#(		/9!}/B/B3/J, ii!3!3!5 G
12 GHOOPTU%%&,,S!4Q7D+I&DI*Xcde+ $). %Y/;;)  	!HTUWXY
 	   B44%CCc          	        / n[        U 4XS.UD6u  pVS nU H  u  p U	S   R                  SS5      u  pSR	                  UR                  5       /U	SS  Q5      R                  S5      nSU
;   a  U
R                  SS5      S   nU
nOU
nS nUR                  [        XUS	95        M     [        U5      U4$ ! [         a    U(       a  [        U USU	S    S35         M  f = fr   )
rX   rs   rt   r%   r\   rK   r]   rL   r	   r   )rN   rO   r>   rP   r;   r^   rQ   r   r|   class_linesr   rr   ro   s                rW   _read_classes_sectionr     s    G))aFaY`aE#'I$) 		/:1~/C/CC/K, ii!3!3!5 HAB HIPPQUV%%&,,S!4Q7D+I&DI~4S^_`+ %*. #7+Z77)  	!HUVHXXYZ
 	r   c          	     h   / n[        U 4SU0UD6u  pEU Hi  u  pg US   R                  SS5      u  pSR	                  U	R                  5       /USS  Q5      R                  S5      n	UR                  [        XS95        Mk     [        U5      U4$ ! [         a    [        U USUS    S35         M  f = f)	NrO   r   rd   rD   re   rf   r[   ro   rr   )
rX   rs   rt   r%   r\   rK   r]   rL   r!   r   )
rN   rO   rP   type_aliasesr^   rQ   r|   type_alias_linesro   rr   s
             rW   _read_type_aliases_sectionr     s     L))NFNgNE).%	 0 3 9 9#q AD ii!3!3!5 M8H8L MNUUVZ[.DRS */ '|4j@@  	?@PQR@S?TTUV
 	s   BB10B1c          	     v   / n[        U 4XS.UD6u  pVU Hi  u  px US   R                  SS5      u  pSR	                  U
R                  5       /USS  Q5      R                  S5      n
UR                  [        XS95        Mk     [        U5      U4$ ! [         a    U(       a  [        U USUS    S35         M  f = f)	Nrc   r   rd   rD   re   rf   r[   r   )
rX   rs   rt   r%   r\   rK   r]   rL   r   r   )rN   rO   r>   rP   r<   r^   rQ   r|   module_linesro   rr   s              rW   _read_modules_sectionr     s     G))aFaY`aE%*!		 ,Q 5 5c1 =D ii!3!3!5 IQR8H IJQQRVWDJK &+ #7+Z77  	!CLQROCTTUV
 	   B%B87B8c          	        / n[        U 4XS.UD6u  pVU Ht  u  px US   R                  SS5      u  pSR	                  U
R                  5       /USS  Q5      R                  S5      n
[        X5      n	UR                  [        XS95        Mv     [        U5      U4$ ! [         a    U(       a  [        U USUS    S35         M  f = f)	Nrc   r   rd   rD   z2Failed to get 'exception: description' pair from 'rf   r[   rq   rr   )rX   rs   rt   r%   r\   rK   r]   r&   rL   r   r   )rN   rO   r>   rP   r3   r^   rQ   r|   exception_linesrq   rr   s              rW   _read_raises_sectionr     s     J))aFaY`aE ).$		&5a&8&>&>sA&F#J ii!3!3!5 L8K LMTTUYZ/
F
.JXY )." "*-z99  	!HYZI[H\\]^
 	s   B%CCc          	     v   / n[        U 4XS.UD6u  pVU Hi  u  px US   R                  SS5      u  pSR	                  U
R                  5       /USS  Q5      R                  S5      n
UR                  [        XS95        Mk     [        U5      U4$ ! [         a    U(       a  [        U USUS    S35         M  f = f)	Nrc   r   rd   rD   z0Failed to get 'warning: description' pair from 'rf   r[   r   )
rX   rs   rt   r%   r\   rK   r]   rL   r#   r   )rN   rO   r>   rP   r=   r^   rQ   r|   warning_linesrq   rr   s              rW   _read_warns_sectionr   #  s     E))aFaY`aE&+"		&3A&6&<&<S!&D#J ii!3!3!5 Jab8I JKRRSWX]jRS ', !'33  	!F}UVGWFXXYZ
 	r   )multiplec               t    U(       a  [        U 4SU0UD6$ [        U 4SU0UD6u  pEXTR                  5       4/U4$ r   )rX   r_   
splitlines)rN   rO   r   rP   	one_blockrQ   s         rW   _read_block_items_mayber   ?  sM      E6EWEE'	L&LGLI--/01:==rY   )namedr>   c                  U(       aT  [         R                  US   5      nU(       d!  U(       a  [        U USUS    S35        [        eUR	                  5       u  pgnOJS nSUS   ;   a8  US   R                  SS5      u  pxUR                  S5      R                  S5      nOS nUS   nSR                  UR                  5       /USS  Q5      R                  S5      nXgU4$ )	Nr   z4Failed to get name, annotation or description from 'rf   rd   rD   rg   rh   r[   )	r@   matchr%   rt   groupsrs   rK   r]   r\   )	rN   r|   rH   r   r>   r   ro   rq   rr   s	            rW    _get_name_annotation_descriptionr   L  s     /55eAh?!J5QR8*TUV
 (-%+%(?&+AhnnS!&<#J#**3/66s;JJ(K))[//1>E!"I>?FFtLK[((rY   F)r   indexc                  S n[        [        5         U R                  R                  nUR                  (       a  UR
                  R                  U   nO#UR                  (       a  US:X  a  UR
                  nU(       a*  UR                  (       a  UR
                  R                  U   nS S S 5        U$ ! , (       d  f       U$ = f)Nr   )	r   	Exceptionrx   rq   is_generatorsliceelementsis_iteratoris_tuple)rN   	gen_indexr   r   rq   s        rW   _annotation_from_parentr   k  s     J	)	%%00
""#))229=J##	Q#))J
++#))2259J 
  
	 s   BB22
C)returns_multiple_itemsreturns_named_valuera   r>   c          	        / n[        U 4UUS.UD6u  p[        U5       H  u  n
u  p [        U UUUS9u  pnU(       a  [	        X5      nOO[        U S[        U5      S:  U
S9nU(       a0  U(       a)  Uc&  U(       a  [        U5      OU
S-   n[        XSU 35        UR                  [        U=(       d    SXS95        M     [        U5      U	4$ ! [         a     M  f = f)	NrO   r   r   rF   rD   r   r   r   z)No type or annotation for returned value rE   r   )r   	enumerater   rt   r&   r   rI   reprr%   rL   r   r   )rN   rO   r   r   ra   r>   rP   r4   r^   rQ   r   r|   return_linesro   rq   rr   returned_values                    rW   _read_returns_sectionr   ~  s    G/' 	E /8.>**	,L)	-)Dk 3JJJ 1aRUV[R\_`R`hmnJ.:3E/3d!)<efteu:vwDJB:gh- /?0 #7+Z77!  		   C
CCc          	        / n[        U 4UUS.UD6u  p[        U5       H  u  n
u  p [        U UUUS9u  pnU(       a  [	        X5      nOO[        U S[        U5      S:  U
S9nU(       a0  U(       a)  Uc&  U(       a  [        U5      OU
S-   n[        XSU 35        UR                  [        U=(       d    SXS95        M     [        U5      U	4$ ! [         a     M  f = f)	Nr   r   r   rD   r   z(No type or annotation for yielded value rE   r   )r   r   r   rt   r&   r   rI   r   r%   rL   r$   r    )rN   rO   r   r   ra   r>   rP   r5   r^   rQ   r   r|   yield_linesro   rq   rr   yielded_values                    rW   _read_yields_sectionr     s    F/' 	E .7u-=))	,L)	-)Dk 3JJJ 1aRUV[R\_`R`hmnJ.:3E.2T
	!)<derds:tun$*"ef- .>0 "&):55!  		r   )receives_multiple_itemsreceives_named_valuera   r>   c          	        / n[        U 4UUS.UD6u  p[        U5       H  u  n
u  p [        U UUUS9u  pnU(       a  [	        X5      nO[        U S[        U5      S:  U
S9nU(       a0  U(       a)  Uc&  U(       a  [        U5      OU
S-   n[        XSU 35        UR                  [        U=(       d    SXS95        M     [        U5      U	4$ ! [         a     M  f = f)Nr   r   rD   r   z)No type or annotation for received value rE   r   )r   r   r   rt   r&   r   rI   r   r%   rL   r   r   )rN   rO   r   r   ra   r>   rP   r6   r^   rQ   r   r|   receive_linesro   rq   rr   received_values                    rW   _read_receives_sectionr     s    H/( 	E 09/?++	,L*	-)Dk 3JJJ 1aRUV[R\_`R`hmnJ*z/A+/T$ZUQYNi8abpaq6rs(djbZij- 0@0 $H-z99!  		r   )trim_doctest_flagsc                  [        U 4SU0UD6u  pE/ nSnSn/ n	/ n
UR                  S5       GH  n[        U5      (       aW  U(       a=  U
(       a2  UR                  [        R
                  SR                  U
5      45        / n
SnMX  U	R                  U5        Mk  U(       aF  U(       a,  [        R                  SU5      n[        R                  SU5      nU
R                  U5        M  UR                  S5      (       a  U(       + nU	R                  U5        M  U(       a  U	R                  U5        GM  UR                  S5      (       a{  U	(       aA  UR                  [        R                  SR                  U	5      R                  S5      45        / n	SnU(       a  [        R                  SU5      nU
R                  U5        GM  U	R                  U5        GM     U	(       a@  UR                  [        R                  SR                  U	5      R                  S5      45        O7U
(       a0  UR                  [        R
                  SR                  U
5      45        [        U5      U4$ )NrO   Fr[   rE   ```z>>>T)r_   rs   rJ   rL   r'   r7   r\   rB   subrA   rM   textr]   r   )rN   rO   r   rP   r   rQ   sub_sectionsin_code_examplein_code_blockcurrent_textcurrent_examplerU   s               rW   _read_examples_sectionr     s    #9GVGwGDhjLOM L!#O

4 $" '')=)F)F		RaHb(cd&(O"'##D)!(,,R6,00T:""4(__U## --M%%__U####%9%>%>		,@W@^@^_c@d$ef!"O!(,,R6""4( %E !H 166		,8O8V8VW[8\]^	1::DIIo<VWX#L1:==rY   c                ,    U R                  5       (       + $ )N)rv   )rU   s    rW   rJ   rJ   C  s    zz|rY   c                      \ rS rSr% SrS\S'    S\S'    S\S'    S\S'    S\S'    S\S	'    S\S
'    S\S'    S\S'    S\S'   Srg)GoogleOptionsiY  z,Options for parsing Google-style docstrings.boolignore_init_summaryr   r   r    returns_type_in_property_summaryr   r   r`   ra   r>    N)__name__
__module____qualname____firstlineno____doc____annotations____static_attributes__r   rY   rW   r   r   Y  s^    6JE  Mz&**[!!An3]N7rY   r   )total
r   r   r   r   r   r   r   r`   ra   r>   c       
           / n/ nSnU R                   nU(       a  [        S[        SS9  UUUUUUUUU	U
S.
nUS   =(       a    U R                  SL=(       a|    U R                  R                  S:H  =(       a\    U R                  R
                  =(       a?    U R                  R                  SL=(       a     U R                  R                  R                  nU(       a  SOS	nU[        U5      :  GaB  UU   R                  5       nU(       a=  UR                  S
5      R                  S5      (       a  SnUR                  UU   5        GOUR                  S
5      R                  S5      (       a  SnUR                  UU   5        GO[        R                  UU   5      =n(       Gac  UR                  5       nUS   nUS   nUR                  5       [        ;   nUS	:  nU(       + =(       d    [!        UUS-
     5      nU[        U5      S-
  :  nU[        U5      S-
  :  nU=(       a    [!        UUS-      5      nU=(       a    [!        UUS-      5      nU=(       a%    U(       + =(       a    UUS-      R                  S
5      nU=(       a%    U(       + =(       a    UUS-      R                  S
5      nU(       d#  U(       d  UR                  UU   5        US-  nGM  / n U(       a  SOSn!U(       d  U(       a  U(       d  U R                  SU! 35        U(       a  U(       a  U R                  SU! S35        U (       aV  U
(       a3  SR#                  U 5      n"[%        U USU! SU" 3[&        R(                  5        UR                  UU   5        US-  nGM  U(       a  U(       aJ  [+        U5      (       a8  UR                  [-        SR#                  U5      R/                  S5      5      5        / n[0        [        UR                  5             n#U#" U 4SUS-   0UD6u  n$nU$(       a  UU$l        UR                  U$5        O[5        U US-   S9u  n%nU%(       a  U(       aJ  [+        U5      (       a8  UR                  [-        SR#                  U5      R/                  S5      5      5        / nUc  UnUR                  5       R7                  S
S5      nUR                  [9        UU%US95        OA[;        [<        5         UR                  UU   5        SSS5        OUR                  UU   5        US-  nU[        U5      :  a  GMB  U(       aH  [+        U5      (       a8  UR                  [-        SR#                  U5      R/                  S5      5      5        U(       a  U(       a  U R                  (       a  U R                  R>                  (       a  SU R                  R@                  ;   a  US	   RB                  R                  5       RE                  S5      nSUS	   ;   ag  US	   RE                  SS5      u  n&n'U'/USS QnSR#                  U5      US	   l!        UR                  [G        [I        SS[K        U&U 5      S 9/5      5        U$ ! , (       d  f       GNg= f)!a  Parse a Google-style docstring.

This function iterates on lines of a docstring to build sections.
It then returns this list of sections.

Parameters:
    docstring: The docstring to parse.
    ignore_init_summary: Whether to ignore the summary in `__init__` methods' docstrings.
    trim_doctest_flags: Whether to remove doctest flags from Python example blocks.
    returns_multiple_items: Whether to parse multiple items in `Yields` and `Returns` sections.
        When true, each item's continuation lines must be indented.
        When false (single item), no further indentation is required.
    returns_named_value: Whether to parse `Yields` and `Returns` section items as name and description, rather than type and description.
        When true, type must be wrapped in parentheses: `(int): Description.`. Names are optional: `name (int): Description.`.
        When false, parentheses are optional but the items cannot be named: `int: Description`.
    receives_multiple_items: Whether to parse multiple items in `Receives` sections.
        When true, each item's continuation lines must be indented.
        When false (single item), no further indentation is required.
    receives_named_value: Whether to parse `Receives` section items as name and description, rather than type and description.
        When true, type must be wrapped in parentheses: `(int): Description.`. Names are optional: `name (int): Description.`.
        When false, parentheses are optional but the items cannot be named: `int: Description`.
    returns_type_in_property_summary: Whether to parse the return type of properties
        at the beginning of their summary: `str: Summary of the property`.
    warn_unknown_params: Warn about documented parameters not appearing in the signature.
    warn_missing_types: Warn about missing types/annotations for parameters, return values, etc.
    warnings: Whether to log warnings at all.
    **options: Swallowing keyword arguments for backward-compatibility.

Returns:
    A list of docstring sections.
FzDPassing additional options is deprecated, these options are ignored.rF   )
stacklevelr   r   N__init__r   rG   r   TtitletyperD   section
admonitionzMissing blank line above zExtraneous blank line below z titlez; z	Possible z skipped, reasons: r[   rO   )rO   -)r   r   r   propertyrd   rE   )rr   rq   )&rH   r   DeprecationWarningrx   ro   is_functionis_classrI   lowerrK   rM   rL   r?   r   	groupdict_section_kindrJ   r\   r%   r(   debuganyr   r]   _section_readerr   r_   replacer   r   
IndexErroris_attributelabelsrp   rs   r   r   r&   )(rN   r   r   r   r   r   r   r   r`   ra   r>   rP   sectionscurrent_sectionr   rH   ignore_summaryrO   
line_lowerr   r   r   admonition_type
is_sectionhas_previous_lineblank_line_abovehas_next_linehas_next_linesblank_line_belowblank_lines_belowindented_line_belowindented_lines_belowreasonsr   reasons_stringreaderr   contentsrq   rU   s(                                           rW   parse_googler  r  s   ^ (*HOMOOE SUgtuv  30"82,L#: 420G 	%& 	-D(	-!!Z/	- ((	- ##4/		-
 ##,,  !QaF
3u:
6]((*
  %0077 %""5=1s#..u55 M""5=1$**5=99U9__&F7OE$VnO(..0MAJ &
#44YuVVWZGX8Y"SZ!^3M#c%j1n4N,Rfqj@Q1R . T>%QR
BS3T"/"n8H4H"nUSY\]S]M^MiMijmMn#1#q:K6K#qPUV\_`V`PaPlPlmpPq '+?  &&uV}5!G *9D#';EU!:4&AB#(8!=dV6JK%)YYw%7N%!#D6)<^<LM 	  &&uV}5!"?++ (<TYY=W=^=^_c=d(ef&(O(7L7L7N)OP"("Q6A:"Q"Q$)GMOOG, $/y!#L &&//$OO,@?A[AbAbcgAh,ij*,} /&5&;&;&=&E&Ec3&OOOO$>OZbjo$pq!*-'..uV}= .- ""5=1!_ 3u:
b 3//,TYY-G-N-Nt-TUV 	))))**111!!((*006%(?$Qx~~c15J&E!"I&E $		% 0HQKOO'$RRD^_iktDuvw O9 .-s   'Y11
Z )
rN   r-   rO   intr>   r   rP   r*   return_ItemsBlock)rN   r-   rO   r  rP   r*   r  ztuple[str, int])rN   r-   rO   r  r`   r   ra   r   r>   r   rP   r*   r  z$tuple[list[DocstringParameter], int])rN   r-   rO   r  rP   r*   r  z-tuple[DocstringSectionParameters | None, int])
rN   r-   rO   r  r`   r   rP   r*   r  z2tuple[DocstringSectionOtherParameters | None, int])
rN   r-   rO   r  r`   r   rP   r*   r  z1tuple[DocstringSectionTypeParameters | None, int])
rN   r-   rO   r  r>   r   rP   r*   r  z-tuple[DocstringSectionAttributes | None, int])
rN   r-   rO   r  r>   r   rP   r*   r  z,tuple[DocstringSectionFunctions | None, int])
rN   r-   rO   r  r>   r   rP   r*   r  z*tuple[DocstringSectionClasses | None, int])rN   r-   rO   r  rP   r*   r  z.tuple[DocstringSectionTypeAliases | None, int])
rN   r-   rO   r  r>   r   rP   r*   r  z*tuple[DocstringSectionModules | None, int])
rN   r-   rO   r  r>   r   rP   r*   r  z)tuple[DocstringSectionRaises | None, int])
rN   r-   rO   r  r>   r   rP   r*   r  z(tuple[DocstringSectionWarns | None, int])
rN   r-   rO   r  r   r   rP   r*   r  r  )rN   r-   r|   r  rH   z	list[str]r   r   r>   r   r  ztuple[str | None, Any, str])
rN   r-   r   zLiteral[0, 1, 2]r   r   r   r  r  zstr | Expr | None)rN   r-   rO   r  r   r   r   r   ra   r   r>   r   rP   r*   r  z*tuple[DocstringSectionReturns | None, int])rN   r-   rO   r  r   r   r   r   ra   r   r>   r   rP   r*   r  z)tuple[DocstringSectionYields | None, int])rN   r-   rO   r  r   r   r   r   ra   r   r>   r   rP   r*   r  z+tuple[DocstringSectionReceives | None, int])
rN   r-   rO   r  r   r   rP   r*   r  z+tuple[DocstringSectionExamples | None, int])rU   strr  r   )rN   r-   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r`   r   ra   r   r>   r   rP   r*   r  zlist[DocstringSection])j
__future__r   re
contextlibr   typingr   r   r>   r   "griffe._internal.docstrings.modelsr   r	   r
   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r    r!   r"   r#   r$   !griffe._internal.docstrings.utilsr%   r&   griffe._internal.enumerationsr'   r(   r)   r*   r+   griffe._internal.expressionsr,   griffe._internal.modelsr-   r1   other_parametersr   r2   r4   r5   r6   r7   r8   r9   r;   r   r<   r=   r  tupler  listr   
_BlockItem_BlockItemsr  compile
IGNORECASEr?   r   r@   rA   rB   rX   r_   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   rJ   r  r   r  r   rY   rW   <module>r1     s   # 	  +        > \ H#11
 ++%00 "-- &11	
 (99 ->> &77 +<< (99 ,== %55 *:: '77 +;; "))  &--!" #++#$ #))$--$--&11%//#--#++(55#++!''$**9> 3S	>"
:K$%**%\^`^k^kl l+-::6v+w  w!#,B!C w CZZ(?@ 7 @ NR =!@9F !%#B"B" B" 	B"
 B" B" B" *B"J>> > 	>
 3> !%	CC C 	C
 C 8C !%	BGBG BG 	BG
 BG 7BGR 	'>'> '> 	'>
 '> 3'>\ 	"<"< "< 	"<
 "< 2"<R 	"8"8 "8 	"8
 "8 0"8JAA A 	A
 4A: 	88 8 	8
 8 08@ 	:: : 	:
 : /:F 	44 4 	4
 4 .4@ 	
>
> 
> 	
>
 
> 
>$ ))) )
 ) ) !)F    	
  . $( $#+8+8 +8 !	+8
 +8 +8 +8 +8 0+8d $( $#+6+6 +6 !	+6
 +6 +6 +6 +6 /+6d %)!%#+:+: +: "	+:
 +: +: +: +: 1+:d  $	8>8> 8> 	8>
 8> 18>v
 ##%=))+I((*G!5 3!!#9##%=""$;  "7%%'A  "7  "7!5!!#9$8IU 88 !&##' $-2$(!% $#ww w 	w
 !w w '+w "w w w w w w wrY   