Skip to content

Commit

Permalink
add autorelease
Browse files Browse the repository at this point in the history
  • Loading branch information
jerowe committed Feb 22, 2024
1 parent f2d3810 commit 0aafc5a
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions bioanalyze_omics/resources/runs.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,22 @@ def __init__(self, client=None):
self.omics_client = client

def format_run(self, run: Dict, cost: Any) -> Dict:
run["resourceDigests"] = json.dumps(cost["run"]["resourceDigests"])
run["tags"] = str(json.dumps(cost["run"]["tags"]))
run["parameters"] = json.dumps(cost["run"]["parameters"])
run["logLocation"] = run["logLocation"]["runLogStream"]
if "resourceDigests" in cost['run']:
run["resourceDigests"] = json.dumps(cost["run"]["resourceDigests"])
else:
run["resourceDigests"] = {}
if "tags" in run:
run["tags"] = str(json.dumps(cost["run"]["tags"]))
else:
run["tags"] = ""
if "parameters" in run:
run["parameters"] = json.dumps(cost["run"]["parameters"])
else:
run["parameters"] = {}
if "logLocation" in run and "runLogStream" in run['logLocation']:
run["logLocation"] = run["logLocation"]["runLogStream"]
else:
run["logLocation"] = ""
del run["tasks"]
run_columns = run.keys()
run_values = run.values()
Expand Down

0 comments on commit 0aafc5a

Please sign in to comment.