+
    iJ#                        ^ RI t ^ RIt^ RIt]P                  '       d   ^ RIHt  ! R R] P                  4      t]P                  ]]P                  R.]
3,          3,          t ! R R]4      t]! 4       t ! R R	]4      t]! 4       t ! R
 R]4      t ! R R]4      t ! R R]4      t ! R R]4      t ! R R]4      t ! R R]4      t ! R R]4      t ! R R]4      t ! R R]4      t ! R R]4      t ! R R]4      tR# )     N)RetryCallStatec                      a  ] tR t^t o Rt]P                  V 3R lR l4       tV 3R lR ltV 3R lR lt	V 3R lR	 lt
V 3R
 lR ltRtV tR# )
retry_basez)Abstract base class for retry strategies.c                $   < V ^8  d   QhRRRS[ /#    retry_stater   returnbool)format__classdict__s   "a/Users/igloo/.openclaw/workspace/scratch/fb_ad_env/lib/python3.14/site-packages/tenacity/retry.py__annotate__retry_base.__annotate__   s      $4      c                    R # N selfr	   s   &&r   __call__retry_base.__call__   s    r   c                "   < V ^8  d   QhRRRR/# r   otherr   r
   	retry_allr   )r   r   s   "r   r   r       s     $ $\ $k $r   c                $    VP                  V 4      # r   )__rand__r   r   s   &&r   __and__retry_base.__and__    s    ~~d##r   c                "   < V ^8  d   QhRRRR/# r   r   )r   r   s   "r   r   r   #   s     & &l &{ &r   c                    \        W4      # r   )r   r    s   &&r   r   retry_base.__rand__#       %%r   c                "   < V ^8  d   QhRRRR/# r   r   r   r
   	retry_anyr   )r   r   s   "r   r   r   &   s     # #L #[ #r   c                $    VP                  V 4      # r   )__ror__r    s   &&r   __or__retry_base.__or__&   s    }}T""r   c                "   < V ^8  d   QhRRRR/# r(   r   )r   r   s   "r   r   r   )   s     & &\ &k &r   c                    \        W4      # r   )r)   r    s   &&r   r+   retry_base.__ror__)   r&   r   r   N)__name__
__module____qualname____firstlineno____doc__abcabstractmethodr   r!   r   r,   r+   __static_attributes____classdictcell__r   s   @r   r   r      sH     3 $ $& &# #& &r   r   r   c                   6   a  ] tR t^0t o RtV 3R lR ltRtV tR# )_retry_neverz-Retry strategy that never rejects any result.c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   _retry_never.__annotate__3   s      $4  r   c                    R # )Fr   r   s   &&r   r   _retry_never.__call__3   s    r   r   Nr1   r2   r3   r4   r5   r   r8   r9   r:   s   @r   r<   r<   0   s     7 r   r<   c                   6   a  ] tR t^:t o RtV 3R lR ltRtV tR# )_retry_alwaysz.Retry strategy that always rejects any result.c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   _retry_always.__annotate__=   s      $4  r   c                    R # )Tr   r   s   &&r   r   _retry_always.__call__=   s    r   r   NrA   r:   s   @r   rC   rC   :   s     8 r   rC   c                   H   a  ] tR t^Dt o RtV 3R lR ltV 3R lR ltRtV tR# )retry_if_exceptionzARetry strategy that retries if an exception verifies a predicate.c                P   < V ^8  d   QhRS[ P                  S[.S[3,          RR/# r   	predicater
   N)typingCallableBaseExceptionr   )r   r   s   "r   r   retry_if_exception.__annotate__G   s+     # #&//=/42G"H #T #r   c                    Wn         R # r   rL   r   rL   s   &&r   __init__retry_if_exception.__init__G       "r   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   rP   J   s     
 
$4 
 
r   c                    VP                   f   \        R4      hVP                   P                  '       d;   VP                   P                  4       pVf   \        R4      hV P	                  V4      # R# )N(__call__() called before outcome was set(outcome failed but the exception is NoneFoutcomeRuntimeErrorfailed	exceptionrL   r   r	   r_   s   && r   r   retry_if_exception.__call__J   sd    &IJJ%%%#++557I "#MNN>>),,r   rR   N	r1   r2   r3   r4   r5   rT   r   r8   r9   r:   s   @r   rI   rI   D   s     K# #
 
