+
    kGjz               
      X  a  0 t $ ^ RIH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Ht ^ RIt^ RIHt ^ R	IHtHt ^ R
IHt ^ RIHtHt ^ RIHt ^ RIH t H!t! ^ RI"H#t# ]! ]$4      t%RRRRRRRRRR/t&R]'R&   ]'       d   ^ RI(H)t) R R lt*R t+ ! R R]4      t,R  R! lt-R# )"    )annotationsN)HeaderParser)	getLogger)PathLike)Path)TYPE_CHECKINGBinaryIOIterableLiteralTuple)WheelDestination)HashRecordEntry)	WheelFile)Schemeparse_wheel_filename)	parse_tag)copy_into_info_licenses#package_metadata_from_metadata_body)sha256_base64url_to_hexpurelibsite-packagesplatlibscriptsbindata headersincludezdict[Scheme, str]SCHEME_TO_CONDA_PREFIX)Messagec               $    V ^8  d   QhRRRRRR/# )   
wheel_metar!   wheel_filenamestrreturnztuple[str, int] )formats   "Alib/python3.14/site-packages/conda_pypi/package_extractors/whl.py__annotate__r+   $   s&     !& !&!&!& !&    c                   V P                  R4      ;'       g    . pV'       d   TpM6\        \        V4      P                  4       Uu. uF  p\	        V4      NK  	  ppRV9   d   RM
\        V4      pVR8w  d0   VP                  R4      '       d   \        P                  RV4       Rp^ pV P                  R4      pVe"   VP                  4       '       d   \        V4      pVP                  RR4       RV 2pW3# u upi )zCreate a build string and number from wheel metadata and filename.

Wheel metadata (the WHEEL file) is the primary source and filename is secondary.
Some normalization is applied for compatibility with repodata v3.
Tagzpy3-none-anyz	-none-anyzeNormalizing wheel tag %s to py3-none-any for index.json build (matches repodata v3 noarch convention)Build-_)get_allr   r   tagr&   maxendswithloggerinfogetisdigitintreplace)	r$   r%   	tag_linestag_candidatest	wheel_tagbuild_numberwheel_buildbuild_strings	   &&       r*   1_create_build_string_from_wheel_meta_and_filenamerC   $   s     ""5)//RI" +44H4X4\4\*]^*]Q#a&*]^"0N"BNH[IN"y'9'9+'F'F6	

 #	L..)K;#6#6#8#8;'''S12!L>BL%%% _s   C9c                r    \         P                  ! V^RRR7      p\        V 4      P                  VRR7       R# )r#   T)indent	sort_keys
separatorszutf-8)encodingN),:)jsondumpsr   
write_text)	file_pathobjjson_strs   && r*   write_as_json_to_filerQ   J   s-    zz#a4JOHOx':r,   c                  R    ] tR t^OtR R ltR R ltR R ltR R ltR	 R
 ltRt	R# )MyWheelDestinationc               $    V ^8  d   QhRRRRRR/# )r#   target_full_path
str | Pathsourcer   whl_full_pathr(   )r)   s   "r*   r+   MyWheelDestination.__annotate__P   s(     
 
$
 
 "	
r,   c                	    \        V4      V n        \        V4      V n        V P                  R ,          V n        . V n        W n        R# )r   N)r   rU   rX   sp_direntry_pointsrW   )selfrU   rW   rX   s   &&&&r*   __init__MyWheelDestination.__init__P   s>     !%%5 6!-0++o=r,   c          
     ,    V ^8  d   QhRRRRRRRRRR/# )	r#   namer&   moduleattrsectionz#Literal['console'] | Literal['gui']r'   r   r(   )r)   s   "r*   r+   rY   \   s4     

 



!$

,/

:]

	

r,   c                	n    V R V RV 2pV P                   P                  V4       \        RV 2RRR7      # )z = rJ   z../../../bin/Npathhash_size)r\   appendr   )r]   ra   rb   rc   rd   entry_points   &&&&& r*   write_scriptMyWheelDestination.write_script\   sK     c&4&1  - '
 	
r,   c          
     ,    V ^8  d   QhRRRRRRRRR	R
/# )r#   schemer   rg   zstr | PathLikestreamr	   is_executableboolr'   r   r(   )r)   s   "r*   r+   rY   h   s4     
 

$2
<D
UY
	
r,   c                	V   V\         9  d   \        R V 24      h\        V4      P                  4       p\         V,          pV'       d   V P                  V,          V,          pMV P                  V,          pVP
                  P                  RRR7       VP                  R4      ;_uu_ 4       p\        P                  P                  VVRR7      w  rRRR4       V'       d    \        P                  P                  V4       \        V\        RX4      X	R7      #   + '       g   i     LO; i)zUnsupported scheme: T)parentsexist_okwbsha256)rW   desthash_algorithmNrf   )r    
ValueErrorr   as_posixrU   parentmkdiropen	installerutilscopyfileobj_with_hashingmake_file_executabler   r   )
r]   ro   rg   rp   rq   conda_prefix	dest_pathrx   rh   ri   s
   &&&&&     r*   
