
    njf                        S SK Jr  S SKrS SKrS SKrS SKJr  S SK	J
r
  S SKJrJr  SSKJrJr  \R"                  " S5      r S         SS	 jjrSS
 jrg)    )annotationsN)BytesGenerator)BytesParser)InvalidVersionVersion   )
WheelError	WheelFilez6^(?P<namever>(?P<name>.+?)-(?P<ver>\d.*?))\.dist-info$c           	        [         R                  " U 5       Vs/ s Hd  n[         R                  R                  [         R                  R	                  X5      5      (       d  MF  [
        R                  U5      (       d  Mb  UPMf     nn[        U5      S:  a  [        SU  35      eU(       d  [        SU  35      eUS   n[
        R                  U5      nUR                  S5      nUR                  S5      n	UR                  S5      n
UGbC  U
R                  S	S5      S   nUS
:X  a  UOU S	U 3n [        U5        SU;   a  [        SU< S35      eU	 SU 3nU S3n[         R                  " [         R                  R	                  X5      [         R                  R	                  X5      5        UnUn[         R                  R	                  XS5      n [        US5       n[        [         R"                  R$                  S9R'                  U5      nSSS5        WS	 UUS'   [        US5       n[+        USS9R-                  U5        SSS5        [         R                  R	                  XS5      n[        US5       n[        [         R"                  R$                  S9R'                  U5      nUR/                  S/ 5      nUR1                  S5      nU(       d  [        SU S35      e SSS5        Ub  UOWnUbK  WS	 U(       a  UUS'   USU-   -  nUW:w  a.  [        US5       n[+        USS9R-                  U5        SSS5        [3        W5      n[         R                  R	                  X SU S35      n[5        US5       n[7        S U S!3S
S"S#9  UR9                  U 5        SSS5        [7        S$5        gs  snf ! [         a  n[        SU< SU 35      SeSnAff = f! , (       d  f       GN= f! [(         a    [        SU S35      Sef = f! , (       d  f       GN= f! , (       d  f       GNA= f! , (       d  f       N= f! , (       d  f       N= f)%a  Repack a previously unpacked wheel directory into a new wheel file.

The .dist-info/WHEEL file must contain one or more tags so that the target
wheel file name can be determined.

:param directory: The unpacked wheel directory
:param dest_dir: Destination directory (defaults to the current directory)
:param build_number: Build tag to use in the wheel name
:param local_version: Local version identifier to add or replace
   z)Multiple .dist-info directories found in z#No .dist-info directories found in r   namevernameverN+ zInvalid version z: -z!Invalid local version identifier zK: wheel filenames cannot contain '-' in the version; use '_' instead of '-'z
.dist-infoMETADATArb)policyzMissing z/METADATA filer   wb)maxheaderlenWHEELTagBuildzNo tags present in z./WHEEL; cannot determine target wheel filenamez.whlwzRepacking wheel as z...T)endflushOK)oslistdirpathisdirjoinDIST_INFO_REmatchlenr	   groupsplitr   r   renameopenr   emailr   compat32parseFileNotFoundErrorr   flattenget_allgetcompute_tagliner
   printwrite_files)	directorydest_dirbuild_numberlocal_versionfndist_info_dirsdist_info_dirr%   name_versionr   versionbase_versionnew_versionenew_namevernew_dist_info_dirmetadata_pathfmetadatawheel_file_pathinfotagsexisting_build_numbertagline
wheel_pathwfs                             P/var/www/html/pdf-tiff/venv/lib/python3.13/site-packages/wheel/_commands/pack.pypackrN      s   & **Y''B77==i45 	:F:L:LR:P 	'  
 >QDYKPQQ>ykJKK #1%M}-E;;y)L;;vDkk% G  }}S!,Q/)R/L~Q}o5V 		PK  +3M3D E) )  a}-*m:6
		GGLL2GGLL6	
 *" YzJ	QmT*a&ell.C.CDJJ1M +
 Y)-&!11-55h? ' ggll9WEO	ot	$%,,"7"78>>qA,,ub1 $ 1%m_ 5! "   
% $0#;<AVLM(DMC,..L00ot,qq199$? - d#G h.'$(GHJ	:s	#r#J<s34H
y! 
$ 
$Kw2  	P/bDE4O	P, +*  	QxnEFDP	Q
 '&
 
%	$( -, 
$	#s   AN1"N1>N1.N6 O- 1OO- *P8A*PP/<!Q 6
O OO
O*%O- *O- -P
P
P,/
P= 
Qc                   [        U  Vs1 s H  oR                  S5      S   iM     sn5      n[        U  Vs1 s H  oR                  S5      S   iM     sn5      n[        U  Vs1 s H  oR                  S5      S   iM     sn5      nSR                  SR                  U5      SR                  U5      SR                  U5      /5      $ s  snf s  snf s  snf )zWCompute a tagline from a list of tags.

:param tags: A list of tags
:return: A tagline
r   r   r   r   .)sortedr(   r#   )rH   tagimplsabivers	platformss        rM   r2   r2      s     6#IIcN1%67E484CiinQ'489GT:Tc		#q)T:;I88SXXe_chhw&7)9LMNN 78:s   C	C$C)N)
r5   strr6   rV   r7   
str | Noner8   rW   returnNone)rH   z	list[str]rX   rV   )
__future__r   email.policyr+   os.pathr   reemail.generatorr   email.parserr   packaging.versionr   r   	wheelfiler	   r
   compiler$   rN   r2        rM   <module>re      sq    "   	 * $ 5 -zzST !%	lll l 	l
 
l^	Ord   