+
    i9  c                   s>   Rt ^ RIt^RIHt ^RIHt ^RIHt ^RIHt ^RIHt ]P                  t	]P                  t
]P                  t ! R R]P                  ]P                  4      t ! R	 R
4      tRRR]P                   3R ltRRRRRRR]P                   /R ltR# )create_subprocess_execN)events)	protocols)streams)tasks)loggerc                   s`   a a ] tR t^t oRtV 3R ltR tR tR tR t	R t
R tR	 tR
tVtV ;t# )SubprocessStreamProtocolz0Like StreamReaderProtocol, but for a subprocess.c                s   < \         SV `  VR 7       Wn        R;V n        ;V n        V n        RV n        RV n        . V n        V P                  P                  4       V n        R# ))loopNF)Zsuper__init___limitstdinstdoutstderr
_transport_process_exited	_pipe_fds_loopZcreate_future_stdin_closed)selflimitr   	__class__s   &&&+/usr/lib64/python3.14/asyncio/subprocess.pyr   Z!SubprocessStreamProtocol.__init__   sX    d#155
5T[4;$!ZZ557    c                s~   V P                   P                  .pV P                  e    VP                  RV P                  : 24       V P                  e    VP                  RV P                  : 24       V P
                  e    VP                  RV P
                  : 24       RP                  RP                  V4      4      # )Nzstdin=zstdout=zstderr=z<{}> )r   __name__r
   appendr   r   ZformatZjoin)r   Zinfos   & r   __repr__Z!SubprocessStreamProtocol.__repr__   s    ''(::!KK&/0;;"KK'$++12;;"KK'$++12}}SXXd^,,r   c                s   Wn         VP                  ^4      pVeh   \        P                  ! V P                  V P
                  R7      V n        V P                  P                  V4       V P                  P                  ^4       VP                  ^4      pVeh   \        P                  ! V P                  V P
                  R7      V n
        V P                  P                  V4       V P                  P                  ^4       VP                  ^ 4      pVe,   \        P                  ! VV RV P
                  R7      V n        R# R# )   Nr   r   )protocolreaderr   )r   get_pipe_transportr   ZStreamReaderr	   r   r   Zset_transportr   r   r   ZStreamWriterr
   )r   	transportZstdout_transportZstderr_transportZstdin_transport   &&   r   connection_madeZ(SubprocessStreamProtocol.connection_made(   s    #$77:'!..T[[48JJ@DKKK%%&67NN!!!$$77:'!..T[[48JJ@DKKK%%&67NN!!!$#66q9& --o7;5937::?DJ 'r   c                s    V^8X  d   V P                   pMV^8X  d   V P                  pMRpVe   VP                  V4       R# R# )r   N)r   r   Z	feed_data)r   fdZdatar   s   &&& r   pipe_data_receivedZ+SubprocessStreamProtocol.pipe_data_received@   s@    7[[F1W[[FFT" r   c                s2   V^ 8X  d   V P                   pVe   VP                  4        V P                  V4       Vf   V P                  P	                  R4       R# V P                  P                  V4       RV P                  n        R# V^8X  d   V P                  pMV^8X  d   V P                  pMRpVe'   Vf   VP                  4        MVP                  V4       WP                  9   d   V P                  P                  V4       V P                  4        R# )    NF)r
   closeZconnection_lostr   Z
set_resultZset_exceptionZ_log_tracebackr   r   Zfeed_eofr   Zremove_maybe_close_transport)r   r#   excZpiper   s   &&&  r   pipe_connection_lostZ-SubprocessStreamProtocol.pipe_connection_lostJ   s    7::D

  %{""--d3 	 ""005 5:""17[[F1W[[FF{!$$S)NN!!"%##%r   c                s4    R V n         V P                  4        R# )TN)r   r'   r      &r   process_exitedZ'SubprocessStreamProtocol.process_exitedh   s    ###%r   c                s    \        V P                  4      ^ 8X  d8   V P                  '       d$   V P                  P	                  4        RV n        R# R# R# )r%   N)lenr   r   r   r&   r*   r+   r   r'   Z/SubprocessStreamProtocol._maybe_close_transportl   s=    t~~!#(<(<(<OO!!#"DO )=#r   c                s<    WP                   J d   V P                  # R # N)r
   r   )r   stream   &&r   _get_close_waiterZ*SubprocessStreamProtocol._get_close_waiterq   s    ZZ%%%  r   )r	   r   r   r   r   r   r
   r   )r   
__module____qualname____firstlineno__Z__doc__r   r   r"   r$   r)   r,   r'   r1   __static_attributes____classdictcell__Z__classcell__)r   __classdict__s   @@r   r   r      s5     :8-?0#&<&#
& &r   r   c                   sp   a  ] tR t^vt o R tR t]R 4       tR tR t	R t
R tR tR	 tR
 tRR ltRtV tR# )Processc                s    Wn         W n        W0n        VP                  V n        VP                  V n        VP
                  V n        VP                  4       V n        R # r.   )r   	_protocolr   r
   r   r   Zget_pidpid)r   r    r   r   s   &&&&r   r   ZProcess.__init__w   sB    #!
