diff options
| author | Alexander_Kabui | 2024-12-20 17:53:07 +0300 |
|---|---|---|
| committer | Alexander_Kabui | 2024-12-20 17:53:07 +0300 |
| commit | bba6befbad749533779c0b6057e22885d351595b (patch) | |
| tree | c8a059ad9bfa1839cafa83c5fa4f4a1c2db87547 | |
| parent | dd37daf60353f125eaed6fb5d99fe65634bcede6 (diff) | |
| download | genenetwork3-bba6befbad749533779c0b6057e22885d351595b.tar.gz | |
feat: Enable streaming for output.
| -rw-r--r-- | gn3/api/rqtl.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gn3/api/rqtl.py b/gn3/api/rqtl.py index 7246ba8..39f45a3 100644 --- a/gn3/api/rqtl.py +++ b/gn3/api/rqtl.py @@ -64,9 +64,11 @@ run the rqtl_wrapper script and return the results as JSON run_id = request.args.get("id", str(uuid.uuid4())) if not os.path.isfile(os.path.join(current_app.config.get("TMPDIR"), "gn3", rqtl_cmd.get('output_file'))): - stream_ouput_file = os.path.join(current_app.config.get("TMPDIR"), + pass + stream_ouput_file = os.path.join(current_app.config.get("TMPDIR"), f"{run_id}.txt") - run_process(rqtl_cmd.get("rqtl_cmd"), stream_ouput_file, run_id) + + results = run_process(rqtl_cmd.get("rqtl_cmd"), stream_ouput_file, run_id) if "pairscan" in rqtl_bool_kwargs: rqtl_output['results'] = process_rqtl_pairscan(rqtl_cmd.get('output_file'), genofile) |
