Skip to content

Commit 25c3f98

Browse files
author
longendu
committed
format code
1 parent 9b8e4a5 commit 25c3f98

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

aiutil/filesystem.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/usr/bin/env python3
22
"""Filesystem related util functions."""
3+
34
from collections import namedtuple
45
from typing import Iterable, Callable
56
import itertools
@@ -702,9 +703,10 @@ def trace_dir_upwards(path: str | Path, name: str) -> PosixPathPair:
702703
name: The base name (stem) of the parent directory.
703704
704705
Returns:
705-
A PosixPathPair which contains the parent directory
706+
A PosixPathPair which contains the parent directory
706707
and the relative path to this parent directory.
707708
"""
709+
708710
def _trace_dir_upwards(path: Path) -> Path:
709711
while (stem := path.stem) != name:
710712
if not stem:
@@ -716,4 +718,3 @@ def _trace_dir_upwards(path: Path) -> Path:
716718
path = Path(path)
717719
prefix = _trace_dir_upwards(path)
718720
return PosixPathPair(prefix, path.relative_to(prefix))
719-

0 commit comments

Comments
 (0)