+
    P\iF&  c                  s  a  0 t $ ^ RIHt R#t^ RIt^ RIt^ RIt^ RIt^ RIH	t	 ^ RI
Ht ^ RIHtHt ^ RIHtHt ^RIHtHtHt ^RIHt ^R	IHt ^R
IHt ^RIHtHt ^RIH t H!t!H"t" ^RI#H$t$H%t% ^RI&H't' ]PP                  R$8  d
   ^ RIH)t)H*t* M^ RI+H)t)H*t* Rt,]! R4      t-])! R4      t.]$! R4      t/R]0R&   ]$! R4      t1R]0R&   ]$! R4      t2R]0R&   RRRR/R R llt3R R lt4R  R! lt5]6R"8X  d
   ]5! 4        R# R# )%i    )annotationsN)deque)Callable)module_from_specspec_from_file_location)TypeVarcast)current_timeget_async_backendget_cancelled_exc_class)BrokenWorkerProcess)open_process)CapacityLimiter)CancelScope
fail_after)ByteReceiveStreamByteSendStreamProcess)RunVarcheckpoint_if_cancelled)BufferedByteReceiveStream)TypeVarTupleUnpacki,  T_RetvalPosArgsT_process_pool_workerszRunVar[set[Process]]_process_pool_idle_workersz$RunVar[deque[tuple[Process, float]]]_default_process_limiterzRunVar[CapacityLimiter]cancellableFlimiterc          
     s,    V ^8  d   QhRRRRRRRRR	R
/# )   funcz&Callable[[Unpack[PosArgsT]], T_Retval]argszUnpack[PosArgsT]r   Zboolr   zCapacityLimiter | Nonereturnr    Zformat   "5/usr/lib/python3.14/site-packages/anyio/to_process.py__annotate__r&   ,   sH     OC OC
0OCOC OC $	OC
 OC    c               s	  aaaa"   R VVVV3R llp\        4       G Rj  xL
  \        P                  ! RW3\        P                  R7      p \        P                  4       o\        P                  4       pT;'       g    \        4       ;_uu_4       GRj  xL
  V'       Ed-   VP                  4       w  opSP                  f   \        \         SP"                  4      o\%        \        \&        SP(                  4      4      o\+        4       p. p	V'       dg   W^ ,          ^,          ,
          \,        8  d   MFVP/                  4       w  rV
P1                  4        SP3                  V
4       V	P5                  V
4       Kn  \7        RR7      ;_uu_ 4        V	 F  pVP9                  4       G Rj  xL
  K  	  RRR4       EMaSP3                  S4       EK5  \:        P<                  RR	\>        .p\A        V\B        PD                  \B        PD                  R
7      G Rj  xL
 o \        \         SP"                  4      o\%        \        \&        SP(                  4      4      o\G        ^4      ;_uu_ 4        SPI                  ^4      G Rj  xL
 pRRR4       XR8w  d   \K        RV: 24      h\M        \:        PN                  R,          RR4      p\        P                  ! R\:        PP                  V3\        P                  R7      pV! V4      G Rj  xL
  SPW                  S4       \7        V'       * R7      ;_uu_ 4         \        \X        V! V4      G Rj  xL
 4      SS9   d   VP5                  S\+        4       34       uuRRR4       uuRRR4      GRj  xL
  #  ELt  \         d\    \        4       o\        4       p\        P                  S4       \        P                  T4       \        4       P                  S4        ELi ; i ELj ELZ  + '       g   i     EL]; i EL EL  + '       g   i     EL; i EL-  \J        \S        4       3 d    h \T         d"   pSP1                  4        \K        R4      ThRp?ii ; i EL. L  SS9   d   TP5                  S\+        4       34       i i ; i  + '       g   i     M; iRRR4      GRj  xL 
  R#   + GRj  xL 
 '       g   i     R# ; i5i)a  
Call the given function with the given arguments in a worker process.

If the ``cancellable`` option is enabled and the task waiting for its completion is
cancelled, the worker process running it will be abruptly terminated using SIGKILL
(or ``terminateProcess()`` on Windows).

:param func: a callable
:param args: positional arguments for the callable
:param cancellable: ``True`` to allow cancellation of the operation while it's
    running
:param limiter: capacity limiter to use to limit the total amount of processes
    running (if omitted, the default limiter is used)
:raises NoEventLoopError: if no supported asynchronous event loop is running in the
    current thread
:return: an awaitable that yields the return value of the function.

c               s     V ^8  d   QhRRRR/# )r   pickled_cmdZbytesr!   Zobjectr"   r#   r$   r%   r&   Zrun_sync.<locals>.__annotate__E   s      E f r'   c                s  <"    S	P                  V 4      G R j  xL
  SP                  R^24      G R j  xL
 pVP                  R4      w  r#VR9  d   \        RV: 24      hSP	                  \        V4      4      G R j  xL
 p\        P                   ! T4      pTR8X  d   \        T\        4      '       g   Q hThT#  L L LA  \         d   pS
P                  S4        SP                  4        \        RR7      ;_uu_ 4        SP                  4       G R j  xL 
  R R R 4       M$  + '       g   i     M; i  \         d     Mi ; i\        T\        4       4      '       d   h \        ThR p?ii ; i5i)Ns   
    	   EXCEPTION-Worker process returned unexpected response: TZshield)   RETURNr*   )ZsendZreceive_untilZsplitZRuntimeErrorZreceive_exactlyZintBaseExceptionZdiscardkillr   acloseZProcessLookupError
isinstancer	   r
   pickleZloads)r(   ZresponsestatusZlengthZpickled_responseexcretvalbufferedprocessstdinworkerss   &      r%   send_raw_commandZ"run_sync.<locals>.send_raw_commandE   sB    	3**[)))%33E2>>H%^^D1NF66"CH<P  &.%=%=c&k%JJ ./\!fm4444LM9 *>  K 	3OOG$ --!..*** .---%  #6899)s2	3s   E4C B<C B>A
C >C ?C 9E4<C >C  C E1E,$D9D&D
D&D9%E,&D61D95E,6D99EE,E%E,,E11E4Nrun)ZprotocolTr,   z-uz-m)r8   stdout   READY
r+   __main__Z__file__initz*Error during worker process initialization)-r   r2   dumpsHIGHEST_PROTOCOLr   getr   LookupErrorsetr   r   Z#setup_process_pool_exit_at_shutdowncurrent_default_process_limiterZpopZ
returncoder   r   r8   r   r   r<   r   WORKER_MAX_IDLE_TIMEZpopleftr/   ZremoveZappendr   r0   sysZ
executable__name__r   
subprocessZPIPEr   Zreceiver
   Zgetattrmodulespathr	   r.   Zaddr   )r   r   r   r    r:   ZrequestZidle_workersZ