^^
oooo$$&r   c                sP    R V P                   P                   RV P                   R2# )Z<r   Z>)r   r   r:   r*   r+   r   r   ZProcess.__repr__   s&    4>>**+1TXXJa88r   c                s6    V P                   P                  4       # r.   )r   Zget_returncoder*   r+   r   
returncodeZProcess.returncode   s    --//r   c                sR   "   V P                   P                  4       G Rj  xL
 #  L5i)z?Wait until the process exit and return the process return code.N)r   Z_waitr*   r+   r   waitZProcess.wait   s     __**,,,,s   '%'c                s<    V P                   P                  V4       R # r.   )r   send_signal)r   Zsignalr0   r   r=   ZProcess.send_signal   s    ##F+r   c                :    V P                   P                  4        R # r.   )r   	terminater*   r+   r   r?   ZProcess.terminate   s    !!#r   c                r>   r.   )r   killr*   r+   r   r@   ZProcess.kill   s    r   c                s  "   V P                   P                  4       p VeE   V P                  P                  V4       V'       d"   \        P
                  ! RV \        V4      4       V P                  P                  4       G R j  xL
  V'       d   \        P
                  ! RV 4       V P                  P                  4        R #  L?  \        \        3 d*   pT'       d   \        P
                  ! RY4        R p?LrR p?ii ; i5i)Nz%%r communicate: feed stdin (%s bytes)z%r communicate: stdin got %rz%r communicate: close stdin)r   	get_debugr
   Zwriter   debugr-   ZdrainZBrokenPipeErrorZConnectionResetErrorr&   )r   inputrB   r(   s   &&  r   _feed_stdinZProcess._feed_stdin   s     

$$&	H 

  'LL?s5zS **""$$$ LL6=

 %!56 	H ;TG		HsL   D&C >C CC D3DC C?C:5D:C??Dc                s   "   R # 5ir.    r*   r+   r   _noopZProcess._noop   s     s   c                s  "   V P                   P                  V4      pV^8X  d   V P                  pMV P                  pV P                  P                  4       '       d#   V^8X  d   RMRp\        P                  ! RW4       VP                  4       G Rj  xL
 pV P                  P                  4       '       d#   V^8X  d   RMRp\        P                  ! RW4       VP                  4        V#  LX5i)i   r   r   z%r communicate: read %sNz%r communicate: close %s)
r   r   r   r   r   rA   r   rB   Zreadr&   )r   r#   r    r/   ZnameZoutputs   &&    r   _read_streamZProcess._read_stream   s     OO66r:	7[[F [[F::!!!Qw8HDLL2D?{{}$::!!!Qw8HDLL3T@ %s   AC.5C.C,#C.85C.Nc                s  "   V P                   e   V P                  V4      pMV P                  4       pV P                  e   V P	                  ^4      pMV P                  4       pV P
                  e   V P	                  ^4      pMV P                  4       p\        P                  ! W#V4      G R j  xL
 w  r#pV P                  4       G R j  xL
  W43#  L" L	5ir.   )	r
   rD   rF   r   rG   r   r   Zgatherr<   )r   rC   r
   r   r   r!   r   communicateZProcess.communicate   s     ::!$$U+EJJLE;;"&&q)FZZ\F;;"&&q)FZZ\F&+ll5&&I Iviik !Js$   B+C-C.CC	CC)r   r9   r   r:   r   r
   r   r.   )r   r2   r3   r4   r   r   Zpropertyr;   r<   r=   r?   r@   rD   rF   rG   rH   r5   r6   )r7   s   @r   r8   r8   v   sP     '9 0 0-,$("   r   r8   c           	      s   aa	"   \         P                  ! 4       o	VV	3R  lpS	P                  ! VV 3RVRVRV/VB G Rj  xL
 w  rx\        WxS	4      #  L5i)c                     < \        S SR 7      # r   r   r      r   <lambda>Z)create_subprocess_shell.<locals>.<lambda>       7e=A Cr   r
   r   r   N)r   get_running_loopZsubprocess_shellr8   )
Zcmdr
   r   r   r   kwdsprotocol_factoryr    r   r   s
   &&&&f,   @r   create_subprocess_shellrR      ss     ""$DC $ 5 5!!!'! ! ! I 9--	s   :AAAr
   r   r   r   c          	      s   aa
"   \         P                  ! 4       o
VV
3R  lpS
P                  ! VV .VO5RVRVRV/VB G Rj  xL
 w  r\        WS
4      #  L5i)c                  rI   rJ   rK   r   rL   r   rM   Z(create_subprocess_exec.<locals>.<lambda>   rN   r   r
   r   r   N)r   rO   Zsubprocess_execr8   )Zprogramr
   r   r   r   ZargsrP   rQ   r    r   r   s   &$$$d*,   @r   r    r       s      ""$DC $ 4 4!! ! #! 	! 	! I
 9--s   =AAA)r    rR   )Z__all__Z
subprocessZ r   r   r   r   Zlogr   ZPIPEZSTDOUTZDEVNULLZFlowControlMixinZSubprocessProtocolr   r8   Z_DEFAULT_LIMITrR   r    rE   r   r   <module>rS      s   
=       			


b&w77(;;b&JU  U p .2$t(/(>(>	..t .D .(,.4;4J4J.r   