Skip to content

Commit b3711dc

Browse files
committed
PEP 808: how to teach update
Signed-off-by: Henry Schreiner <henryfs@princeton.edu>
1 parent edbdf98 commit b3711dc

File tree

1 file changed

+17
-10
lines changed

1 file changed

+17
-10
lines changed

peps/pep-0808.rst

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ Abstract
1717
========
1818

1919
This PEP relaxes the constraint on dynamic metadata listed in the ``[project]``
20-
section in ``pyproject.toml`` to allow the static portion of mixed metadata to
21-
be defined in the normal location if the field is a table or array by having
22-
the dynamic fields extend the static ones.
20+
section in ``pyproject.toml`` to allow a static portion of mixed metadata to be
21+
defined in the normal location if the field is a table or array by having the
22+
dynamic fields extend the static ones.
2323

2424
This allows users to opt into allowing a backend to extend metadata while still
2525
keeping the static portions of the metadata defined in the standard location in
@@ -295,19 +295,26 @@ a static component to existing dynamic metadata support.
295295
How to Teach This
296296
=================
297297

298+
If you currently have dynamic metadata, but some list or table entries are
299+
known statically, you can now make that explicit by adding them to the
300+
corresponding static entry in the project table, while keeping the entry in the
301+
``project.dynamic`` list to allow the dynamic portion to be added by your build
302+
backend.
303+
298304
The current guides that state metadata must not be listed in both ``[project]``
299-
and ``project.dynamic`` can be updated to say that some fields can be extended
300-
by ``project.dynamic``. Since dynamic metadata is already an advanced concept,
301-
this will likely not affect most existing tutorial material aimed at
302-
introductory packaging.
305+
and ``project.dynamic`` can be updated to say that lists and tables marked with
306+
``project.dynamic`` can still have static entries. Since dynamic metadata is
307+
already an advanced concept, this will likely not affect most existing tutorial
308+
material aimed at introductory packaging.
303309

304310
The ``pyproject.toml`` `specification <pyprojectspec>`__ will be updated to
305311
include the behavior of fields when specified and also listed in the dynamic
306312
field.
307313

308-
It should also be noted that specifying something in dynamic will require any
309-
tool that requires the full metadata to invoke the backend even if it is
310-
partially statically specified, so it should not be used unless necessary.
314+
It should also be noted that specifying something in ``dynamic`` will require
315+
any tool that requires the full metadata to invoke the backend even if it is
316+
partially statically specified, so it should not be used unless necessary, just
317+
like any other dynamic metadata.
311318

312319

313320
Rejected Ideas

0 commit comments

Comments
 (0)