Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions importlib_metadata/_meta.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,11 @@ class SimplePath(Protocol):
"""

def joinpath(
self, other: str | os.PathLike[str]
self, other: str | os.PathLike[str], /
) -> SimplePath: ... # pragma: no cover

def __truediv__(
self, other: str | os.PathLike[str]
self, other: str | os.PathLike[str], /
) -> SimplePath: ... # pragma: no cover

@property
Expand Down
1 change: 1 addition & 0 deletions newsfragments/542.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Marked the ``other`` parameter of ``SimplePath.joinpath`` and ``SimplePath.__truediv__`` positional-only, so ``pathlib.Path`` satisfies the protocol under type checkers that compare parameter names.