Skip to content

Commit 32fa215

Browse files
authored
Merge pull request #851 from takluyver/core-metadata-email-fmt
Describe the file format of core metadata
2 parents 9b13d8e + cf27970 commit 32fa215

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

‎source/specifications/core-metadata.rst‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,20 @@ complete and not subject to change. The required fields are:
1313

1414
All the other fields are optional.
1515

16+
The standard file format for metadata (including in :doc:`wheels
17+
<binary-distribution-format>` and :doc:`installed projects
18+
<recording-installed-packages>`) is based on the format of email headers.
19+
However, email formats have been revised several times, and exactly which email
20+
RFC applies to packaging metadata is not specified. In the absence of a precise
21+
definition, the practical standard is set by what the standard library
22+
:mod:`python:email.parser` module can parse using the
23+
:data:`~.python:email.policy.compat32` policy.
24+
25+
Although :pep:`566` defined a way to transform metadata into a JSON-compatible
26+
dictionary, this is not yet used as a standard interchange format. The need for
27+
tools to work with years worth of existing packages makes it difficult to shift
28+
to a new format.
29+
1630
.. note:: *Interpreting old metadata:* In :pep:`566`, the version specifier
1731
field format specification was relaxed to accept the syntax used by popular
1832
publishing tools (namely to remove the requirement that version specifiers

0 commit comments

Comments
 (0)