Skip to content

Commit e9ad012

Browse files
committed
Fix bug in fsspec store delete_dir.
Closes #2917
1 parent 5968fc7 commit e9ad012

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

changes/2918.bugfix.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix bug with `FsspecStore.delete_dir` (:issue:`2917`)

src/zarr/storage/_fsspec.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ async def delete_dir(self, prefix: str) -> None:
298298
path_to_delete = _dereference_path(self.path, prefix)
299299

300300
with suppress(*self.allowed_exceptions):
301-
await self.fs._rm(path_to_delete, recursive=True)
301+
await self.fs._rm(path_to_delete + "/", recursive=True)
302302

303303
async def exists(self, key: str) -> bool:
304304
# docstring inherited

0 commit comments

Comments
 (0)