Skip to content

Commit 9eede71

Browse files
authored
build: add editable to dist type (#764)
* build: add `editable` to dist type Closes #763. * Merge literals
1 parent 1e67c06 commit 9eede71

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

src/build/_builder.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,11 @@ def build_system_requires(self) -> set[str]:
203203
"""
204204
return set(self._build_system['requires'])
205205

206-
def get_requires_for_build(self, distribution: Distribution, config_settings: ConfigSettings | None = None) -> set[str]:
206+
def get_requires_for_build(
207+
self,
208+
distribution: Distribution,
209+
config_settings: ConfigSettings | None = None,
210+
) -> set[str]:
207211
"""
208212
Return the dependencies defined by the backend in addition to
209213
:attr:`build_system_requires` for a given distribution.
@@ -220,7 +224,9 @@ def get_requires_for_build(self, distribution: Distribution, config_settings: Co
220224
return set(get_requires(config_settings))
221225

222226
def check_dependencies(
223-
self, distribution: Distribution, config_settings: ConfigSettings | None = None
227+
self,
228+
distribution: Distribution,
229+
config_settings: ConfigSettings | None = None,
224230
) -> set[tuple[str, ...]]:
225231
"""
226232
Return the dependencies which are not satisfied from the combined set of

src/build/_types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66

77
ConfigSettings = typing.Mapping[str, typing.Union[str, typing.Sequence[str]]]
8-
Distribution = typing.Literal['sdist', 'wheel']
8+
Distribution = typing.Literal['sdist', 'wheel', 'editable']
99
StrPath = typing.Union[str, 'os.PathLike[str]']
1010
SubprocessRunner = typing.Callable[
1111
[typing.Sequence[str], typing.Optional[str], typing.Optional[typing.Mapping[str, str]]], None

0 commit comments

Comments
 (0)