+
    '(j5                        ^ RI H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 ^ RIHt ^ RIHtHtHtHt ^ RIHt ^ R	IHt R
 R ltR R ltR R ltR R ltR R ltR R ltR R ltRR R lltR# )    )annotationsN)Literal)CurlHttpVersion)Response)Console)Progress	BarColumnDownloadColumnTransferSpeedColumn)Syntax)Textc                    V ^8  d   QhRRRR/# )   responser   returnzLiteral['1.0', '1.1', '2', '3'] )formats   "I/home/ubuntu/cf-venv/lib/python3.14/site-packages/curl_cffi/cli/output.py__annotate__r      s     
5 
5h 
5+J 
5    c                   \         P                  R \         P                  R\         P                  R\         P                  R\         P
                  R\         P                  R\         P                  R/pVP                  V P                  R4      # )z1.0z1.123)
r   V1_0V1_1V2_0V2TLSV2_PRIOR_KNOWLEDGEV3V3ONLYgethttp_version)r   mappings   & r   _http_ver_labelr$      so    eecs**CCG ;;x,,e44r   c                    V ^8  d   QhRRRR/# )r   argszargparse.Namespacer   strr   )r   s   "r   r   r      s      1 c r   c                .   V P                   '       d   V P                   # V P                  '       d   R # V P                  '       d   R# V P                  '       d   R# V P                  '       d   R# \
        P                  P                  4       '       d   R# R# )HhBbhbhb)
print_specverboseheaders_only	body_onlydownloadsysstdoutisatty)r&   s   &r   determine_print_specr5      sa    |||~~~}}}
zzr   c               (    V ^8  d   QhRRRRRRRR/# )	r   consoler   linesz	list[str]	use_colorboolr   Noner   )r   s   "r   r   r   /   s(     : :G :I :$ :4 :r   c                j   V'       g   V F  p\        V4       K  	  R# V F  pRV9   di   VP                  R4      w  rEp\        4       pVP                  VRR7       VP                  RRR7       VP                  V4       V P                  V4       Kr  V P                  \        VRR7      4       K  	  R# )z3Print HTTP headers, with rich colors when possible.N: z	bold cyanstyledim
bold green)print	partitionr   append)r7   r8   r9   linekey_valuetexts   &&&     r   _print_headersrJ   /   s    D$K 4< NN40MCE6DKK;K/KKEK*KKMM$MM$t<89 r   c               (    V ^8  d   QhRRRRRRRR/# 	r   r7   r   r   r   r9   r:   r   r;   r   )r   s   "r   r   r   A   s.     3D 3D 3DH 3D 3D$ 3Dr   c           
     *   VP                   P                  RR4      pRV9   d_    \        P                  ! VP                  4       ^RR7      pV'       d"   V P	                  \        VRRRRR	7      4       R
# \	        V4       R
# VP                  R4      '       d8   \	        RV R\        VP                  4       R2\        P                  R7       R
# V'       g   \	        VP                  4       R
# RV9   d,   V P	                  \        VP                  RRRRR	7      4       R
# RV9   d,   V P	                  \        VP                  RRRRR	7      4       R
# V P	                  VP                  RRR7       R
#   \        P                  \        3 d     ELi ; i)z9Print response body, with syntax highlight when possible.zcontent-type jsonF)indentensure_ascii	ansi_darkTdefaulttheme	word_wrapbackground_colorNzimage/zBinary image data (z, z bytes)filehtmlxml)	highlightmarkup)headersr!   rO   dumpsrB   r   JSONDecodeError
ValueError
startswithlencontentr2   stderrrI   )r7   r   r9   content_type	formatteds   &&&  r   _print_bodyrh   A   sf   ##'';L	

8==?15QI!)"&)2  i  x((!,r#h6F6F2G1HP	
 	hmm!!*	
 
