PEP 665: address review feedback

This commit is contained in:
Brett Cannon 2021-12-20 14:10:15 -08:00
parent ec3ac5bf29
commit 79cddd5639
1 changed files with 39 additions and 11 deletions

View File

@ -407,11 +407,13 @@ executions.
This field is **required**. This field is **required**.
A string representing the name of the file as represented by an entry A string representing the base name of the file as represented by an
in the array. This field is required to simplify installers as the entry in the array (i.e. what
file name is required to resolve wheel tags derived from the file ``os.path.basename()``/``pathlib.PurePath.name`` represents). This
name. It also guarantees that the association of the array entry to field is required to simplify installers as the file name is required
the file it is meant for is always clear. to resolve wheel tags derived from the file name. It also guarantees
that the association of the array entry to the file it is meant for is
always clear.
``[package._name_._version_.hashes]`` ``[package._name_._version_.hashes]``
@ -435,8 +437,10 @@ specified hashes.
A string representing a URL where to get the file. A string representing a URL where to get the file.
The installer MAY support any schemes it wants for URLs The installer MAY support any schemes it wants for URLs. A URL with no
(e.g. ``file:`` as well as ``https:``). scheme MUST be assumed to be a local file path (both relative paths to
the lock file and absolute paths). Installers MUST support, at
minumum, HTTPS URLs as well as local file paths.
An installer MAY choose to not use the URL to retrieve a file An installer MAY choose to not use the URL to retrieve a file
if a file matching the specified hash can be found using alternative if a file matching the specified hash can be found using alternative
@ -483,8 +487,9 @@ Example
# Tool-specific table. # Tool-specific table.
[metadata] [metadata]
requires = ["mousebender"] requires = ["mousebender", "coveragepy[toml]"]
requires-python = ">=3.6" marker = "sys_platform == 'linux'" # As an example for coverage.
requires-python = ">=3.7"
[[package.attrs."21.2.0"]] [[package.attrs."21.2.0"]]
filename = "attrs-21.2.0-py2.py3-none-any.whl" filename = "attrs-21.2.0-py2.py3-none-any.whl"
@ -496,11 +501,28 @@ Example
# If attrs had another wheel file (e.g. that was platform-specific), # If attrs had another wheel file (e.g. that was platform-specific),
# it could be listed here. # it could be listed here.
[[package."coveragepy[toml]"."6.2.0"]]
filename = "coverage-6.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl"
hashes.sha256 = "c7912d1526299cb04c88288e148c6c87c0df600eca76efd99d84396cfe00ef1d"
url = "https://files.pythonhosted.org/packages/da/64/468ca923e837285bd0b0a60bd9a287945d6b68e325705b66b368c07518b1/coverage-6.2-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl"
requires-python = ">=3.6"
requires = ["tomli"]
[[package."coveragepy[toml]"."6.2.0"]]
filename = "coverage-6.2-cp310-cp310-musllinux_1_1_x86_64.whl "
hashes.sha256 = "276651978c94a8c5672ea60a2656e95a3cce2a3f31e9fb2d5ebd4c215d095840"
url = "https://files.pythonhosted.org/packages/17/d6/a29f2cccacf2315150c31d8685b4842a6e7609279939a478725219794355/coverage-6.2-cp310-cp310-musllinux_1_1_x86_64.whl"
requires-python = ">=3.6"
requires = ["tomli"]
# More wheel files for `coverage` could be listed for more
# extensive support (i.e. all Linux-based wheels).
[[package.mousebender."2.0.0"]] [[package.mousebender."2.0.0"]]
filename = "mousebender-2.0.0-py3-none-any.whl" filename = "mousebender-2.0.0-py3-none-any.whl"
hashes.sha256 = "a6f9adfbd17bfb0e6bb5de9a27083e01dfb86ed9c3861e04143d9fd6db373f7c" hashes.sha256 = "a6f9adfbd17bfb0e6bb5de9a27083e01dfb86ed9c3861e04143d9fd6db373f7c"
url = "https://files.pythonhosted.org/packages/f4/b3/f6fdbff6395e9b77b5619160180489410fb2f42f41272994353e7ecf5bdf/mousebender-2.0.0-py3-none-any.whl" url = "https://files.pythonhosted.org/packages/f4/b3/f6fdbff6395e9b77b5619160180489410fb2f42f41272994353e7ecf5bdf/mousebender-2.0.0-py3-none-any.whl"
required-python = ">=3.6" requires-python = ">=3.6"
requires = ["attrs", "packaging"] requires = ["attrs", "packaging"]
[[package.packaging."20.9"]] [[package.packaging."20.9"]]
@ -513,11 +535,17 @@ Example
[[package.pyparsing."2.4.7"]] [[package.pyparsing."2.4.7"]]
filename = "pyparsing-2.4.7-py2.py3-none-any.whl" filename = "pyparsing-2.4.7-py2.py3-none-any.whl"
hashes.sha256="ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b" hashes.sha256 = "ef9d7589ef3c200abe66653d3f1ab1033c3c419ae9b9bdb1240a85b024efc88b"
url = "https://files.pythonhosted.org/packages/8a/bb/488841f56197b13700afd5658fc279a2025a39e22449b7cf29864669b15d/pyparsing-2.4.7-py2.py3-none-any.whl" url = "https://files.pythonhosted.org/packages/8a/bb/488841f56197b13700afd5658fc279a2025a39e22449b7cf29864669b15d/pyparsing-2.4.7-py2.py3-none-any.whl"
direct = true # For demonstration purposes. direct = true # For demonstration purposes.
requires-python = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" requires-python = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*"
[[package.tomli."2.0.0"]]
filename = "tomli-2.0.0-py3-none-any.whl"
hashes.sha256 = "b5bde28da1fed24b9bd1d4d2b8cba62300bfb4ec9a6187a957e8ddb9434c5224"
url = "https://files.pythonhosted.org/packages/e2/9f/5e1557a57a7282f066351086e78f87289a3446c47b2cb5b8b2f614d8fe99/tomli-2.0.0-py3-none-any.whl"
requires-python = ">=3.7"
------------------------ ------------------------
Expectations for Lockers Expectations for Lockers