Skip to content

Commit f238ab3

Browse files
lucmosLuca Moschella
authored andcommitted
Assume empty prefix indicates the root
1 parent 8ac5270 commit f238ab3

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

fsspec/implementations/prefix.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,11 @@ def __init__(
1717
**storage_options,
1818
) -> None:
1919
super().__init__(*args, **storage_options)
20-
self.prefix = prefix
20+
self.prefix = stringify_path(prefix)
21+
22+
if not self.prefix:
23+
self.prefix = self.sep
24+
2125
self.filesystem = filesystem
2226

2327
def _add_fs_prefix(self, path: Union[str, Path]) -> Union[str, Sequence[str]]:

0 commit comments

Comments
 (0)