write_fileMyWheelDestination.write_fileh   s     //3F8<==Dz""$-f5--<tCI--4Itd;^^D!!T#//BB' C KE " OO00;x'
 	
 "!s   ,%DD(	c               $    V ^8  d   QhRRRRRR/# )r#   records$Iterable[Tuple[Scheme, RecordEntry]]rW   r   r'   Noner(   )r)   s   "r*   r+   rY      s)     =M =M;=MEN=M	=Mr,   c           
     	Z   V P                   R ,          pVP                  RR7       RRR/R^/pV P                  '       d   V P                  VR,          R&   \        VR,          V4       . pV F  w  rgVP                  P                  R	4      '       d   K(  \        V,          pV'       d   V R
VP                   2MVP                  p	RT	RRR\        VP                  '       d   VP                  P                  MR4      RVP                  /p
VP                  V
4       K  	  RVR^/p\        VR,          V4       \        VP                  4      p\        VP                  4      pV P                  P                   p\#        4       P%                  VP'                  R4      4      p\)        W4      w  ppRVRVRVRVRV/p\        VR,          V4       \+        V P,                  P/                  R4      4      pV'       d1   \1        VP'                  R4      4      p\3        V^ ,          VV4       R# R# )r7   T)ru   noarchtypepythonpackage_metadata_versionr\   z	link.jsonz../_path	path_typehardlinkrw   Nsize_in_bytespathspaths_versionz
paths.jsonWHEELra   versionbuildr@   fnz
index.jsonz*.dist-infoMETADATA)rU   r}   r\   rQ   rg   
startswithr    r   rh   valueri   rj   r&   distributionr   rX   ra   r   parsestrread_dist_inforC   sortedr[   globr   r   )r]   r   rW   info_dirlink_json_datar   ro   recordr   
conda_pathrg   paths_json_datapackage_namepackage_versionr%   r$   rB   r@   index_json_data
dist_infoswheel_metadatas   &&&                  r*   _create_conda_metadata)MyWheelDestination._create_conda_metadata   s    ((61%  '	
 7;7H7HN8$^4h4nE %NF{{%%d++1&9L<HL>6;;-8fkkJZ1&,,2D2DZ^_	D LL & UQ
 	h5G 6../fnn-++00!^,,V-B-B7-KL
%V&
"l
 L\L.
 	h5GDKK,,];<
@AVAVWaAbcN#JqM8^L r,   c               (    V ^8  d   QhRRRRRRRR/# )	r#   ro   r   record_file_pathr&   r   r   r'   r   r(   )r)   s   "r*   r+   rY      s2        6	
 
r,   c                	   \        V4      p\        P                  P                  VR  4      ;_uu_ 4       pV P                  V,          pVP                  R4      ;_uu_ 4       p\        P                  P                  WWR4      w  r\        V\        RV4      V	R7      p
RRR4       RRR4       RX
3VR&   V P                  W@P                  4       R#   + '       g   i     L<; i  + '       g   i     LG; i)c                    R # )Nr(   )xs   &r*   <lambda>:MyWheelDestination.finalize_installation.<locals>.<lambda>   s    $r,   rv   rw   rf   Nr   )listr   r   construct_record_filer[   r~   r   r   r   r   rW   )r]   ro   r   r   record_listrecord_streamr   rx   rh   ri   record_file_records   &&&&       r*   finalize_installation(MyWheelDestination.finalize_installation   s     7m__22;OOS`&66I%%'ooFF! &1)x/&"	 & P %&89B##K= &% POs#   -C$";C	C$C!C$$C4	)r\   rW   r[   rU   rX   N)
__name__
__module____qualname____firstlineno__r^   rl   r   r   r   __static_attributes__r(   r,   r*   rS   rS   O   s"    



<=M~ r,   rS   c                    V ^8  d   QhRRRR/# )r#   rX   rV   rU   r(   )r)   s   "r*   r+   r+      s     
 
J 
* 
r,   c           
         \        V 4      p \        P                  ! V 4      ;_uu_ 4       p\        P                  ! V\        WV 4      R R/R7       RRR4       R#   + '       g   i     R# ; i)	INSTALLERs   conda-via-whl)rW   destinationadditional_metadataN)r   r   r~   r   installrS   )rX   rU   rW   s   && r*   extract_whl_as_conda_pkgr      sQ    'M		&	&&*+;]S!,.> ?	
 
'	&	&	&s   &AA+	).__conditional_annotations__
__future__r   rK   email.parserr   loggingr   osr   pathlibr   typingr   r	   r
   r   r   installer.utilsr   installer.destinationsr   installer.recordsr   r   installer.sourcesr   r   r   packaging.tagsr   conda_pypi.license_filesr   r   conda_pypi.utilsr   r   r6   r    __annotations__email.messager!   rC   rQ   rS   r   )r   s   @r*   <module>r      s    " "  %    D D  3 / ' 8 $ a 4	8	
 u
By- )  %!&L;
J) JZ
r,   