r   rI   c                   H   a a ] tR t^Wt oRt]3V3R lV 3R llltRtVtV ;t	# )retry_if_exception_typez=Retries if an exception has been raised of one or more types.c                   < V ^8  d   QhRS[ P                  S[ P                  S[,          S[ P                  S[ P                  S[,          R3,          3,          RR/# r   exception_types.r
   NrM   UnionTyperO   Tuple)r   r   s   "r   r   $retry_if_exception_type.__annotate__Z   sW     C CKK&LL]3S89;
C 
Cr   c                >   <a SV n         \        SV `	  V3R  l4       R# )c                    < \        V S4      # r   
isinstanceerg   s   &r   <lambda>2retry_if_exception_type.__init__.<locals>.<lambda>b   s    :a#Ar   Nrg   superrT   r   rg   	__class__s   &fr   rT    retry_if_exception_type.__init__Z   s      /ABr   rg   
r1   r2   r3   r4   r5   	ExceptionrT   r8   r9   __classcell__rx   r   s   @@r   rd   rd   W   s     G C C Cr   rd   c                   H   a a ] tR t^et oRt]3V3R lV 3R llltRtVtV ;t	# )retry_if_not_exception_typezARetries except an exception has been raised of one or more types.c                   < V ^8  d   QhRS[ P                  S[ P                  S[,          S[ P                  S[ P                  S[,          R3,          3,          RR/# rf   rh   )r   r   s   "r   r   (retry_if_not_exception_type.__annotate__h   W     G GKK&LL]3S89;
G 
Gr   c                >   <a SV n         \        SV `	  V3R  l4       R# )c                 &   < \        V S4      '       * # r   ro   rq   s   &r   rs   6retry_if_not_exception_type.__init__.<locals>.<lambda>p       z!_'E#Er   Nru   rw   s   &fr   rT   $retry_if_not_exception_type.__init__h         /EFr   rz   r{   r~   s   @@r   r   r   e   s     K G G Gr   r   c                   Z   a a ] tR t^st oRt]3V3R lV 3R llltV3R lR ltRtVt	V ;t
# )retry_unless_exception_typez:Retries until an exception is raised of one or more types.c                   < V ^8  d   QhRS[ P                  S[ P                  S[,          S[ P                  S[ P                  S[,          R3,          3,          RR/# rf   rh   )r   r   s   "r   r   (retry_unless_exception_type.__annotate__v   r   r   c                >   <a SV n         \        SV `	  V3R  l4       R# )c                 &   < \        V S4      '       * # r   ro   rq   s   &r   rs   6retry_unless_exception_type.__init__.<locals>.<lambda>~   r   r   Nru   rw   s   &fr   rT   $retry_unless_exception_type.__init__v   r   r   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   r      s     ) )$4 ) )r   c                    VP                   f   \        R4      hVP                   P                  '       g   R# VP                   P                  4       pVf   \        R4      hV P	                  V4      # NrY   TrZ   r[   r`   s   && r   r   $retry_unless_exception_type.__call__   sf    &IJJ "")))''113	IJJ~~i((r   rz   )r1   r2   r3   r4   r5   r|   rT   r   r8   r9   r}   r~   s   @@r   r   r   s   s(     D G G) ) )r   r   c                   N   a  ] tR t^t o Rt]3V 3R lR lltV 3R lR ltRtV t	R# )retry_if_exception_cause_typezRetries if any of the causes of the raised exception is of one or more types.

