Skip to content

Commit 62f7e19

Browse files
authored
PEP 751: mention dependency groups for services to look for (#4290)
1 parent 66228e5 commit 62f7e19

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

peps/pep-0751.rst

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -135,11 +135,17 @@ e.g.:
135135
if len(filename) > 11 and filename.startswith("pylock.") and filename.endswith(".toml"):
136136
name = filename.removeprefix("pylock.").removesuffix(".toml")
137137
138-
The expectation is that services that install lock files automatically will
139-
search for a lock file with the service's name, then fallback to the generic
140-
``pylock.toml`` (e.g. a cloud host service named Spam would first look for
141-
``pylock.spam.toml`` to install, and if that file didn't exist then install from
142-
``pylock.toml``).
138+
The expectation is that services that automatically install from lock files will
139+
search for:
140+
141+
1. The lock file with the service's name and doing the default install
142+
2. A multi-use ``pylock.toml`` with a dependency group with the name of the service
143+
3. The default install of ``pylock.toml``
144+
145+
E.g. a cloud host service named "spam" would first look for
146+
``pylock.spam.toml`` to install from, and if that file didn't exist then install
147+
from ``pylock.toml`` and look for a dependency group named "spam" fo use if
148+
present.
143149

144150
The lock file(s) SHOULD be located in the directory as appropriate for the scope
145151
of the lock file. Locking against a single ``pyproject.toml``, for instance,

0 commit comments

Comments
 (0)