Skip to content

Commit

Permalink
fix: download all the directory failed
Browse files Browse the repository at this point in the history
  • Loading branch information
brosoul committed Dec 9, 2024
1 parent a5824d1 commit 5b2f729
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion python/aibrix/aibrix/downloader/s3.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,9 @@ def _directory_list(self, path: str) -> List[str]:
Bucket=self.bucket_name, Delimiter="/", Prefix=path
)
contents = objects_out.get("Contents", [])
return [content.get("Key") for content in contents]
files = [content.get("Key") for content in contents]
# filter the directory path
return [file for file in files if not file.endswith("/")]

def _support_range_download(self) -> bool:
return True
Expand Down

0 comments on commit 5b2f729

Please sign in to comment.