
    4Քh                    |    S r SSKJ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  SSKJr  SSKJr   " S	 S
5      rg)z`Represents a wheel file and provides access to the various parts of the
name that have meaning.
    )annotationsN)IterableTag)BuildTagparse_wheel_filename)InvalidWheelFilename)
deprecatedc                      \ rS rSrSr\R                  " S\R                  5      rSS jr	\
SS j5       rSS jrSS jr      SS jrSS	 jrS
rg)Wheel   zA wheel filez^(?P<namever>(?P<name>[^\s-]+?)-(?P<ver>[^\s-]*?))
        ((-(?P<build>\d[^-]*?))?-(?P<pyver>[^\s-]+?)-(?P<abi>[^\s-]+?)-(?P<plat>[^\s-]+?)
        \.whl|\.dist-info)$c                  ^^ Xl         U   S U l         [        U5      nUu  U l        o0l        U l        [        U5      U l        g ! [         Ga-  nU R                  R                  U5      nU(       d  [        UR                  S   5      S e[        SU< SUR                  S    S3SSSS9  UR                  S	5      R                  S
S5      U l        UR                  S5      R                  S
S5      U l        UR                  S5      R                  S5      nUR                  S5      R                  S5      mUR                  S5      R                  S5      m[!        UU4S jU 5       5      U l         S nAg S nAff = f)Nr   zWheel filename zU is not correctly normalised. Future versions of pip will raise the following error:
z

zvto rename the wheel to use a correctly normalised name (this may require updating the version in the project metadata)z25.3i2  )reasonreplacementgone_inissuename_-verpyver.abiplatc           	   3  `   >#    U  H#  nT  H  nT  H  n[        XUS 9v   M     M     M%     g7f))interpreterr   platformNr   ).0pyr   r   abisplatss       R/var/www/auris/envauris/lib/python3.13/site-packages/pip/_internal/models/wheel.py	<genexpr>!Wheel.__init__.<locals>.<genexpr>F   s;      '$BC!D d; " < <$s   +.)filename
_build_tagr   r   	file_tagsstrversion_PackagingInvalidWheelFilenamelegacy_wheel_file_rematchr	   argsr
   groupreplacesplit	frozenset)	selfr%   
wheel_info_versionelegacy_wheel_info
pyversionsr    r!   s	          @@r"   __init__Wheel.__init__   sc     	+/%	-h7JCM@DIx$.x=DL- !	 $ 9 9 ? ? I$*166!954?%h\ 2Ovvayk'
,  *//7??SIDI,2259AA#sKDL +009??DJ$**5177<D%++F399#>E& '$' DNN9!	s   0A E<D#E77E<c                ^   U R                   b  U R                   $ U R                  R                  U R                  5      nUc   S5       eUR	                  S5      n[
        R                  " SU5      nUc   S5       eUR                  5       n[        US   5      US   4U l         U R                   $ )Nz!guaranteed by filename validationbuildz^(\d+)(.*)$r      )r&   r+   r,   r%   r.   regroupsint)r2   r6   	build_tagr,   build_tag_groupss        r"   r@   Wheel.build_tagM   s    ??&??" !55;;DMMJ ,Q.QQ,%++G4	3 E"EE  <<>/235Ea5HI    c                :    [        S U R                   5       5      $ )z4Return the wheel's tags as a sorted list of strings.c              3  8   #    U  H  n[        U5      v   M     g 7fN)r(   )r   tags     r"   r#   0Wheel.get_formatted_file_tags.<locals>.<genexpr>_   s     9.3c#hh.s   )sortedr'   )r2   s    r"   get_formatted_file_tagsWheel.get_formatted_file_tags]   s    9$..999rC   c                r   ^   [        U 4S j[        U5       5       5      $ ! [         a    [        5       ef = f)a  Return the lowest index that one of the wheel's file_tag combinations
achieves in the given list of supported tags.

For example, if there are 8 supported tags and one of the file tags
is first in the list, then return 0.

:param tags: the PEP 425 tags to check the wheel against, in order
    with most preferred first.

:raises ValueError: If none of the wheel's file tags match one of
    the supported tags.
c              3  P   >#    U  H  u  pUTR                   ;   d  M  Uv   M     g 7frF   )r'   )r   itr2   s      r"   r#   *Wheel.support_index_min.<locals>.<genexpr>o   s      Modadnn9Los   &	&)next	enumerateStopIteration
ValueErrorr2   tagss   ` r"   support_index_minWheel.support_index_mina   s4    	MioMMM 	,	s   ! 6c                B   ^ [        U4S jU R                   5       5      $ )aX  Return the priority of the most preferred tag that one of the wheel's file
tag combinations achieves in the given list of supported tags using the given
tag_to_priority mapping, where lower priorities are more-preferred.

This is used in place of support_index_min in some cases in order to avoid
an expensive linear scan of a large list of tags.

:param tags: the PEP 425 tags to check the wheel against.
:param tag_to_priority: a mapping from tag to priority of that tag, where
    lower is more preferred.

:raises ValueError: If none of the wheel's file tags match one of
    the supported tags.
c              3  <   >#    U  H  oT;   d  M
  TU   v   M     g 7frF    )r   rG   tag_to_prioritys     r"   r#   0Wheel.find_most_preferred_tag.<locals>.<genexpr>   s!      
,:S_>T OC Ns   	)minr'   )r2   rV   r\   s     `r"   find_most_preferred_tagWheel.find_most_preferred_tags   s#    "  
,0NN
 
 	
rC   c                B    U R                   R                  U5      (       + $ )z~Return whether the wheel is compatible with one of the given tags.

:param tags: the PEP 425 tags to check the wheel against.
)r'   
isdisjointrU   s     r"   	supportedWheel.supported   s    
 >>,,T222rC   )r&   r'   r%   r   r)   N)r%   r(   returnNone)re   r   )re   z	list[str])rV   	list[Tag]re   r?   )rV   rg   r\   zdict[Tag, int]re   r?   )rV   zIterable[Tag]re   bool)__name__
__module____qualname____firstlineno____doc__r=   compileVERBOSEr+   r8   propertyr@   rJ   rW   r_   rc   __static_attributes__r[   rC   r"   r   r      sh    ::	 	

	-^  :$

0>
	
*3rC   r   )rm   
__future__r   r=   collections.abcr   pip._vendor.packaging.tagsr   pip._vendor.packaging.utilsr   r   r	   r*   pip._internal.exceptionspip._internal.utils.deprecationr
   r   r[   rC   r"   <module>rx      s4    # 	 $ * F : 6y3 y3rC   