1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
U
H=®dnpã@sdZddlmZddlZddlZddlZddlmZddlm    Z    ddl
m Z m Z m Z ddlmZddlmZdd    lmZdd
lmZmZdd lmZdd lmZdd lmZddlmZddlmZerddl m!Z!m"Z"m#Z#m$Z$m%Z%ddl
m&Z&m'Z'ddl(m)Z)dd„Z*dd„Z+ddd„Z,ddd„Z-dd„Z.Gdd„de ƒZ/e    e d d!d"d"d#d$Z0e    e d%d&d'dd(d)Z1e    e d*d+d,d'de d)Z2e    e d-d.d/d0dd1d)Z3e    e d2d3d'dd4d)Z4e    e d5d6d7d'd8d$Z5e    e d9d:d;d0dd<d)Z6e    e d=d>d?e7e 8¡ƒd@dAdB 9e 8¡¡dCdDZ:e    e/dEdFdGdHdIdIdJdKZ;e    e dLdMd'ddNd)Z<e    e dOdPdQdRdSdTZ=e    e dUdVdWdXdYdTZ>e    e dZd[d\d]d^d_d`daZ?dbdc„Z@e    e/dddedIdIdfdgZAe    e/dhdidIddIdjdkZBe    e dldmdndodpejCdqdrZDdsdt„ZEe    e dudvd'ddwd)ZFdxdy„ZGdzd{„ZHd|d}„ZId~d„ZJd€d„ZKd‚dƒ„ZLe    e/d„d…d†d‡dˆdId‰eƒdŠeLd‹dŒ ZMddŽ„ZNdd„ZOd‘d’„ZPd“d”„ZQd•d–„ZRe    e d—d˜d˜dd™drZSdšd›„ZTdœd„ZUe    e dždŸdŸdŠeUdQded ƒd¡    ZVe    e d¢d£d£dd¤drZWe    e d¥d¦d¦dd§drZXd¨d©„ZYdªd«„ZZd¬d­„Z[e    e/d®d¯ed‰dId°d±Z\d²d³„Z]e    e d´d¯dŠe]dµd¶Z^e    e d·d¸d¹d'ddºd)Z_d»d¼„Z`e    e/d½d¾d¿dÀdÁdId‰dŠe`dÂdÍ Zae    e dÄdÅd'dÆd$Zbe    e dÇdÈdÉdÊdËd)ZcdÌd̈́Zde    e dÎdÏd'ddÐd)Zee    e dÑdÏdŠedde dҍZfe    e dÓdÔdÕdÖd×d؍Zge    e dÙdÚdÕdÖdÛd؍Zhe    e dÜd'ddÝdލZie    e dßd'ddàdލZje    e dádâd'ddãd)Zkdädå„Zle    e dædçdŠeldèdédêZme    e dëdìd'ddíd)Zne    e/dîdIdIdÕdïdðZodñdò„Zpe    e dódôd'ddõd)Zqe    e död÷dødÕgdùge dúZre    e dûdüdødÕgdýdþgdÿdúZse    e dddødÕggddúZtde0e1e2e3e5e6e;e<e=e>e?e@eHeAeBe\e^eke4eqeresetgdœZudeDeEeFeGgdœZvdS(aC
shared options and groups
 
The principle here is to define options once, but *not* instantiate them
globally. One reason being that options with action='append' can carry state
between parses. pip parses general options twice internally, and shouldn't
pass on state. To be consistent, all options will follow this design.
é)Úabsolute_importN)Ú    strtobool)Úpartial)Ú SUPPRESS_HELPÚOptionÚ OptionGroup)Údedent)Ú    BAR_TYPES)Ú CommandError)ÚUSER_CACHE_DIRÚget_src_prefix)Ú FormatControl)ÚPyPI)Ú TargetPython)Ú STRONG_HASHES)ÚMYPY_CHECK_RUNNING)ÚAnyÚCallableÚDictÚOptionalÚTuple)Ú OptionParserÚValues)ÚConfigOptionParsercCs.d ||¡}t d | ¡¡¡}| |¡dS)z­
    Raise an option parsing error using parser.error().
 
    Args:
      parser: an OptionParser instance.
      option: an Option instance.
      msg: the error text.
    z {} error: {}ú N)ÚformatÚtextwrapÚfillÚjoinÚsplitÚerror)ÚparserÚoptionÚmsg©r$úSD:\z\workplace\VsCode\pyvenv\venv\Lib\site-packages\pip/_internal/cli/cmdoptions.pyÚraise_option_error&s
