Skip to content
Merged
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
2 changes: 1 addition & 1 deletion src/datasets/download/streaming_download_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -545,7 +545,7 @@ def xlistdir(path: str, download_config: Optional[DownloadConfig] = None) -> Lis
if inner_path.strip("/") and not fs.isdir(inner_path):
raise FileNotFoundError(f"Directory doesn't exist: {path}")
objects = fs.listdir(inner_path)
return [os.path.basename(obj["name"]) for obj in objects]
return [os.path.basename(obj["name"].strip("/")) for obj in objects]


def xglob(urlpath, *, recursive=False, download_config: Optional[DownloadConfig] = None):
Expand Down