,	!!*	
 	hmmuUCA $$j1 		s   .E3 E3 5E3 3FFc               (    V ^8  d   QhRRRRRRRR/# rL   r   )r   s   "r   r   r   w   s(     2 27 2h 24 2D 2r   c                   \        V4      pRV RVP                   RVP                   2pV'       g   \        V4       R# VP                  R8  d   RpMVP                  R8  d   RpMRpV P                  \	        WER	7      4       R# )
zPrint the HTTP status line.zHTTP/ Ni,  rA   i  zbold yellowzbold redr>   )r$   status_codereasonrB   r   )r7   r   r9   verstatus_liner?   s   &&&   r   _print_statusrp   w   sz    
(
#C#a 4 45Qx6GHKkc!				#MM${01r   c               4    V ^8  d   QhRRRRRRRRRR	R
RRR/# )r   r   r   methodr'   urlrequest_headerszdict[str, str] | Nonerequest_body
str | Noner-   r   r;   r   )r   s   "r   r   r      sN     ,2 ,2,2,2 
,2 +	,2
 ,2 ,2 
,2r   c           
        \         P                  P                  4       p\        Wf'       * R 7      pRV9   dX   V RV 2.pT;'       g    / P	                  4        F  w  rVP                  V	 RV
 24       K  	  \        WxV4       \        4        RV9   dF   V'       d>   V'       d!   VP                  \        VRRRRR	7      4       M\        V4       \        4        R
V9   dU   \        WpV4       V P                  P	                  4        U	U
u. uF  w  rV	 RV
 2NK  	  pp	p
\        W{V4       \        4        RV9   d   \        WpV4       R# R# u up
p	i ))force_terminalno_colorHrk   r=   BrO   rR   TrS   rT   r*   r+   N)r2   r3   r4   r   itemsrD   rJ   rB   r   rp   r^   rh   )r   rr   rs   rt   ru   r-   r9   r7   r8   kvheader_liness   &&&&&&      r   print_outputr      s5    

!!#IYGG j81SE"#$**113DALLA3b% 4wy1 j\MM %"%. , jg3080@0@0F0F0HI0H1#Rs0HIwi8 jGy1  Js   
Ec                    V ^8  d   QhRRRR/# )r   namer'   r   r   )r   s   "r   r   r      s      S S r   c                    V P                  RR4      P                  R4      R,          P                  R4      R,          p \        P                  ! RRV 4      p T ;'       g    R# )	z2Remove or replace characters unsafe for filenames. rN   /\z[^\w.\-]rG   r1   )replacesplitresub)r   s   &r   _sanitize_filenamer      sT     <<#))#.r288>rBD66+sD)D:r   c               (    V ^8  d   QhRRRRRRRR/# )	r   r   r   rs   r'   output_pathrv   r   r;   r   )r   s   "r   r   r      s,     ; ;; ;/9;	;r   c                n   Vf   V P                   P                  RR4      pRV9   d8   VP                  R4      ^,          P                  R4      P                  R4      pM1VP	                  R4      P                  R4      R,          ;'       g    Rp\        V4      pV P                  p\        V4      p\        RR	7      p\        R
\        4       \        4       \        4       VR7      ;_uu_ 4       pVP                  W%R7      p\        VR4      ;_uu_ 4       p	Rp
\        ^ WZ4       F9  pWKW,            pV	P!                  V4       VP#                  V\        V4      4       K;  	  R R R 4       R R R 4       \%        RV 2\&        P(                  R7       R #   + '       g   i     L8; i  + '       g   i     LC; i)Nzcontent-dispositionrN   z	filename="'r   r1   T)re   z([progress.description]{task.description})r7   )totalwbzDownloaded to rX   r   i   )r^   r!   r   striprstripr   rd   rc   r   r   r	   r
   r   add_taskopenrangewriteadvancerB   r2   re   )r   rs   r   cdrd   r   r7   progresstaskf
chunk_sizeoffsetchunks   &&&          r   handle_downloadr      sc    !!"7<"((;/288=CCCHK**S///4R8FFJK$[1KGLET"G	2
 
 
   :+t$$"J55)<=  s5z2 6 %
 
N;-
(szz: %$
 
s%   .'F$AF	!F$F!F$$F4	)N)
__future__r   argparserO   r   r2   typingr   curl_cffi.constr   curl_cffi.requestsr   rich.consoler   rich.progressr   r	   r
   r   rich.syntaxr   	rich.textr   r$   r5   rJ   rh   rp   r   r   r   r   r   r   <module>r      s\    "   	 
  + '   R R  
5 :$3Dl2 ,2^; ;r   