r&cCs,t||dƒ}|dD]}| |ƒ¡q|S)z‡
    Return an OptionGroup object
    group  -- assumed to be dict with 'name' and 'options' keys
    parser -- an optparse Parser
    ÚnameÚoptions)rÚ
add_option)Úgroupr!Ú option_groupr"r$r$r%Úmake_option_group5s r,csPˆdkr |‰‡fdd„}dddg}tt||ƒƒrL|j}| ¡tjddd    dS)
zÏDisable wheels if per-setup.py call options are set.
 
    :param options: The OptionParser options to update.
    :param check_options: The options to check, if not supplied defaults to
        options.
    Ncs tˆ|dƒS©N)Úgetattr)Ún©Ú check_optionsr$r%ÚgetnameMsz+check_install_build_global.<locals>.getnameÚ build_optionsÚglobal_optionsÚinstall_optionszbDisabling all use of wheels due to the use of --build-option / --global-option / --install-option.é)Ú
stacklevel)ÚanyÚmapÚformat_controlÚdisallow_binariesÚwarningsÚwarn)r(r1r2ÚnamesÚcontrolr$r0r%Úcheck_install_build_globalBs 
þr@FcCsbt|j|j|j|jgƒ}ttƒdhƒ}|j|ko6|j }|rH|rHt    dƒ‚|r^|r^|j
s^t    dƒ‚dS)zÀFunction for determining if custom platform options are allowed.
 
    :param options: The OptionParser options.
    :param check_target: Whether or not to check if --target is being used.
    z:all:zòWhen restricting platform and interpreter constraints using --python-version, --platform, --abi, or --implementation, either --no-deps must be set, or --only-binary=:all: must be set and --no-binary must not be set (or must be set to :none:).zQCan not use any platform or abi specific options unless installing via '--target'N) r8Úpython_versionÚplatformÚabiÚimplementationr Úsetr:Úignore_dependenciesr
Ú
target_dir)r(Ú check_targetÚdist_restriction_setÚ binary_onlyÚsdist_dependencies_allowedr$r$r%Úcheck_dist_restrictionZs&ü
þÿ
ÿrLcCs tj |¡Sr-)ÚosÚpathÚ
expanduser)r"ÚoptÚvaluer$r$r%Ú_path_option_check‚srRc@s(eZdZejdZej ¡Zeed<dS)Ú    PipOption)rNrNN)Ú__name__Ú
__module__Ú __qualname__rÚTYPESÚ TYPE_CHECKERÚcopyrRr$r$r$r%rS‡s
 
