diff options
author | Alexander Kabui | 2021-09-23 16:05:17 +0300 |
---|---|---|
committer | Alexander Kabui | 2021-09-23 16:05:17 +0300 |
commit | 62a5047be6cee5f692d44f97410cab11a01e3396 (patch) | |
tree | 535af51f9419cc58bc18e2d020b47098f4b88e42 /gn3 | |
parent | 0ca5f01422883d97e42dd37e59ffacdcf9a65af9 (diff) | |
download | genenetwork3-62a5047be6cee5f692d44f97410cab11a01e3396.tar.gz |
minor fixes for endpoint
Diffstat (limited to 'gn3')
-rw-r--r-- | gn3/api/wgcna.py | 3 | ||||
-rw-r--r-- | gn3/computations/wgcna.py | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/gn3/api/wgcna.py b/gn3/api/wgcna.py index 89784c4..fa044cf 100644 --- a/gn3/api/wgcna.py +++ b/gn3/api/wgcna.py @@ -19,4 +19,7 @@ def run_wgcna(): results = call_wgcna_script(wgcna_script, wgcna_data) + if results.get("data") is None: + return jsonify(results), 401 + return jsonify(results), 200 diff --git a/gn3/computations/wgcna.py b/gn3/computations/wgcna.py index e9b76e8..436a888 100644 --- a/gn3/computations/wgcna.py +++ b/gn3/computations/wgcna.py @@ -44,6 +44,5 @@ def call_wgcna_script(rscript_path: str, request_data: dict): "data": json.load(outputfile), **run_cmd_results } - # return json.load(outputfile) except Exception as error: raise error |