Skip to content

Commit

Permalink
Fix issue Netflix#1805
Browse files Browse the repository at this point in the history
  • Loading branch information
narayanacharya6 committed Apr 19, 2024
1 parent 5908c4e commit 9930a64
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions metaflow/plugins/datatools/s3/s3.py
Original file line number Diff line number Diff line change
Expand Up @@ -1245,12 +1245,12 @@ def put_many(

def _store():
for key_obj in key_objs:
if isinstance(key_obj, tuple):
key = key_obj[0]
obj = key_obj[1]
else:
if isinstance(key_obj, S3PutObject):
key = key_obj.key
obj = key_obj.value
else:
key = key_obj[0]
obj = key_obj[1]
store_info = {
"key": key,
"content_type": getattr(key_obj, "content_type", None),
Expand Down Expand Up @@ -1319,12 +1319,12 @@ def put_files(

def _check():
for key_path in key_paths:
if isinstance(key_path, tuple):
key = key_path[0]
path = key_path[1]
else:
if isinstance(key_path, S3PutObject):
key = key_path.key
path = key_path.path
else:
key = key_path[0]
path = key_path[1]
store_info = {
"key": key,
"content_type": getattr(key_path, "content_type", None),
Expand Down

0 comments on commit 9930a64

Please sign in to comment.