rSz-hz--helpÚhelpz
Show help.)ÚdestÚactionrZz
--isolatedÚ isolated_modeÚ
store_truezSRun pip in an isolated mode, ignoring environment variables and user configuration.©r[r\ÚdefaultrZz--require-virtualenvz--require-venvÚ require_venvz-vz    --verboseÚverboseÚcountzDGive more output. Option is additive, and can be used up to 3 times.z
--no-colorÚno_colorzSuppress colored outputz-Vz    --versionÚversionzShow version and exit.z-qz--quietÚquietzƒGive less output. Option is additive, and can be used up to 3 times (corresponding to WARNING, ERROR, and CRITICAL logging levels).z--progress-barÚ progress_barÚchoiceÚonz*Specify type of progress to be displayed [ú|z] (default: %default))r[ÚtypeÚchoicesr`rZz--logz
--log-filez --local-logÚlogrNz Path to a verbose appending log.)r[ÚmetavarrkrZz
--no-inputÚno_inputzDisable prompting for input.z--proxyÚproxyÚstrÚz<Specify a proxy in the form [user:passwd@]proxy.server:port.)r[rkr`rZz    --retriesÚretriesÚintézRMaximum number of retries each connection should attempt (default %default times).z    --timeoutz--default-timeoutÚsecÚtimeoutÚfloatéz2Set the socket timeout (default %default seconds).)rnr[rkr`rZc
Cs"tddddddddggd    d
d d S) Nz--exists-actionÚ exists_actionrhÚsÚiÚwÚbÚaÚappendr\zYDefault action when a path already exists: (s)witch, (i)gnore, (w)ipe, (b)ackup, (a)bort.)r[rkrlr`r\rnrZ©rr$r$r$r%rzs ÷rzz--certÚcertzPath to alternate CA bundle.)r[rkrnrZz --client-certÚ client_certzkPath to SSL client certificate, a single file containing the private key and the certificate in PEM format.)r[rkr`rnrZz-iz --index-urlz
--pypi-urlÚ    index_urlÚURLz¿Base URL of the Python Package Index (default %default). This should point to a repository compliant with PEP 503 (the simple repository API) or a local directory laid out in the same format.)r[rnr`rZcCstddddgddS)Nz--extra-index-urlÚextra_index_urlsr…r€zmExtra URLs of package indexes to use in addition to --index-url. Should follow the same rules as --index-url.)r[rnr\r`rZrr$r$r$r%Úextra_index_urlEsúr‡z
--no-indexÚno_indexzAIgnore package index (only looking at --find-links URLs instead).c    CstddddgdddS)Nz-fz --find-linksÚ
find_linksr€ÚurlaIf a URL or path to an html file, then parse for links to archives such as sdist (.tar.gz) or wheel (.whl) files. If a local path or file:// URL that's a directory,  then look for archives in the directory listing. Links to VCS project URLs are not supported.©r[r\r`rnrZrr$r$r$r%r‰]súr‰cCstddddgddS)Nz--trusted-hostÚ trusted_hostsr€ÚHOSTNAMEz]Mark this host or host:port pair as trusted, even though it does not have valid or any HTTPS.)r[r\rnr`rZrr$r$r$r%Ú trusted_hostmsúrŽc    CstddddgdddS)Nz-cz --constraintÚ constraintsr€Úfilez\Constrain versions using the given constraints file. This option can be used multiple times.r‹rr$r$r$r%rzsúrc    CstddddgdddS)Nz-rz --requirementÚ requirementsr€rzQInstall from the given requirements file. This option can be used multiple times.r‹rr$r$r$r%r‘‡súr‘c    CstddddgdddS)Nz-ez
--editableÚ    editablesr€zpath/urlzkInstall a project in editable mode (i.e. setuptools "develop mode") from a local project path or a VCS url.r‹rr$r$r$r%Úeditable”súr“cCs tj |¡}t|j|j|ƒdSr-©rMrNÚabspathÚsetattrÚvaluesr[)r"Úopt_strrQr!r$r$r%Ú _handle_src¡s r™z--srcz--sourcez --source-dirz--source-directoryÚsrc_dirÚdirÚcallbackz˜Directory to check out editable projects into. The default in a virtualenv is "<venv path>/src". The default for global installs is "<current dir>/src".)r[rkrnr`r\rœrZcCs t||jƒS)zGet a format_control object.)r.r[)r—r"r$r$r%Ú_get_format_control¶srcCs"t|j|ƒ}t ||j|j¡dSr-)rr—r Úhandle_mutual_excludesÚ    no_binaryÚ only_binary©r"r˜rQr!Úexistingr$r$r%Ú_handle_no_binary¼s  ÿr£cCs"t|j|ƒ}t ||j|j¡dSr-)rr—r ržr rŸr¡r$r$r%Ú_handle_only_binaryÄs  ÿr¤c    Cs$ttƒtƒƒ}tdddtd|ddS)Nz --no-binaryr:rœrqavDo not use binary packages. Can be supplied multiple times, and each time adds to the existing value. Accepts either ":all:" to disable all binary packages, ":none:" to empty the set (notice the colons), or one or more package names with commas between them (no colons). Note that some packages are tricky to compile and may fail to install when this option is used on them.©r[r\rœrkr`rZ)r rErr£©r:r$r$r%rŸÌsürŸc    Cs$ttƒtƒƒ}tdddtd|ddS)Nz --only-binaryr:rœrqaKDo not use source packages. Can be supplied multiple times, and each time adds to the existing value. Accepts either ":all:" to disable all source packages, ":none:" to empty the set, or one or more package names with commas between them. Packages without binary distributions will fail to install when this option is used on them.r¥)r rErr¤r¦r$r$r%r Üsür z
--platformrBz[Only use wheels compatible with <platform>. Defaults to the platform of the running system.cCsŒ|sdS| d¡}t|ƒdkr"dSt|ƒdkrV|d}t|ƒdkrV|d|dd…g}ztdd    „|Dƒƒ}Wntk
r‚Yd
SX|dfS) zÖ
    Convert a version string like "3", "37", or "3.7.3" into a tuple of ints.
 
    :return: A 2-tuple (version_info, error_msg), where `error_msg` is
        non-None if and only if there was a parsing error.
    )NNÚ.é)r$z'at most three version parts are allowedérNcss|]}t|ƒVqdSr-)rt)Ú.0Úpartr$r$r%Ú    <genexpr>sz*_convert_python_version.<locals>.<genexpr>)r$z$each version part must be an integer)rÚlenÚtupleÚ
ValueError)rQÚpartsÚ version_infor$r$r%Ú_convert_python_versionøs
   r²cCs:t|ƒ\}}|dk    r.d ||¡}t|||d||j_dS)z3
    Handle a provided --python-version value.
    Nz(invalid --python-version value: {!r}: {}©r"r#)r²rr&r—rA)r"r˜rQr!r±Ú    error_msgr#r$r$r%Ú_handle_python_versions ÿÿrµz--python-versionrAa    The Python interpreter version to use for wheel and "Requires-Python"
    compatibility checks. Defaults to a version derived from the running
    interpreter. The version can be specified using up to three dot-separated
    integers (e.g. "3" for 3.0.0, "3.7" for 3.7.0, or "3.7.3"). A major-minor
    version can also be given as a string without dots (e.g. "37" for 3.7.0).
    )r[rnr\rœrkr`rZz--implementationrDzâOnly use wheels compatible with Python implementation <implementation>, e.g. 'pp', 'jy', 'cp',  or 'ip'. If not specified, then the current interpreter implementation is used.  Use 'py' to force implementation-agnostic wheels.z--abirCzñOnly use wheels compatible with Python abi <abi>, e.g. 'pypy_41'.  If not specified, then the current interpreter abi tag is used.  Generally you will need to specify --implementation, --platform, and --python-version when using this option.cCs4| tƒ¡| tƒ¡| tƒ¡| tƒ¡dSr-)r)rBrArDrC)Úcmd_optsr$r$r%Úadd_target_python_optionsVs   r·cCst|j|j|j|jd}|S)N)rBÚpy_version_inforCrD)rrBrArCrD)r(Ú target_pythonr$r$r%Úmake_target_python^sürºcCstddddddS)Nz--prefer-binaryÚ prefer_binaryr^Fz8Prefer older binary packages over newer source packages.r_rr$r$r$r%r»jsûr»z --cache-dirÚ    cache_dirzStore the cache data in <dir>.)r[r`rnrkrZc
CsV|dk    rJz t|ƒWn4tk
rH}zt||t|ƒdW5d}~XYnXd|j_dS)z‰
    Process a value provided for the --no-cache-dir option.
 
    This is an optparse.Option callback for the --no-cache-dir option.
    Nr³F)rr¯r&rqr—r¼)r"rPrQr!Úexcr$r$r%Ú_handle_no_cache_dir€s  $    r¾z--no-cache-dirzDisable the cache.)r[r\rœrZz    --no-depsz--no-dependenciesrFz#Don't install package dependencies.cCs$|rtj |¡}t|j|j|ƒdSr-r”)r"rPrQr!r$r$r%Ú_handle_build_dir¯s r¿z-bz--buildz --build-dirz--build-directoryÚ    build_diraK(DEPRECATED) Directory to unpack packages into and build in. Note that an initial build still takes place in a temporary directory. The location of temporary directories can be controlled by setting the TMPDIR environment variable (TEMP on Windows) appropriately. When passed, build directories are not cleaned in case of failures.)r[rkrnr\rœrZz--ignore-requires-pythonÚignore_requires_pythonz'Ignore the Requires-Python information.z--no-build-isolationÚbuild_isolationÚ store_falseTz—Disable isolation when building a modern source distribution. Build dependencies specified by PEP 518 must be already installed if this option is used.cCs&|dk    rd}t|||dd|j_dS)z‰
    Process a value provided for the --no-use-pep517 option.
 
    This is an optparse.Option callback for the no_use_pep517 option.
    Na0A value was passed for --no-use-pep517,
        probably using either the PIP_NO_USE_PEP517 environment variable
        or the "no-use-pep517" config file option. Use an appropriate value
        of the PIP_USE_PEP517 environment variable or the "use-pep517"
        config file option instead.
        r³F)r&r—Ú
use_pep517)r"rPrQr!r#r$r$r%Ú_handle_no_use_pep517Ús rÅz --use-pep517rÄz^Use PEP 517 for building source distributions (use --no-use-pep517 to force legacy behaviour).z--no-use-pep517)r[r\rœr`rZz--install-optionr5r€r(a"Extra arguments to be supplied to the setup.py install command (use like --install-option="--install-scripts=/usr/local/bin"). Use multiple --install-option options to pass multiple options to setup.py install. If you are using an option with a directory path, be sure to use absolute path.)r[r\rnrZz--global-optionr4zTExtra global options to be supplied to the setup.py call before the install command.z
--no-cleanz!Don't clean up build directories.)r\r`rZz--prezYInclude pre-release and development versions. By default, pip only finds stable versions.z--disable-pip-version-checkÚdisable_pip_version_checkz{Don't periodically check PyPI to determine whether a new version of pip is available for download. Implied with --no-index.cCs„|jjsi|j_z| dd¡\}}Wn$tk
rH| d |¡¡YnX|tkrj| d |d t¡¡¡|jj |g¡     |¡dS)zkGiven a value spelled "algo:digest", append the digest to a list
    pointed to in a dict by the algo name.ú:r©zTArguments to {} must be a hash name followed by a value, like --hash=sha256:abcde...z&Allowed hash algorithms for {} are {}.z, N)
