Unverified Commit 5e5630a4 authored by omer-dayan's avatar omer-dayan Committed by GitHub
Browse files

[Bugfix] Path join when building local path for S3 clone (#12353)


Signed-off-by: default avatarOmer Dayan (SW-GPU) <omer@run.ai>
parent d3d6bb13
...@@ -145,7 +145,8 @@ class S3Model: ...@@ -145,7 +145,8 @@ class S3Model:
return return
for file in files: for file in files:
destination_file = self.dir + file.removeprefix(base_dir) destination_file = os.path.join(self.dir,
file.removeprefix(base_dir))
local_dir = Path(destination_file).parent local_dir = Path(destination_file).parent
os.makedirs(local_dir, exist_ok=True) os.makedirs(local_dir, exist_ok=True)
self.s3.download_file(bucket_name, file, destination_file) self.s3.download_file(bucket_name, file, destination_file)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment