Skip to content

Commit

Permalink
fix: create parent folders for file index
Browse files Browse the repository at this point in the history
  • Loading branch information
steveoh committed Feb 7, 2023
1 parent 1cbf0ed commit bcc7d29
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions row.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ def get_files_from_index(from_location, task_index, task_count, total_size):
bucket = storage_client.bucket(from_location[5:])
blob = bucket.blob("index.txt")

if not index.parent.exists():
index.parent.mkdir(parents=True)

try:
blob.download_to_filename(str(index))
except Exception as ex:
Expand Down

0 comments on commit bcc7d29

Please sign in to comment.