/opt/alt/python37/lib/python3.7/site-packages/setuptools/__pycache__
NameSizeModeActions
archive_util.cpython-37.opt-1.pyc56760644editdlrm
archive_util.cpython-37.pyc56760644editdlrm
build_meta.cpython-37.opt-1.pyc88280644editdlrm
build_meta.cpython-37.pyc88620644editdlrm
config.cpython-37.opt-1.pyc205920644editdlrm
config.cpython-37.pyc205920644editdlrm
depends.cpython-37.opt-1.pyc51250644editdlrm
depends.cpython-37.pyc51250644editdlrm
dep_util.cpython-37.opt-1.pyc8300644editdlrm
dep_util.cpython-37.pyc8300644editdlrm
dist.cpython-37.opt-1.pyc363370644editdlrm
dist.cpython-37.pyc364180644editdlrm
errors.cpython-37.opt-1.pyc8210644editdlrm
errors.cpython-37.pyc8210644editdlrm
extension.cpython-37.opt-1.pyc18930644editdlrm
extension.cpython-37.pyc18930644editdlrm
glob.cpython-37.opt-1.pyc36020644editdlrm
glob.cpython-37.pyc36520644editdlrm
installer.cpython-37.opt-1.pyc26710644editdlrm
installer.cpython-37.pyc27200644editdlrm
launch.cpython-37.opt-1.pyc8500644editdlrm
launch.cpython-37.pyc8500644editdlrm
monkey.cpython-37.opt-1.pyc45480644editdlrm
monkey.cpython-37.pyc45480644editdlrm
msvc.cpython-37.opt-1.pyc426220644editdlrm
msvc.cpython-37.pyc426220644editdlrm
namespaces.cpython-37.opt-1.pyc35150644editdlrm
namespaces.cpython-37.pyc35150644editdlrm
package_index.cpython-37.opt-1.pyc321880644editdlrm
package_index.cpython-37.pyc321880644editdlrm
py34compat.cpython-37.opt-1.pyc4550644editdlrm
py34compat.cpython-37.pyc4550644editdlrm
sandbox.cpython-37.opt-1.pyc153920644editdlrm
sandbox.cpython-37.pyc153920644editdlrm
unicode_utils.cpython-37.opt-1.pyc10770644editdlrm
unicode_utils.cpython-37.pyc10770644editdlrm
version.cpython-37.opt-1.pyc3010644editdlrm
version.cpython-37.pyc3010644editdlrm
wheel.cpython-37.opt-1.pyc70670644editdlrm
wheel.cpython-37.pyc70930644editdlrm
windows_support.cpython-37.opt-1.pyc9840644editdlrm
windows_support.cpython-37.pyc9840644editdlrm
_deprecation_warning.cpython-37.opt-1.pyc5210644editdlrm
_deprecation_warning.cpython-37.pyc5210644editdlrm
_imp.cpython-37.opt-1.pyc20590644editdlrm
_imp.cpython-37.pyc20590644editdlrm
__init__.cpython-37.opt-1.pyc85930644editdlrm
__init__.cpython-37.pyc85930644editdlrm
Edit: /opt/alt/python37/lib/python3.7/site-packages/setuptools/__pycache__/dist.cpython-37.pyc (36418B)
B ~”ReO¨ã@s²dgZddlZddlZddlZddlZddlZddlZddlZddl Zddl Zddl Zddl Zddl mZddlmZddlmZddlmZddlZddlZddlmZmZmZddlmZdd lmZdd lm Z m!Z!dd l m"Z"dd l#m$Z$dd l%m&Z&ddl%m'Z'ddl(m)Z)ddl*m+Z+ddl,Z,ddl-Z,ddl,m.Z.ddl/m0Z0ddl1m2Z2ddl3Z3erpddl4m5Z5e6dƒe6dƒdd„Z7dd„Z8e9e9dœdd„Z:de9ee9d œd!d"„Z;de9ee9d œd#d$„Zd*d+„Z?d,d-„Z@d.d/„ZAeBeCfZDd0d1„ZEd2d3„ZFd4d5„ZGd6d7„ZHd8d9„ZId:d;„ZJdd?„ZLd@dA„ZMdBdC„ZNdDdE„ZOdFdG„ZPdHdI„ZQe0ejRjSƒZTGdJd„deTƒZSGdKdL„dLe+ƒZUdS)MÚ DistributionéN)Ú strtobool)ÚDEBUG)Útranslate_longopt)Úiglob)ÚListÚOptionalÚ TYPE_CHECKING)Ú defaultdict)Úmessage_from_file)ÚDistutilsOptionErrorÚDistutilsSetupError)Ú rfc822_escape)Ú StrictVersion)Ú packaging)Ú ordered_set)Úunique_everseené)ÚSetuptoolsDeprecationWarning)Úwindows_support)Ú get_unpatched)Úparse_configuration)ÚMessagez&setuptools.extern.packaging.specifiersz#setuptools.extern.packaging.versioncCst dt¡t|ƒS)NzDo not call this function)ÚwarningsÚwarnÚDistDeprecationWarningr)Úcls©rú@/opt/alt/python37/lib/python3.7/site-packages/setuptools/dist.pyÚ_get_unpatched2s rcCs&t|ddƒ}|dkr"tdƒ}||_|S)NÚmetadata_versionz2.1)Úgetattrrr )ÚselfZmvrrrÚget_metadata_version7s  r#)ÚcontentÚreturnc CsJ| ¡}t|ƒdkr |d ¡Sd |d ¡t d |dd…¡¡f¡S)zFReverse RFC-822 escaping by removing leading whitespaces from content.rrÚ N)Ú splitlinesÚlenÚlstripÚjoinÚtextwrapÚdedent)r$ÚlinesrrrÚrfc822_unescape?s  r.r)ÚmsgÚfieldr%cCs||}|dkrdS|S)zRead Message header field.ÚUNKNOWNNr)r/r0ÚvaluerrrÚ_read_field_from_msgGsr3cCst||ƒ}|dkr|St|ƒS)z4Read Message header field and apply rfc822_unescape.N)r3r.)r/r0r2rrrÚ_read_field_unescaped_from_msgOs r4cCs| |d¡}|gkrdS|S)z9Read Message header field and return all results as list.N)Zget_all)r/r0ÚvaluesrrrÚ_read_list_from_msgWs r6)r/r%cCs| ¡ ¡}|dkrdS|S)Nr1)Z get_payloadÚstrip)r/r2rrrÚ_read_payload_from_msg_s r8cCsVt|ƒ}t|dƒ|_t|dƒ|_t|dƒ|_t|dƒ|_t|dƒ|_d|_t|dƒ|_ d|_ t|dƒ|_ t |d ƒ|_ d |krŒt|d ƒ|_nd|_t |d ƒ|_|jdkrÀ|jtd ƒkrÀt|ƒ|_t|dƒ|_d |kræt|d ƒ d¡|_t|dƒ|_t|dƒ|_|jtdƒkr4t|dƒ|_t|dƒ|_t|dƒ|_nd|_d|_d|_t|dƒ|_dS)z-Reads the metadata values from a file object.zmetadata-versionÚnameÚversionZsummaryÚauthorNz author-emailz home-pageÚlicensez download-urlÚ descriptionz2.1Úkeywordsú,ÚplatformZ classifierz1.1ÚrequiresÚprovidesÚ obsoletesz license-file)r rr r3r9r:r=r;Ú maintainerÚ author_emailÚmaintainer_emailZurlr4r<Ú download_urlZlong_descriptionr8Úsplitr>r6Z platformsZ classifiersrArBrCÚ license_files)r"Úfiler/rrrÚ read_pkg_filefs<              rKcCs"d|krt d¡| dd¡}|S)Nr&z1newlines not allowed and will break in the futureú )rrÚreplace)ÚvalrrrÚ single_line“s  rOc sÚ| ¡}‡fdd„}|dt|ƒƒ|d| ¡ƒ|d| ¡ƒ|dt| ¡ƒƒ|d| ¡ƒd}x.|D]&\}}t||d ƒ}|d k rh|||ƒqhWt|  ¡ƒ}|d |ƒ|j rº|d |j ƒx |j   ¡D]} |d d | ƒqÆWd  | ¡¡} | rø|d| ƒx| ¡D]} |d| ƒqW| ˆd| ¡¡| ˆd| ¡¡| ˆd| ¡¡| ˆd| ¡¡t|dƒrv|d|jƒ|jrŠ|d|jƒ|jr®x|jD]} |d| ƒqšW| ˆd|jpÀg¡ˆ d| ¡¡d S)z0Write the PKG-INFO format data to a file object.csˆ d||f¡dS)Nz%s: %s )Úwrite)Úkeyr2)rJrrÚ write_field¡sz#write_pkg_file..write_fieldzMetadata-VersionÚNameÚVersionZSummaryz Home-page))ZAuthorr;)z Author-emailrE)Z MaintainerrD)zMaintainer-emailrFNZLicensez Download-URLz Project-URLz%s, %sr?ZKeywordsZPlatformZ ClassifierZRequiresZProvidesZ ObsoletesÚpython_requireszRequires-PythonzDescription-Content-TypezProvides-Extraz License-Filez %s )r#ÚstrZget_nameZ get_versionrOZget_descriptionZget_urlr!rZ get_licenserGÚ project_urlsÚitemsr*Z get_keywordsZ get_platformsZ _write_listZget_classifiersZ get_requiresZ get_providesZ get_obsoletesÚhasattrrUÚlong_description_content_typeÚprovides_extrasrIrPZget_long_description) r"rJr:rRZoptional_fieldsr0ÚattrZattr_valr<Z project_urlr>r@Úextrar)rJrÚwrite_pkg_filesH          r^c Cs`ytj d|¡}|jrt‚Wn<ttttfk rZ}ztd||fƒ|‚Wdd}~XYnXdS)Nzx=z4%r must be importable 'module:attrs' string (got %r)) Ú pkg_resourcesÚ EntryPointÚparseZextrasÚAssertionErrorÚ TypeErrorÚ ValueErrorÚAttributeErrorr )Údistr\r2ÚepÚerrrÚcheck_importableÞs ric Csjy(t|ttfƒst‚d |¡|ks&t‚Wn<ttttfk rd}ztd||fƒ|‚Wdd}~XYnXdS)z"Verify that value is a string listÚz%%r must be a list of strings (got %r)N) Ú isinstanceÚlistÚtuplerbr*rcrdrer )rfr\r2rhrrrÚassert_string_listès rncCsh|}t|||ƒxR|D]J}| |¡s4tdd|ƒ‚| d¡\}}}|r||krtj d||¡qWdS)z(Verify that namespace packages are validz1Distribution contains no modules or packages for znamespace package %rÚ.z^WARNING: %r is declared as a package namespace, but %r is not: please correct this in setup.pyN)rnÚhas_contents_forr Ú rpartitionÚ distutilsÚlogr)rfr\r2Z ns_packagesZnspÚparentÚsepZchildrrrÚ check_nspös     rvc CsPytt t| ¡¡ƒWn2tttfk rJ}ztdƒ|‚Wdd}~XYnXdS)z+Verify that extras_require mapping is validz‹'extras_require' must be a dictionary whose values are strings or lists of strings containing valid project/version requirement specifiers.N) rlÚ itertoolsÚstarmapÚ _check_extrarXrcrdrer )rfr\r2rhrrrÚ check_extras s rzcCs<| d¡\}}}|r*t |¡r*td|ƒ‚tt |¡ƒdS)Nú:zInvalid environment marker: )Ú partitionr_Zinvalid_markerr rlÚparse_requirements)r]Zreqsr9ruÚmarkerrrrrys rycCs&t|ƒ|kr"d}t|j||dƒ‚dS)z)Verify that value is True, False, 0, or 1z0{attr!r} must be a boolean value (got {value!r}))r\r2N)Úboolr Úformat)rfr\r2ÚtmplrrrÚ assert_bools r‚cCs,|st |›dt¡dSt|›dƒ‚dS)Nz is ignored.z is invalid.)rrrr )rfr\r2rrrÚinvalid_unless_false$srƒc Csly(tt |¡ƒt|ttfƒr&tdƒ‚Wn>ttfk rf}zd}t|j ||dƒ|‚Wdd}~XYnXdS)z9Verify that install_requires is a valid requirements listzUnordered types are not allowedzm{attr!r} must be a string or list of strings containing valid project/version requirement specifiers; {error})r\ÚerrorN) rlr_r}rkÚdictÚsetrcrdr r€)rfr\r2r„rrrrÚcheck_requirements+s r‡c CsXytj |¡WnBtjjtfk rR}zd}t|j||dƒ|‚Wdd}~XYnXdS)z.Verify that value is a valid version specifierzF{attr!r} must be a string containing valid version specifiers; {error})r\r„N)rZ specifiersZ SpecifierSetZInvalidSpecifierrer r€)rfr\r2r„rrrrÚcheck_specifier9s rˆc CsBytj |¡Wn,tk r<}zt|ƒ|‚Wdd}~XYnXdS)z)Verify that entry_points map is parseableN)r_r`Z parse_maprdr )rfr\r2rhrrrÚcheck_entry_pointsDsr‰cCst|tƒstdƒ‚dS)Nztest_suite must be a string)rkrVr )rfr\r2rrrÚcheck_test_suiteLs rŠcCs^t|tƒstd |¡ƒ‚x@| ¡D]4\}}t|tƒsDtd ||¡ƒ‚t|d |¡|ƒq"WdS)z@Verify that value is a dictionary of package names to glob listszT{!r} must be a dictionary mapping package names to lists of string wildcard patternsz,keys of {!r} dict must be strings (got {!r})zvalues of {!r} dictN)rkr…r r€rXrVrn)rfr\r2ÚkÚvrrrÚcheck_package_dataQs  rcCs,x&|D]}t d|¡stj d|¡qWdS)Nz \w+(\.\w+)*z[WARNING: %r not a valid package name; please use only .-separated package names in setup.py)ÚreÚmatchrrrsr)rfr\r2ZpkgnamerrrÚcheck_packages`s   rc@s~eZdZdZdd„eejdd„dd„dœZdZdd „Z dUd d „Z d d „Z e dd„ƒZ e dd„ƒZdd„Zdd„Ze dd„ƒZdd„Zdd„Zdd„Ze dd„ƒZdVd d!„Zd"d#„Zd$d%„Zd&d'„ZdWd(d)„ZdXd+d,„Zd-d.„Zd/d0„Ze d1d2„ƒZd3d4„Zd5d6„Z d7d8„Z!d9d:„Z"d;d<„Z#d=d>„Z$d?d@„Z%dAdB„Z&dCdD„Z'dEdF„Z(dGdH„Z)dIdJ„Z*dKdL„Z+dMdN„Z,dOdP„Z-dQdR„Z.dSdT„Z/dS)YraG Distribution with support for tests and package data This is an enhanced version of 'distutils.dist.Distribution' that effectively adds the following new optional keyword arguments to 'setup()': 'install_requires' -- a string or sequence of strings specifying project versions that the distribution requires when installed, in the format used by 'pkg_resources.require()'. They will be installed automatically when the package is installed. If you wish to use packages that are not available in PyPI, or want to give your users an alternate download location, you can add a 'find_links' option to the '[easy_install]' section of your project's 'setup.cfg' file, and then setuptools will scan the listed web pages for links that satisfy the requirements. 'extras_require' -- a dictionary mapping names of optional "extras" to the additional requirement(s) that using those extras incurs. For example, this:: extras_require = dict(reST = ["docutils>=0.3", "reSTedit"]) indicates that the distribution can optionally provide an extra capability called "reST", but it can only be used if docutils and reSTedit are installed. If the user installs your package using EasyInstall and requests one of your extras, the corresponding additional requirements will be installed if needed. 'test_suite' -- the name of a test suite to run for the 'test' command. If the user runs 'python setup.py test', the package will be installed, and the named test suite will be run. The format is the same as would be used on a 'unittest.py' command line. That is, it is the dotted name of an object to import and call to generate a test suite. 'package_data' -- a dictionary mapping package names to lists of filenames or globs to use to find data files contained in the named packages. If the dictionary has filenames or globs listed under '""' (the empty string), those names will be searched for in every package, in addition to any names for the specific package. Data files found using these names/globs will be installed along with the package, in the same location as the package. Note that globs are allowed to reference the contents of non-package subdirectories, as long as you use '/' as a path separator. (Globs are automatically converted to platform-specific paths at runtime.) In addition to these new keywords, this class also has several new methods for manipulating the distribution's contents. For example, the 'include()' and 'exclude()' methods can be thought of as in-place add and subtract commands that add or remove packages, modules, extensions, and so on from the distribution. cCsdS)NrrrrrÚ¢ózDistribution.cCsdS)Nrrrrrr‘¥r’cCsdS)Nrrrrrr‘¦r’)rZrWr[Ú license_filerINcCsl|rd|ksd|krdSt t|dƒ¡ ¡}tjj |¡}|dk rh| d¡sht t|dƒ¡|_ ||_ dS)Nr9r:zPKG-INFO) r_Z safe_namerVÚlowerÚ working_setZby_keyÚgetZ has_metadataZ safe_versionZ_versionÚ _patched_dist)r"ÚattrsrQrfrrrÚpatch_missing_pkg_info«sz#Distribution.patch_missing_pkg_infocsÈtˆdƒ}|siˆ_|pi}gˆ_| dd¡ˆ_ˆ |¡| dg¡ˆ_| dg¡ˆ_x$t  d¡D]}t ˆƒ  |j d¡qbWt  ˆ‡fdd„| ¡Dƒ¡ˆ |¡ˆ ˆ ˆjj¡¡ˆj_ˆ ¡dS)NÚ package_dataÚsrc_rootÚdependency_linksÚsetup_requireszdistutils.setup_keywordscs i|]\}}|ˆjkr||“qSr)Ú_DISTUTILS_UNSUPPORTED_METADATA)Ú.0r‹rŒ)r"rrú Çsz)Distribution.__init__..)rYršZ dist_filesÚpopr›r™rœrr_Úiter_entry_pointsÚvarsÚ setdefaultr9Ú _DistributionÚ__init__rXÚ_set_metadata_defaultsÚ_normalize_versionÚ_validate_versionÚmetadatar:Ú_finalize_requires)r"r˜Zhave_package_datargr)r"rr¦¸s&    zDistribution.__init__cCs8x2|j ¡D]$\}}t|jƒ || ||ƒ¡¡q WdS)zä Fill-in missing metadata fields not supported by distutils. Some fields may have been set by other tools (e.g. pbr). Those fields (vars(self.metadata)) take precedence to supplied attrs. N)ržrXr£rªr¤r–)r"r˜ÚoptionÚdefaultrrrr§Õsz#Distribution._set_metadata_defaultscCsPt|tjƒs|dkr|Sttj |¡ƒ}||krLd}t |j ft ƒŽ¡|S|S)Nz)Normalizing '{version}' to '{normalized}') rkÚ setuptoolsÚsicrVrr:rTrrr€Úlocals)r:Z normalizedrrrrr¨ßszDistribution._normalize_versionc Csbt|tjƒrt|ƒ}|dk r^ytj |¡Wn0tjjtfk r\t   d|¡t   |¡SX|S)Nz¦The version specified (%r) is an invalid version, this may not work as expected with newer versions of setuptools, pip, and PyPI. Please see PEP 440 for more details.) rkÚnumbersÚNumberrVrr:rTZInvalidVersionrcrrr®r¯)r:rrrr©ës  zDistribution._validate_versioncCsjt|ddƒr|j|j_t|ddƒrVx2|j ¡D]$}| d¡d}|r.|jj |¡q.W| ¡|  ¡dS)z€ Set `metadata.python_requires` and fix environment markers in `install_requires` and `extras_require`. rUNÚextras_requirer{r) r!rUrªr³ÚkeysrHr[ÚaddÚ_convert_extras_requirementsÚ"_move_install_requirements_markers)r"r]rrrr«þs   zDistribution._finalize_requirescCspt|ddƒpi}ttƒ|_xP| ¡D]D\}}|j|x0t |¡D]"}| |¡}|j|| |¡qBWq$WdS)z¡ Convert requirements in `extras_require` of the form `"extra": ["barbazquux; {marker}"]` to `"extra:{marker}": ["barbazquux"]`. r³N) r!r rlÚ_tmp_extras_requirerXr_r}Ú _suffix_forÚappend)r"Z spec_ext_reqsÚsectionrŒÚrÚsuffixrrrr¶s   z)Distribution._convert_extras_requirementscCs|jrdt|jƒSdS)ze For a requirement, return the 'extras_require' suffix for that requirement. r{rj)r~rV)Úreqrrrr¹!szDistribution._suffix_forcs–dd„}tˆddƒpd}tt |¡ƒ}t||ƒ}t ||¡}ttt|ƒƒˆ_ x&|D]}ˆj dt|j ƒ  |¡qRWt ‡fdd„ˆj  ¡Dƒƒˆ_dS) zv Move requirements in `install_requires` that are using environment markers `extras_require`. cSs|j S)N)r~)r¾rrrÚ is_simple_req3szFDistribution._move_install_requirements_markers..is_simple_reqÚinstall_requiresNrr{c3s,|]$\}}|dd„tˆj|ƒDƒfVqdS)cSsg|] }t|ƒ‘qSr)rV)rŸr¼rrrú ?szMDistribution._move_install_requirements_markers...N)ÚmapÚ _clean_req)rŸr‹rŒ)r"rrú ?szBDistribution._move_install_requirements_markers..)r!rlr_r}ÚfilterrwÚ filterfalserÂrVrÀr¸r~rºr…rXr³)r"r¿Zspec_inst_reqsZ inst_reqsZ simple_reqsZ complex_reqsr¼r)r"rr·)s     z/Distribution._move_install_requirements_markerscCs d|_|S)zP Given a Requirement, remove environment markers and return it. N)r~)r"r¾rrrrÃCszDistribution._clean_reqcCs`|jj}|r|ng}|jj}|r2||kr2| |¡|dkrF|dkrFd}tt| |¡ƒƒ|j_dS)z>> list(Distribution._expand_patterns(['LICENSE'])) ['LICENSE'] >>> list(Distribution._expand_patterns(['setup.cfg', 'LIC*'])) ['setup.cfg', 'LICENSE'] css:|]2}tt|ƒƒD] }| d¡stj |¡r|VqqdS)ú~N)ÚsortedrÚendswithÚosÚpathÚisfile)rŸÚpatternrÎrrrrÄfsz0Distribution._expand_patterns..r)rÈrrrrÇ]s zDistribution._expand_patternsc Csàddlm}tjtjkrgnddddddd d d d d ddg }t|ƒ}|dkrR| ¡}tr`| d¡|ƒ}t |_ xÆ|D]¾}t j |dd(}trž| dj ftƒŽ¡| |¡WdQRXxt| ¡D]h}| |¡}| |¡} xN|D]F} | dksÚ| |krðqÚ| || ¡} | | |¡} | | |¡} || f| | <qÚWq¼W| ¡qrWd|jkrDdSx–|jd ¡D]„\} \} } |j | ¡} | r~t| ƒ } n| dkrt| ƒ} yt|| pž| | ƒWn.tk rÔ}zt|ƒ|‚Wdd}~XYnXqTWdS)z£ Adapted from distutils.dist.Distribution.parse_config_files, this method provides the same functionality in subtly-improved ways. r)Ú ConfigParserz install-basezinstall-platbasez install-libzinstall-platlibzinstall-purelibzinstall-headerszinstall-scriptsz install-dataÚprefixz exec-prefixÚhomeÚuserÚrootNz"Distribution.parse_config_files():zutf-8)Úencodingz reading {filename}Ú__name__Úglobal)ÚverboseZdry_run)Z configparserrÑÚsysrÒÚ base_prefixÚ frozensetZfind_config_filesrÚannouncerVZ optionxformÚioÚopenr€r°Z read_fileZsectionsÚoptionsÚget_option_dictr–Úwarn_dash_deprecationÚmake_option_lowercaser¦Úcommand_optionsrXÚ negative_optrÚsetattrrdr )r"Ú filenamesrÑZignore_optionsÚparserÚfilenameÚreaderr»ràZopt_dictÚoptrNÚsrcÚaliasrhrrrÚ_parse_config_filesmsd              z Distribution._parse_config_filescCsd|dkr |S| dd¡}tjj| ¡}| d¡sF|dkrF||krF|Sd|kr`t d||f¡|S)N)zoptions.extras_requirezoptions.data_filesú-Ú_ràrªzrUsage of dash-separated '%s' will not be supported in future versions. Please use the underscore name '%s' instead)rMrrÚcommandÚ__all__Ú_setuptools_commandsÚ startswithrr)r"rër»Zunderscore_optZcommandsrrrrâ¼s   z"Distribution.warn_dash_deprecationcCs4yt d¡}t| d¡ƒStjk r.gSXdS)Nr®zdistutils.commands)r_Zget_distributionrlZ get_entry_mapZDistributionNotFound)r"rfrrrróÔs  z!Distribution._setuptools_commandscCs4|dks| ¡r|S| ¡}t d|||f¡|S)NrªzlUsage of uppercase key '%s' in '%s' will be deprecated in future versions. Please use lowercase '%s' instead)Úislowerr”rr)r"rër»Z lowercase_optrrrrãÜsz"Distribution.make_option_lowercasec Csd| ¡}|dkr| |¡}tr,| d|¡x0| ¡D]"\}\}}tr^| d|||f¡ydd„|jDƒ}Wntk rŠg}YnXy |j}Wntk r®i}YnXy|t|t ƒ} ||krà| ràt |||t |ƒ ƒnJ||krþ| rþt ||t |ƒƒn,t ||ƒrt |||ƒnt d|||fƒ‚Wq8tk rZ} zt | ƒ| ‚Wdd} ~ XYq8Xq8WdS)aË Set the options for 'command_obj' from 'option_dict'. Basically this means copying elements of a dictionary ('option_dict') to attributes of an instance ('command'). 'command_obj' must be a Command instance. If 'option_dict' is not supplied, uses the standard option dictionary for this command (from 'self.command_options'). (Adopted from distutils.dist.Distribution._set_command_options) Nz# setting options for '%s' command:z %s = %s (from %s)cSsg|] }t|ƒ‘qSr)r)rŸÚorrrrÁÿsz5Distribution._set_command_options..z1error in %s: command '%s' has no such option '%s')Zget_command_namerárrÝrXZboolean_optionsrerårkrVrærrYr rd) r"Z command_objZ option_dictZ command_namer¬Úsourcer2Z bool_optsÚneg_optZ is_stringrhrrrÚ_set_command_optionsés:         z!Distribution._set_command_optionsFcCs0|j|dt||j|d| ¡| ¡dS)zYParses configuration files from various levels and loads configuration. )rç)Úignore_option_errorsN)rîrrär«rÉ)r"rçrúrrrÚparse_config_filess  zDistribution.parse_config_filescCs<tjjt |¡|jdd}x|D]}tjj|ddq W|S)zResolve pre-setup requirementsT)Ú installerZreplace_conflicting)rM)r_r•Úresolver}Úfetch_build_eggrµ)r"rAZresolved_distsrfrrrÚfetch_build_eggs$s zDistribution.fetch_build_eggscCsTd}dd„}t |¡}t |j|¡}tdd„|ƒ}xt||dD] }||ƒq@WdS)zè Allow plugins to apply arbitrary operations to the distribution. Each hook may optionally define a 'order' to influence the order of execution. Smaller numbers go first and the default is 0. z(setuptools.finalize_distribution_optionscSs t|ddƒS)NÚorderr)r!)ÚhookrrrÚby_order8sz/Distribution.finalize_options..by_ordercSs| ¡S)N)Úload)rhrrrr‘=r’z/Distribution.finalize_options..)rQN)r_r¢rwrÆÚ_removedrÂrË)r"ÚgrouprZdefinedZfilteredZloadedrgrrrÚfinalize_options/s zDistribution.finalize_optionscCsdh}|j|kS)zà When removing an entry point, if metadata is loaded from an older version of Setuptools, that removed entry point will attempt to be loaded and will fail. See #2765 for more details. Z 2to3_doctests)r9)rgZremovedrrrrAs zDistribution._removedcCsNxHt d¡D]:}t||jdƒ}|dk r |j|jd| ¡||j|ƒq WdS)Nzdistutils.setup_keywords)rü)r_r¢r!r9Úrequirerþr)r"rgr2rrrÚ_finalize_setup_keywordsOs z%Distribution._finalize_setup_keywordsc Csvtj tjd¡}tj |¡srt |¡t |¡tj |d¡}t|dƒ$}|  d¡|  d¡|  d¡WdQRX|S)Nz.eggsz README.txtÚwzcThis directory contains eggs that were downloaded by setuptools to build, test, and run plug-ins. zAThis directory caches those eggs to prevent repeated downloads. z/However, it is safe to delete this directory. ) rÍrÎr*ÚcurdirÚexistsÚmkdirrZ hide_filerßrP)r"Z egg_cache_dirZreadme_txt_filenameÚfrrrÚget_egg_cache_dirVs    zDistribution.get_egg_cache_dircCsddlm}|||ƒS)z Fetch an egg needed for buildingr)rþ)Zsetuptools.installerrþ)r"r¾rþrrrrþis zDistribution.fetch_build_eggcCs`||jkr|j|St d|¡}x:|D]&}|j|jd| ¡|j|<}|SWt ||¡SdS)z(Pluggable version of get_command_class()zdistutils.commands)rüN)Úcmdclassr_r¢rrþrr¥Úget_command_class)r"rñZepsrgrrrrros    zDistribution.get_command_classcCs>x2t d¡D]$}|j|jkr | ¡}||j|j<q Wt |¡S)Nzdistutils.commands)r_r¢r9rrýr¥Úprint_commands)r"rgrrrrr|s  zDistribution.print_commandscCs>x2t d¡D]$}|j|jkr | ¡}||j|j<q Wt |¡S)Nzdistutils.commands)r_r¢r9rrýr¥Úget_command_list)r"rgrrrrr„s  zDistribution.get_command_listcKsDx>| ¡D]2\}}t|d|dƒ}|r0||ƒq | ||¡q WdS)aôAdd items to distribution that are named in keyword arguments For example, 'dist.include(py_modules=["x"])' would add 'x' to the distribution's 'py_modules' attribute, if it was not already there. Currently, this method only supports inclusion for attributes that are lists or tuples. If you need to add support for adding to other attributes in this or a subclass, you can add an '_include_X' method, where 'X' is the name of the attribute. The method will be called with the value passed to 'include()'. So, 'dist.include(foo={"bar":"baz"})' will try to call 'dist._include_foo({"bar":"baz"})', which can then handle whatever special inclusion logic is needed. Z _include_N)rXr!Ú _include_misc)r"r˜r‹rŒÚincluderrrrŒs  zDistribution.includecsfˆd‰|jr&‡‡fdd„|jDƒ|_|jrD‡‡fdd„|jDƒ|_|jrb‡‡fdd„|jDƒ|_dS)z9Remove packages, modules, and extensions in named packagerocs"g|]}|ˆkr| ˆ¡s|‘qSr)rô)rŸÚp)ÚpackageÚpfxrrrÁ¨sz0Distribution.exclude_package..cs"g|]}|ˆkr| ˆ¡s|‘qSr)rô)rŸr)rrrrrÁ­scs&g|]}|jˆkr|j ˆ¡s|‘qSr)r9rô)rŸr)rrrrrÁ²sN)ÚpackagesÚ py_modulesÚ ext_modules)r"rr)rrrÚexclude_package¢s zDistribution.exclude_packagecCs4|d}x&| ¡D]}||ks(| |¡rdSqWdS)z.)rkÚsequencer r!reræ)r"r9r2Úoldrhr)r2rÚ _exclude_miscÀs   zDistribution._exclude_miscc s®t|tƒstd||fƒ‚yt||ƒ‰Wn0tk rX}ztd|ƒ|‚Wdd}~XYnXˆdkrpt|||ƒn:tˆtƒsˆt|dƒ‚n"‡fdd„|Dƒ}t||ˆ|ƒdS)zAHandle 'include()' for list/tuple attrs without a special handlerz%s: setting must be a list (%r)z %s: No such distribution settingNz4: this setting cannot be changed via include/excludecsg|]}|ˆkr|‘qSrr)rŸr)rrrrÁász.Distribution._include_misc..)rkrr r!reræ)r"r9r2rhÚnewr)rrrÑs    zDistribution._include_misccKsDx>| ¡D]2\}}t|d|dƒ}|r0||ƒq | ||¡q WdS)aRemove items from distribution that are named in keyword arguments For example, 'dist.exclude(py_modules=["x"])' would remove 'x' from the distribution's 'py_modules' attribute. Excluding packages uses the 'exclude_package()' method, so all of the package's contained packages, modules, and extensions are also excluded. Currently, this method only supports exclusion from attributes that are lists or tuples. If you need to add support for excluding from other attributes in this or a subclass, you can add an '_exclude_X' method, where 'X' is the name of the attribute. The method will be called with the value passed to 'exclude()'. So, 'dist.exclude(foo={"bar":"baz"})' will try to call 'dist._exclude_foo({"bar":"baz"})', which can then handle whatever special exclusion logic is needed. Z _exclude_N)rXr!r )r"r˜r‹rŒÚexcluderrrr"äs  zDistribution.excludecCs,t|tƒstd|fƒ‚tt|j|ƒƒdS)Nz.packages: setting must be a list or tuple (%r))rkrr rlrÂr)r"rrrrÚ_exclude_packagesûs  zDistribution._exclude_packagesc Cs°|jj|_|jj|_|d}| d¡}xB||krh||\}}||=ddl}| |d¡|dd…<|d}q(Wt |||¡}| |¡} t | ddƒr¬d|f| |¡d<|dk r¬gS|S)NrÚaliasesTrZcommand_consumes_argumentsz command lineÚargs) Ú __class__Zglobal_optionsråráÚshlexrHr¥Ú_parse_command_optsrr!) r"rèr%rñr$rìrír'ÚnargsZ cmd_classrrrr(s"        z Distribution._parse_command_optsc CsÌi}xÂ|j ¡D]´\}}xª| ¡D]ž\}\}}|dkr8q"| dd¡}|dkr¤| |¡}|j ¡}| t|diƒ¡x<| ¡D]\} } | |kr|| }d}Pq|Wtdƒ‚n |dkr°d}||  |i¡|<q"WqW|S) ahReturn a '{cmd: {opt:val}}' map of all command-line options Option names are all long, but do not include the leading '--', and contain dashes rather than underscores. If the option doesn't take an argument (e.g. '--quiet'), the 'val' is 'None'. Note that options provided by config files are intentionally excluded. z command linerðrïrråNzShouldn't be able to get herer) rärXrMZget_command_objråÚcopyÚupdater!rbr¤) r"ÚdÚcmdZoptsrërìrNZcmdobjrøÚnegÚposrrrÚget_cmdline_optionss(     z Distribution.get_cmdline_optionsccs‚x|jp dD] }|Vq Wx|jp$dD] }|Vq&WxH|jp>dD]:}t|tƒrX|\}}n|j}| d¡rt|dd…}|Vq@WdS)z@Yield all packages, modules, and extension names in distributionrÚmoduleNiúÿÿÿ)rrrrkrmr9rÌ)r"Zpkgr1Zextr9Z buildinforrrrEs      z$Distribution.iter_distribution_namesc CsÂddl}|jrt ||¡St|jtjƒs4t ||¡S|jj  ¡dkrPt ||¡S|jj}|jj }|j dkrndppd}|jj }t |j  ¡d|||¡|_z t ||¡St |j  ¡||||¡|_XdS)zÚIf there were any non-global "display-only" options (--help-commands or the metadata display options) on the command line, display the requested info and return true; else return false. rN)zutf-8Úutf8Zwin32r&zutf-8)rÚZ help_commandsr¥Úhandle_display_optionsrkÚstdoutrÞÚ TextIOWrapperrÖr”Úerrorsr@Úline_bufferingÚdetach)r"Z option_orderrÚrÖr6Únewliner7rrrr3Ws"    z#Distribution.handle_display_options)N)N)N)NF)0r×Ú __module__Ú __qualname__Ú__doc__r…rZ OrderedSetržr—r™r¦r§Ú staticmethodr¨r©r«r¶r¹r·rÃrÉrÇrîrârórãrùrûrÿrrrrrþrrrrrrpr rr"r#r(r0rr3rrrrrmsZ2      O .     (c@seZdZdZdS)rzrClass for warning about deprecations in dist in setuptools. Not ignored by default, unlike DeprecationWarning.N)r×r:r;r<rrrrr|sr)VròrÞrÚrŽrÍrr±Z distutils.logrrZdistutils.coreZ distutils.cmdZdistutils.distZdistutils.commandZdistutils.utilrZdistutils.debugrZdistutils.fancy_getoptrZglobrrwr+Útypingrrr Ú collectionsr Zemailr Zdistutils.errorsr r rZdistutils.versionrZsetuptools.externrrZ setuptools.extern.more_itertoolsrrjrr®Zsetuptools.commandrZsetuptools.monkeyrZsetuptools.configrr_Z email.messagerÚ __import__rr#rVr.r3r4r6r8rKrOr^rmrlrrirnrvrzryr‚rƒr‡rˆr‰rŠrrZcorerr¥rrrrrÚsŒ                - >