diff --git a/CITATION.cff b/CITATION.cff index b4bdf50d9..5cb6bbdda 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -11,7 +11,7 @@ authors: given-names: Miquel orcid: https://orcid.org/0000-0002-9906-6936 title: 'Ersilia Model Hub: a repository of AI/ML models for neglected tropical diseases' -version: 0.1.38 +version: 0.1.39 doi: 10.5281/zenodo.7274645 date-released: '' url: https://github.com/ersilia-os/ersilia diff --git a/codemeta.json b/codemeta.json index 7e9f6a7f7..9cf7bc1e8 100644 --- a/codemeta.json +++ b/codemeta.json @@ -28,7 +28,7 @@ "givenName": "Miquel" } ], - "codeRepository": "https://github.com/ersilia-os/ersilia/v0.1.38", + "codeRepository": "https://github.com/ersilia-os/ersilia/v0.1.39", "dateCreated": "2021-01-01", "dateModified": "2024-10-01", "datePublished": "2022-10-06", @@ -221,7 +221,7 @@ ], "url": "https://ersilia.io", "downloadUrl": "https://github.com/ersilia-os/ersilia/archive/refs/tags/v0.1.37.tar.gz", - "version": "0.1.38", + "version": "0.1.39", "relatedLink": "https://ersilia.gitbook.io", "developmentStatus": "active", "issueTracker": "https://github.com/ersilia-os/ersilia/issues" diff --git a/ersilia/_static_version.py b/ersilia/_static_version.py index 1640d7908..43dcc4d90 100644 --- a/ersilia/_static_version.py +++ b/ersilia/_static_version.py @@ -1 +1 @@ -version = "0.1.38" +version = "0.1.39" diff --git a/ersilia/serve/standard_api.py b/ersilia/serve/standard_api.py index 9cddc33ef..3a98a27ed 100644 --- a/ersilia/serve/standard_api.py +++ b/ersilia/serve/standard_api.py @@ -263,21 +263,17 @@ def is_amenable(self, output_data): return True def serialize_to_csv(self, input_data, result, output_data): - k = list(result[0].keys())[0] - v = result[0][k] - if type(v) is list: - is_list = True - else: - is_list = False with open(output_data, "w") as f: writer = csv.writer(f) writer.writerow(self.header) for i_d, r_d in zip(input_data, result): - v = r_d[k] - if not is_list: - r = [i_d["key"], i_d["input"]] + [v] - else: - r = [i_d["key"], i_d["input"]] + v + r = [i_d["key"], i_d["input"]] + for k in self.header[2:]: + v = r_d[k] + if isinstance(v, list): + r+=v + else: + r+=[v] writer.writerow(r) return output_data diff --git a/pyproject.toml b/pyproject.toml index d82e20077..b1896fa66 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "ersilia" -version = "0.1.38" +version = "0.1.39" description = "A hub of AI/ML models for open source drug discovery and global health" license = "GPLv3" authors = ["Ersilia Open Source Initiative "] @@ -51,7 +51,7 @@ boto3 = "^1.28.40" requests = "^2.31.0" numpy = "<=1.26.4" setuptools = "^70.0.0" # added to fix the issue with setuptools -isaura = { version = "0.1", optional = true } +isaura = { version = "0.1.39", optional = true } aiofiles = "<=24.1.0" aiohttp = ">=3.10.11" nest_asyncio = "<=1.6.0"