The check on the type of the cause of the exception is done recursively (until finding
an exception in the chain that has no `__cause__`)
c                   < V ^8  d   QhRS[ P                  S[ P                  S[,          S[ P                  S[ P                  S[,          R3,          3,          RR/# rf   rh   )r   r   s   "r   r   *retry_if_exception_cause_type.__annotate__   sS     5 5KK&LL]3S89;
5 
5r   c                    Wn         R # r   exception_cause_types)r   rg   s   &&r   rT   &retry_if_exception_cause_type.__init__   s
     &5"r   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   r      s      $4  r   c                   VP                   f   \        R4      hVP                   P                  '       dU   VP                   P                  4       pVe7   \	        VP
                  V P                  4      '       d   R# VP
                  pK:  R# )Nz&__call__ called before outcome was setTF)r\   r]   r^   r_   rp   	__cause__r   )r   r	   excs   && r   r   &retry_if_exception_cause_type.__call__   sk    &GHH%%%%%//1C/cmmT-G-GHHmmr   r   N)
r1   r2   r3   r4   r5   r|   rT   r   r8   r9   r:   s   @r   r   r      s#      5 5 r   r   c                   H   a  ] tR t^t o RtV 3R lR ltV 3R lR ltRtV tR# )retry_if_resultz+Retries if the result verifies a predicate.c                d   < V ^8  d   QhRS[ P                  S[ P                  .S[3,          RR/# rK   rM   rN   Anyr   )r   r   s   "r   r   retry_if_result.__annotate__   /     # #&//6::,2D"E #$ #r   c                    Wn         R # r   rR   rS   s   &&r   rT   retry_if_result.__init__   rV   r   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   r            $4  r   c                    VP                   f   \        R4      hVP                   P                  '       g*   V P                  VP                   P	                  4       4      # R# NrY   Fr\   r]   r^   rL   resultr   s   &&r   r   retry_if_result.__call__   sM    &IJJ"")))>>+"5"5"<"<">??r   rR   Nrb   r:   s   @r   r   r      s     5# # r   r   c                   H   a  ] tR t^t o RtV 3R lR ltV 3R lR ltRtV tR# )retry_if_not_resultz*Retries if the result refutes a predicate.c                d   < V ^8  d   QhRS[ P                  S[ P                  .S[3,          RR/# rK   r   )r   r   s   "r   r    retry_if_not_result.__annotate__   r   r   c                    Wn         R # r   rR   rS   s   &&r   rT   retry_if_not_result.__init__   rV   r   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   r      r   r   c                    VP                   f   \        R4      hVP                   P                  '       g/   V P                  VP                   P	                  4       4      '       * # R# r   r   r   s   &&r   r   retry_if_not_result.__call__   sP    &IJJ"")))~~k&9&9&@&@&BCCCr   rR   Nrb   r:   s   @r   r   r      s     4# # r   r   c                   F   a a ] tR t^t oRtRV3R lV 3R llltRtVtV ;t# )retry_if_exception_messagez2Retries if an exception message equals or matches.c                   < V ^8  d   QhRS[ P                  S[,          RS[ P                  RS[S[ P                  S[,          3,          RR/# r   messagematchNr
   rM   Optionalstrri   Pattern)r   r   s   "r   r   'retry_if_exception_message.__annotate__   sK     $ $%$ ||D#v~~c'::;$ 
	$r   c                N  <aa S'       d+   V'       d#   \        V P                  P                   R 24      hS'       d   R V3R llpTpMLV'       d#   \        P                  ! V4      oR V3R llpTpM"\        V P                  P                   R24      h\
        SV `  V4       R# )z.() takes either 'message' or 'match', not bothc                0    V ^8  d   QhR\         R\        /# r   r_   r
   rO   r   )r   s   "r   r   9retry_if_exception_message.__init__.<locals>.__annotate__   s     1 1} 1 1r   c                     < S\        V 4      8H  # r   )r   )r_   r   s   &r   message_fnc8retry_if_exception_message.__init__.<locals>.message_fnc   s    #i.00r   c                0    V ^8  d   QhR\         R\        /# r   r   )r   s   "r   r   r      s     8 8] 8t 8r   c                 J   < \        SP                  \        V 4      4      4      # r   )r   r   r   )r_   progs   &r   	match_fnc6retry_if_exception_message.__init__.<locals>.match_fnc   s    DJJs9~677r   z3() missing 1 required argument 'message' or 'match'N)	TypeErrorrx   r1   recompilerv   rT   )r   r   r   r   rL   r   r   rx   s   &f&   @r   rT   #retry_if_exception_message.__init__   s    
 u>>**++YZ 
 1 1 $I::e$D8 8 "I>>**++^_  	#r   r   NN)	r1   r2   r3   r4   r5   rT   r8   r9   r}   r~   s   @@r   r   r      s     <$ $ $r   r   c                   X   a a ] tR t^t oRtRV3R lV 3R llltV3R lR ltRtVtV ;t	# )retry_if_not_exception_messagez5Retries until an exception message equals or matches.c                   < V ^8  d   QhRS[ P                  S[,          RS[ P                  RS[S[ P                  S[,          3,          RR/# r   r   )r   r   s   "r   r   +retry_if_not_exception_message.__annotate__   sP     W W%W ||D#v~~c'::;W 
	Wr   c                V   <a \         SV `  W4       V P                  oV3R  lV n        R# )c                     < S! V / VB '       * # r   r   )args_kwargs_if_predicates   *,r   rs   9retry_if_not_exception_message.__init__.<locals>.<lambda>   s    |U7Vg7V3Vr   N)rv   rT   rL   )r   r   r   r   rx   s   &&&@r   rT   'retry_if_not_exception_message.__init__   s"    
 	(~~Vr   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   r      s     
) 
)$4 
) 
)r   c                    VP                   f   \        R4      hVP                   P                  '       g   R# VP                   P                  4       pVf   \        R4      hV P	                  V4      # r   r[   r`   s   && r   r   'retry_if_not_exception_message.__call__   sd    &IJJ"")))''113	IJJ~~i((r   rR   r   )
r1   r2   r3   r4   r5   rT   r   r8   r9   r}   r~   s   @@r   r   r      s#     ?W W
) 
) 
)r   r   c                   H   a  ] tR tRt o RtV 3R lR ltV 3R lR ltRtV tR# )	r)   i	  z1Retries if any of the retries condition is valid.c                $   < V ^8  d   QhRS[ RR/# r   retriesr
   Nr   )r   r   s   "r   r   retry_any.__annotate__          r   c                    Wn         R # r   r   r   r   s   &*r   rT   retry_any.__init__      r   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   r          9 9$4 9 9r   c                   a \         ;QJ d)    V3R  lV P                   4       F  '       g   K   R# 	  R# ! V3R  lV P                   4       4      # )c              3   2   <"   T F  q! S4      x  K  	  R # 5ir   r   .0rr	   s   & r   	<genexpr>%retry_any.__call__.<locals>.<genexpr>       8<a1[>><   TF)anyr   r   s   &fr   r   retry_any.__call__  4    s84<<8ss8s8s84<<888r   r   Nrb   r:   s   @r   r)   r)   	  s     ; 9 9r   r)   c                   H   a  ] tR tRt o RtV 3R lR ltV 3R lR ltRtV tR# )	r   i  z/Retries if all the retries condition are valid.c                $   < V ^8  d   QhRS[ RR/# r   r   )r   r   s   "r   r   retry_all.__annotate__  r   r   c                    Wn         R # r   r   r   s   &*r   rT   retry_all.__init__  r   r   c                $   < V ^8  d   QhRRRS[ /# r   r   )r   r   s   "r   r   r    r   r   c                   a \         ;QJ d)    V3R  lV P                   4       F  '       d   K   R# 	  R# ! V3R  lV P                   4       4      # )c              3   2   <"   T F  q! S4      x  K  	  R # 5ir   r   r   s   & r   r   %retry_all.__call__.<locals>.<genexpr>  r   r   FT)allr   r   s   &fr   r   retry_all.__call__  r   r   r   Nrb   r:   s   @r   r   r     s     9 9 9r   r   )r6   r   rM   TYPE_CHECKINGtenacityr   ABCr   ri   rN   r   
RetryBaseTr<   retry_neverrC   retry_alwaysrI   rd   r   r   r   r   r   r   r   r)   r   r   r   r   <module>r     s  "  	 	'& &( \\*foo7G6H$6N&OOP
:  nJ   &C0 CG"4 G)"4 )6J <j  *   $!3  $F)%? )49
 99
 9r   