JFIFxxC      C  " }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3RbrJFIFxxC      C  " }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3Rbr ԓgdZddlmZddlZddlZddlZddlZddlZddl m Z ddl m Z ddl mZmZmZmZddlmZdd Zej*dd Zej/edd Z dd Zdd ZddZddZddZ ddZddZ y)z2 Tools for converting old- to new-style metadata. ) annotationsN)Message)Parser) GeneratorIterableIteratorLiteral) Requirementc.|xr|jd S)N#) startswith)strs =/opt/hc_python/lib/python3.12/site-packages/wheel/metadata.py _nonblankrs  *s~~c***c\tjjtt|S)a Yield valid lines of a string or iterable. >>> list(yield_lines('')) [] >>> list(yield_lines(['foo', 'bar'])) ['foo', 'bar'] >>> list(yield_lines('foo\nbar')) ['foo', 'bar'] >>> list(yield_lines('\nfoo\n#bar\nbaz #comment')) ['foo', 'baz #comment'] >>> list(yield_lines(['foo\nbar', 'baz', 'bing\n\n\n'])) ['foo', 'bar', 'baz', 'bing'] ) itertoolschain from_iterablemap yield_lines)iterables rrrs  ?? ( ([()C DDrcnttttj|j SN)filterrrrstrip splitlines)texts r_r )s! )SDOO,=> ??rc#Kd}g}t|D]a}|jdr=|jdr |s|r||f|ddj}g}Et d||j |c||fyw)arSplit a string or iterable thereof into (section, content) pairs Each ``section`` is a stripped version of the section header ("[section]") and each ``content`` is a list of stripped lines excluding blank lines and comment-only lines. If there are any such lines before the first section header, they're returned in a first ``section`` of ``None``. N[]r zInvalid section heading)rrendswithr ValueErrorappend)ssectioncontentlines rsplit_sectionsr,.sGGA ??3 }}S!g!7**q***, !:DAA NN4  7 sA;A=cLtjdd|jS)zConvert an arbitrary string to a standard 'extra' name Any runs of non-alphanumeric characters are replaced with a single '_', and the result is always lowercased. z[^A-Za-z0-9.-]+r )resublower)extras r safe_extrar2Is! 66#S% 0 6 6 88rc0tjdd|S)zConvert an arbitrary string to a standard distribution name Any runs of non-alphanumeric/. characters are replaced with a single '-'. z[^A-Za-z0-9.]+-)r.r/)names r safe_namer6Qs 66"C ..rc|jrd|jzSg}|jD]*}|j|j|jz,|rddj t |zSy)zFReturn the version specifier for a requirement in PEP 345/566 fashion.z @  ,)url specifierr'operatorversionjoinsorted) requirement requires_distspecs rrequires_to_requires_distrDXsi{&&!M%%T]]T\\9:&SXXf]3444rc#K|D]h}t|}t|}djtd|jD}|rd|d}t |j |z|zjyw)z=Yield Requires-Dist: strings for parsed requirements strings.r9c32K|]}t|ywr)r2).0es r z'convert_requirements..ls R8Q1A8Qsr"r#N)r rDr?r@extrasr6r5) requirementsreqparsed_requirementrCrJs rconvert_requirementsrNgsr(-();<& R8J8Q8Q RRS ]F*//069D@@sA/A1c#2K|jD]\}}d}|xsd}d|vr|jdd\}}t|}|rd|f|rd|zdz}|d|dz }|rd |z}t|D]}t t ||z}d |f!y w) a, Convert requirements from a setup()-style dictionary to ('Requires-Dist', 'requirement') and ('Provides-Extra', 'extra') tuples. extras_require is a dictionary of {extra: [requirements]} as passed to setup(), using the empty extra {'': [requirements]} to hold install_requires. r::r Provides-Extra(z) and z extra == ''z ; Requires-DistN)itemssplitr2rNrr )extras_requirer1depends conditionnew_req canonical_reqs rgenerate_requirementsr\ss)..0w   %<${{32 E95! "E) ))Oh6 :eWA. .I  )I+G4G Gi,? @AM!=0 05!1sBBc  t|d5}tj|}dddjdd|d=|d=tj j |d}tj j|rvt|d5}|j}dddttd }|D]4\}} t|| iD]\} } | | f|jvs| || <!6|d } | rq|d j} d j | d jtj d j | ddd f}|j#||d =|S#1swYQxYw#1swYxYw)zN Convert .egg-info directory with PKG-INFO to the Metadata 2.1 format zutf-8)encodingNzMetadata-Versionz2.1rQrTz requires.txtc|dxsdS)Nrr:)xs rz%pkginfo_to_metadata..sQqTZUWZr)key Description rr )openrparsereplace_headerospathr?existsreadr@r,r\rUrlstriptextwrapdedent set_payload) egg_info_path pkginfo_pathheaderspkg_info requires_path requires_filerequiresparsed_requirementsr1reqsrcvalue descriptiondescription_linesdedented_descriptions rpkginfo_to_metadatar~s~ lW -8>>'* . .6!"!GGLL?M ww~~m$ -' 2m$))+H3%^H%=CWX.KE43UDMB U>@#yy"!$++- *;AB*? @A   12 ] # OC . -3 2sE7F7FF )rrreturnzbool | Literal[''])rz Iterable[str]r Iterator[str])rrrr)r(zstr | Iterator[str]rz3Generator[tuple[str | None, list[str]], None, None])r1rrr)r5rrr)rAr rr)rKz list[str]rr)rWzdict[str | None, list[str]]rzIterator[tuple[str, str]])rqrrrrrr)!__doc__ __future__r functoolsros.pathrir.rn email.messager email.parserrtypingrrrr vendored.packaging.requirementsr rsingledispatchrregisterrr r,r2r6rDrNr\r~r`rrrs# !998+ EE" c@@869/  A1/11>%r