Skip to content

Commit 8901a01

Browse files
author
Varun Shenoy
authored
do not cache s3 folders, only files (#730)
1 parent 5de969c commit 8901a01

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

truss/contexts/image_builder/serving_image_builder.py

+4
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,11 @@ def list_files(self, revision=None):
157157

158158
all_objects = []
159159
for blob in bucket.objects.filter(Prefix=path):
160+
# leave out folders
161+
if blob.key[-1] == "/":
162+
continue
160163
all_objects.append(blob.key)
164+
161165
return all_objects
162166

163167
def prepare_for_cache(self, filenames):

0 commit comments

Comments
 (0)