Skip to content
Snippets Groups Projects
Commit 75baedb4 authored by Nathan Bockisch's avatar Nathan Bockisch
Browse files

Just kidding, turns out it's a list of tuples

parent 9f1ef11b
No related branches found
No related tags found
2 merge requests!1605Merge 2.8.2.3 work to main,!1514Just kidding, turns out it's a list of tuples
Pipeline #12770 passed
......@@ -436,7 +436,8 @@ class WrestWorkflowMetadata:
data = cursor.fetchall()
if data:
# This should have all the ancillary and science product names
make_json = json.dumps({"filesList": sum(data, [])})
# It returns from the query as a list of tuples, so it must be flattened
make_json = json.dumps({"filesList": list(sum(data, ()))})
else:
self.logger.error(f"ERROR: Failed to fetch products from product ID {product_group_id}")
else:
......
......@@ -901,3 +901,4 @@ def main(global_config, **settings):
config.add_tween("workflow.server.prometheus_route_timing_factory")
return config.make_wsgi_app()
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment