Skip to content

Commit 9bcc557

Browse files
authored
PEP 627: Remove REQUESTED from the spec (GH-1575)
* Fix typo * Remove REQUESTED from the spec
1 parent 9e884d2 commit 9bcc557

File tree

1 file changed

+16
-15
lines changed

1 file changed

+16
-15
lines changed

pep-0627.rst

+16-15
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ except for ``*.pyc`` and ``RECORD`` itself.
136136
(Note that PEP 376 is unclear on what was optional; when taken literally,
137137
its text and examples contradict. Despite that, “both fields are optional“ is a
138138
reasonable interpretation of PEP 376.
139-
The alternative would be to mandate—rather rhan recommend—which files can be
139+
The alternative would be to mandate—rather than recommend—which files can be
140140
recorded without hash and size, and to update that list over time as new use
141141
cases come up.)
142142

@@ -204,21 +204,21 @@ any ASCII string in ``INSTALLER``, rather than a lowercase identifier.
204204
It also suggests using the command-line command, if available.
205205

206206

207-
The ``REQUESTED`` File
208-
----------------------
207+
The ``REQUESTED`` File: Removed from Spec
208+
-----------------------------------------
209209

210-
The ``REQUESTED`` file is kept in the specification, with only tool-specific
211-
notes removed.
210+
The ``REQUESTED`` file is now considered a tool-specific extension.
212211

213-
It is made clear that while ``REQUESTED`` is optional, tools must handle it:
214-
it can only be omitted only if it is known that a user did not request
215-
installation directly.
212+
Per :pep:`376`, ``REQUESTED`` was to be written when a project was installed
213+
by direct user request, as opposed to automatically to satisfy dependencies
214+
of another project. Projects without this marker file could be uninstalled
215+
when no longer needed.
216216

217-
Note that tools that do not create this file effectively mark all installed
218-
projects as “removable unless needed by another project”.
219-
This was was the case with ``pip`` before version 20.2.
220-
Before ``REQUESTED`` becomes commonplace, automatically uninstalling “orphaned”
221-
projects should be done with care.
217+
Despite the standard, many existing installers (including older versions of
218+
``pip``) never write this file. There is no distinction between projects
219+
that are “OK to remove when no longer needed” and ones simply installed by
220+
a tool that ignores ``REQUESTED``. So, the file is currently not usable for its
221+
intended purpose (unless a tool can use additional, non-standard information).
222222

223223

224224
Clarifications
@@ -236,8 +236,9 @@ future PEPs:
236236

237237
* Encoding of the ``RECORD`` file
238238
* Limiting or namespacing files that can appear in ``.dist-info``
239-
* Marking the difference between projects installed by a tool that does not
240-
support the ``REQUESTED`` file and projects installed as dependencies
239+
* Marking the difference between projects installed directly by user request
240+
versus those installed to satisfy dependencies, so that the latter can be
241+
removed when no longer needed.
241242

242243

243244
Copyright

0 commit comments

Comments
 (0)