PEP 610: add canonical URL and minor clarification (#1283)

This commit is contained in:
Stéphane Bidoul 2020-01-26 14:29:59 +01:00 committed by Nick Coghlan
parent d6fa383389
commit bf9d3a51cc
1 changed files with 6 additions and 2 deletions

View File

@ -184,6 +184,9 @@ Specification
This PEP specifies a ``direct_url.json`` file in the ``.dist-info`` directory
of an installed distribution, to record the Direct URL Origin of the distribution.
The canonical source for the name and semantics of this metadata file is
the `Recording the Direct URL Origin of installed distributions`_ document.
This file MUST be created by installers when installing a distribution
from a requirement specifying a direct URL reference (including a VCS URL).
@ -251,12 +254,12 @@ present as a dictionary with the following key:
When ``url`` refers to a local directory, it MUST have the ``file`` sheme
and be compliant with `RFC 8089`_. In particular, the path component must
be absolute. Symbolic links SHOULD be preserved when make relative
be absolute. Symbolic links SHOULD be preserved when making relative
paths absolute.
.. note::
When the requested URL points to a local directory that happens to contain a
When the requested URL has the file:// scheme and points to a local directory that happens to contain a
VCS checkout, installers MUST NOT attempt to infer any VCS information and
therefore MUST NOT output any VCS related information (such as ``vcs_info``)
in ``direct_url.json``.
@ -532,6 +535,7 @@ References
.. _`environment variables in the user:password part of URLs`: https://pip.pypa.io/en/stable/reference/pip_install/#id10
.. _`RFC 8259`: https://tools.ietf.org/html/rfc8259
.. _`RFC 8089`: https://tools.ietf.org/html/rfc8089
.. _`Recording the Direct URL Origin of installed distributions`: https://packaging.python.org/specifications/direct-url
Acknowledgements
================