8fddlmZddlZddlmZmZmZmZddlm Z m Z ddl m Z m Z eedeeeffZedeZGd d eZGd d eZGd deZejdejZejdZejdZejdZddd'dZd(dZddd)d!Zd*d$Zd+d&Z dS),) annotationsN)NewTypeTupleUnioncast)Tag parse_tag)InvalidVersionVersionNormalizedNameceZdZdZdS) InvalidNamezW An invalid distribution name; users should refer to the packaging user guide. N__name__ __module__ __qualname____doc__r {/builddir/build/BUILD/imunify360-venv-2.3.5/opt/imunify360/venv/lib/python3.11/site-packages/pip/_vendor/packaging/utils.pyrrrrceZdZdZdS)InvalidWheelFilenamezM An invalid wheel filename was found, users should refer to PEP 427. Nrr rrrrrrrceZdZdZdS)InvalidSdistFilenamez^ An invalid sdist filename was found, users should refer to the packaging user guide. Nrr rrrrrrrz)^([A-Z0-9]|[A-Z0-9][A-Z0-9._-]*[A-Z0-9])$z[-_.]+z/^([a-z0-9]|[a-z0-9]([a-z0-9-](?!--))*[a-z0-9])$z (\d+)(.*)F)validatenamestrrboolreturnc|r,t|std|td|}t t|S)Nzname is invalid: -)_validate_regexmatchr_canonicalize_regexsublowerrr)rrvalues rcanonicalize_namer*-sg8--d3386d66777  # #C . . 4 4 6 6E  & &&rc:t|duSN)_normalized_regexr%)rs ris_normalized_namer.5s  " "4 ( ( 44rT)strip_trailing_zeroversion Version | strr/ct|tr# t|}n#t$r|cYSwxYw|}g}|jdkr||jddd|jD}|rtj dd|}|||j 7|dd|j D|j |d |j |j |d |j |j |d |j d|S) z This is very similar to Version.__str__, but has one subtle difference with the way it handles the release segment. r!.c34K|]}t|VdSr,r.0xs r z'canonicalize_version..Ps(>>!s1vv>>>>>>rz(\.0)+$Nc34K|]}t|VdSr,r6r7s rr:z'canonicalize_version..Xs(88SVV888888rz.postz.dev+) isinstancerr r epochappendjoinreleaserer'prepostdevlocal)r0r/parsedpartsrelease_segments rcanonicalize_versionrK9s'3 W%%FF   NNN  E|q  '''(((hh>>v~>>>>>OB&RAA LL!!!z RWW88VZ88888999{ *V[**+++z (FJ(()))| '''((( 775>>s ' 66filename8tuple[NormalizedName, Version, BuildTag, frozenset[Tag]]cN|dstd||dd}|d}|dvrtd||d|dz }|d}d |vs t jd |tjtd |t|} t|d }n%#t$r}td ||d}~wwxYw|dkr|d}t|}|td|d|dttt|d |df} nd} t|d} ||| | fS)Nz.whlz3Invalid wheel filename (extension must be '.whl'): r#)z0Invalid wheel filename (wrong number of parts): r__z ^[\w\d._]*$zInvalid project name: rz*Invalid wheel filename (invalid version): rQzInvalid build number: z in ''r )endswithrcountsplitrCr%UNICODEr*r r _build_tag_regexrBuildTagintgroupr ) rLdashesrI name_partrr0e build_part build_matchbuildtagss rparse_wheel_filenamereis   V $ $ " L( L L   }H ^^C F V" Ix I I    NN3 + +EaI yBH^Y KKS"#FH#F#FGGG Y ' 'D%(## " C C C    {{1X &,,Z88  &EEE(EEE XK$5$5a$8$8 9 9;;L;LQ;O;OPQQ U2Y  D '5$ ''sC C<$C77C<tuple[NormalizedName, Version]c|dr|dtd }n@|dr|dtd }ntd||d\}}}|std|t |} t |}n%#t $r}td||d}~wwxYw||fS)Nz.tar.gzz.zipz@Invalid sdist filename (extension must be '.tar.gz' or '.zip'): r#zInvalid sdist filename: z*Invalid sdist filename (invalid version): )rVlenr rpartitionr*r r )rL file_stemr_sep version_partrr0r`s rparse_sdist_filenamerms,## .I./   6 " " ^F |^, "      $-#7#7#<#< IsL J"#Hh#H#HIII Y ' 'D,'' " C C C    '?s,B<< CCC)rrrr r!r)rrr!r )r0r1r/r r!r)rLrr!rM)rLrr!rf)! __future__rrCtypingrrrrrdr r r0r r r\rr[r ValueErrorrrrcompile IGNORECASEr$r&r-rZr*r.rKrermr rrrss #""""" ............ ,,,,,,,, rE#s(O+ ,)3//* : :"*0"-!bj++BJQRR2:l++6;''''''5555 <@------`((((((((Vr