Skip to content

Commit 37b0da7

Browse files
ponyisiCopilot
andcommitted
Protect Contents retrieval
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 2f3fa85 commit 37b0da7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

servicex/minio_adapter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ async def list_bucket(self) -> List[ResultFile]:
9999
size=_["Size"],
100100
extension=_["Key"].split(".")[-1],
101101
)
102-
for _ in listing["Contents"]
102+
for _ in listing.get("Contents", [])
103103
if not _["Key"].endswith("/")
104104
]
105105
return rv

0 commit comments

Comments
 (0)