Skip to content

Commit 70b5953

Browse files
committed
Fix typecheck in github actions
1 parent c060d3b commit 70b5953

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/pathseq/_base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ def relative_to(self, other: Segment) -> Self:
268268
if other == str(self):
269269
raise ValueError("Cannot make a path sequence relative to itself")
270270

271-
return type(self)(self._path.relative_to(other))
271+
return self.with_segments(self._path.relative_to(other))
272272

273273
def with_name(self, name: str) -> Self:
274274
"""Return a new sequence with the :attr:`~.name` changed.

0 commit comments

Comments
 (0)