diff options
| author | Munyoki Kilyungi | 2025-03-07 12:01:07 +0300 |
|---|---|---|
| committer | Munyoki Kilyungi | 2025-03-07 12:01:07 +0300 |
| commit | a5bc34fa3123c0083e4a515a8c4e231dc4782082 (patch) | |
| tree | be014f250d0388d38c062040812045cc1c69d878 | |
| parent | fb86ebfae2f3ce9fc264aa5796d4513553725f87 (diff) | |
| download | genenetwork3-a5bc34fa3123c0083e4a515a8c4e231dc4782082.tar.gz | |
Revert "fix: Replace file path fetching code in rqtl2.py with current_app.root_path"
This reverts commit e7baf1a4cf05a4e7794a6531c92d367fcd8f1651. Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
| -rw-r--r-- | gn3/api/rqtl2.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gn3/api/rqtl2.py b/gn3/api/rqtl2.py index 5e0a390..5219573 100644 --- a/gn3/api/rqtl2.py +++ b/gn3/api/rqtl2.py @@ -36,7 +36,8 @@ def compute(log_file): output_file, _log2_file) = prepare_files(current_app.config.get("TMPDIR")) # write the input file with data required for creating the cross write_input_file(input_file, workspace_dir, data) - rqtl_path = Path(current_app.root_path) / "scripts" / "rqtl2_wrapper.R" + # TODO : Implement a better way for fetching the file Path. + rqtl_path =Path(__file__).absolute().parent.parent.parent.joinpath("scripts/rqtl2_wrapper.R") if not rqtl_path.is_file(): return jsonify({"error" : f"The script {rqtl_path} does not exists"}), 400 rqtl2_cmd = compose_rqtl2_cmd(rqtl_path, input_file, |