r—Úhashesrr¯r rrrÚ
setdefaultr€)r"r˜rQr!ÚalgoÚdigestr$r$r%Ú_handle_merge_hash9sþ ÿrÌz--hashrÈÚstringzgVerify that the package's archive matches this hash before installing. Example: --hash=sha256:abcdef...)r[r\rœrkrZz--require-hashesÚrequire_hasheszžRequire a hash to check each requirement against, for repeatable installs. This option is implied when any package in a requirements file has a --hash option.z--pathz^Restrict to the specified installation path for listing packages (can be used multiple times).)r[rkr\rZcCs|jr|js|jrtdƒ‚dS)Nz2Cannot combine '--path' with '--user' or '--local')rNÚuserÚlocalr
)r(r$r$r%Úcheck_list_path_optionpsÿrÑz--no-python-version-warningÚno_python_version_warningz>Silence deprecation warnings for upcoming unsupported Pythons.z--unstable-featureÚunstable_featuresÚfeatureÚresolver)r[rnr\r`rlrZz --use-featureÚfeatures_enabledz 2020-resolverz    fast-depsz<Enable new functionality, that may be backward incompatible.z--use-deprecatedÚdeprecated_features_enabledzDEnable deprecated functionality, that will be removed in the future.zGeneral Options)r'r(zPackage Index Options)N)F)wÚ__doc__Ú
__future__rrMrr<Údistutils.utilrÚ    functoolsrÚoptparserrrrÚpip._internal.cli.progress_barsr    Úpip._internal.exceptionsr
Úpip._internal.locationsr r Ú#pip._internal.models.format_controlr Úpip._internal.models.indexrÚ"pip._internal.models.target_pythonrÚpip._internal.utils.hashesrÚpip._internal.utils.typingrÚtypingrrrrrrrÚpip._internal.cli.parserrr&r,r@rLrRrSÚhelp_r]Úrequire_virtualenvrbrdrerfÚlistÚkeysrrgrmrorprsrwrzr‚rƒÚ
simple_urlr„r‡rˆr‰rŽrr‘r“r™Úsrcrr£r¤rŸr rBr²rµrArDrCr·rºr»r¼r¾Úno_cacheÚno_depsr¿rÀrÁÚno_build_isolationrÅrÄÚ no_use_pep517r5r4Úno_cleanÚprerÆrÌÚhashrÎÚ    list_pathrÑrÒÚunstable_featureÚuse_new_featureÚuse_deprecated_featureÚ general_groupÚ index_groupr$r$r$r%Ú<module>sŒ              (
ûù ù
ú    ú    ûù 
 ÿÿø ú    ù
ú    ú
ù ú    ù ú ú
    ÷ú øúú  ù ú    ú
øûú ú
ù
ú ú
ûû    ú ÷ú ú ú
ø ø ÷éþüþ