idle_sinceZnowZkilled_processesZprocess_to_killZkilled_processcommandZmessagemain_module_pathpickledr4   r6   r7   r8   r9   s   &$$*             @@@@r%   run_syncrO   ,   s    2 B "
###llE4.9P9PQGI'++-1557 ;;9;;;; l"."2"2"4GZ!!)^W]];4*GNN; #n24 "!_Q//2FF2>2F2F2H/O#((*NN?3$++O< --*:,33555 +; . NN7#~~tT8<G(zz G^W]];4*GNN;  ^^$,$4$4Q$77G $ j(-G{S  $+3;;z+BJPT#U  ,,SXX'78#44 'w/// KK K00CH,<W,E&EFg% '',.(AB 10E <;; $  I%w!!'*"&&|4??HI <6 6 .-- 8 $^^ 0')@)BC   )@ 'FI <L g% '',.(AB &	 10E <;;;;;s}  S+N,S+(N 6S+?S+P S+	S$A1SA:SP	)P*P	2A#SPSAP7+P 	 PP 	BP7P4P7*S6R(	8R Q;R "R(	7
SS+Q>S+A"O=9S+<O==S+P	P
SP 	 P1+
P77Q8Q8Q33Q88S;R >S+ %R%%R(	(R83S;S+S	S+S(	S
S(	 S(	"	S+c                   V ^8  d   QhRR/# )r   r!   r   r"   r#   r$   r%   r&   r&      s       r'   c                 s     \         P                  4       #   \         dC    \        \        P
                  ! 4       ;'       g    ^4      p \         P                  T 4       T u # i ; i)z
Return the capacity limiter that is used by default to limit the number of worker
processes.

:return: a capacity limiter object

)r   rB   rC   r   osZ	cpu_countrD   )r   r)   r%   rE   rE      sP    '++-- !",,."5"5A6 $$W-s    +A#A#"A#c               rP   )r   r!   ZNoner"   r#   r$   r%   r&   r&      s     8 8 8r'   c                 s   \         P                  p \         P                  p\        \        P
                  4      \         n        \        \        P
                  R 4      \         n        VP                  P                  R4        R;r# \        P                  ! V P                  4      vrEVR8X  d   Vw  re V! V!  pMVR8X  d   Vw  \         n        p\         P                  R V'       d   \        P                  P                  V4      '       da    \        RV4      p	V	'       dL   V	P                  '       d:   \!        V	4      p
V	P                  P#                  V
4       V
\         P                  R&    Ve)   Rp\        P&                  ! V\        P(                  4      pM(Rp\        P&                  ! V\        P(                  4      p VP                  P                  R	V\+        V4      3,          4       VP                  P                  V4       \-        V\.        4      '       g   EK  Vh  \         d   pTp Rp?LRp?ii ; i  \         d   pTp Rp?LRp?ii ; i  \$         d     R# \         d   pTp Rp?ELRp?ii ; i  \         d4   pTpRp\        P&                  ! T\        P(                  4      p Rp?LRp?ii ; i)
Zwr=   Nr;   r?   r>   Z__mp_main__r*   r-   s   %s %d
)rG   r8   r<   ZopenrQ   ZdevnullZbufferZwriter2   Zloadr.   rK   rJ   Zisfiler   Zloaderr   Zexec_moduleZEOFErrorr@   rA   Zlenr1   Z
SystemExit)r8   r<   r5   Z	exceptionrL   r    r   r4   rM   ZspecZmainr3   rN   s                r%   process_workerrR      s    IIEZZFRZZ CIbjj#&CJ
MM
#
!!	(#[[6NG %!
$!4[F F"-1**KK
+#7G(H(H(6}FVWDKKK#3D#9D KK33D96:CKK
3
	A$% ,,y&2I2IJ" ,,vv/F/FG 	J&#g,)??@G$ i,,OE % $ #I$ ) ($'	(1  	 	I	>  	AI!Fll3(?(?@G	Asx   !I 3H% %H? 49H? .+J 'J %H<0H77H<?I
III>'I>0I>1I99I>J?)J::J?r>   )rE   rR   rO   )i   i   )7__conditional_annotations__Z
__future__r    Z__all__rQ   r2   rI   rG   Zcollectionsr   Zcollections.abcr   Zimportlib.utilr   r   Ztypingr   r   Z_core._eventloopr   r   r	   Z_core._exceptionsr
   Z_core._subprocessesr   Z_core._synchronizationr   Z_core._tasksr   r   Zabcr   r   r   Zlowlevelr   r   Zstreams.bufferedr   Zversion_infor   r   Ztyping_extensionsrF   r   r   r   Z__annotations__r   r   rO   rE   rR   rH   )rS   s   @r%   <module>rT      s    " " 
   
  $ D   V V 2 - 3 1 ; ; 5 7w++6 :
#.45L.M + MCI D @  5;;U4V 1 VOC OC '+	OCd 8v z r'   