Skip to content

Commit ace5183

Browse files
authored
Merge pull request #1901 from pfmoore/dynamic_clarification
Clarify that the Dynamic metadata field only applies when building from sdist
2 parents f99923a + a1842f5 commit ace5183

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

source/specifications/core-metadata.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,16 @@ only, and indicates that the field value was calculated at wheel build time,
133133
and may not be the same as the value in the sdist or in other wheels for the
134134
project.
135135

136+
Note in particular that if you have obtained a prebuilt wheel, you cannot
137+
assume that a field which is not marked as ``Dynamic`` will have the same value
138+
in other wheels, as some wheels are not built directly from the sdist, but are
139+
modified from existing wheels (the ``auditwheel`` tool does this, for example,
140+
and it's commonly used when building wheels for PyPI). Such modifications
141+
*could* include changing metadata (even non-dynamic metadata). Similarly, if
142+
you have a sdist and a wheel which you didn't build from that sdist, you cannot
143+
assume that the wheel's metadata matches that of the sdist, even if the field
144+
is not marked as ``Dynamic``.
145+
136146
Full details of the semantics of ``Dynamic`` are described in :pep:`643`.
137147

138148
.. _core-metadata-platform:
@@ -923,6 +933,10 @@ Example::
923933
History
924934
=======
925935

936+
- August 2025: Clarified that ``Dynamic`` only affects how fields
937+
must be treated when building a wheel from a sdist, not when modifying
938+
a wheel.
939+
926940
- August 2024: Core metadata 2.4 was approved through :pep:`639`.
927941

928942
- Added the ``License-Expression`` field.

0 commit comments

Comments
 (0)