From 7f8ecde69e17db5598b44d5126a3bd4e553e4b1c Mon Sep 17 00:00:00 2001 From: Runar Ask Johannessen Date: Fri, 10 Nov 2023 13:02:08 +0100 Subject: [PATCH] unpack upload times correctly --- src/fmu/sumo/uploader/_sumocase.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/fmu/sumo/uploader/_sumocase.py b/src/fmu/sumo/uploader/_sumocase.py index a319778..82bb8a4 100644 --- a/src/fmu/sumo/uploader/_sumocase.py +++ b/src/fmu/sumo/uploader/_sumocase.py @@ -227,8 +227,10 @@ def _calculate_upload_stats(uploads): Given a list of results from file upload, calculate and return timing statistics for uploads.""" - blob_upload_times = uploads["blob_upload_time_elapsed"] - metadata_upload_times = uploads["metadata_upload_time_elapsed"] + blob_upload_times = [u["blob_upload_time_elapsed"] for u in uploads] + metadata_upload_times = [ + u["metadata_upload_time_elapsed"] for u in uploads + ] def _get_stats(values): return {