aboutsummaryrefslogtreecommitdiff
path: root/gn3/commands.py
diff options
context:
space:
mode:
authorFrederick Muriuki Muriithi2023-04-06 12:31:05 +0300
committerFrederick Muriuki Muriithi2023-04-06 12:31:05 +0300
commit17abad9300e4a96a14f94da486ef8307f7d27e06 (patch)
tree38fe3bfd36be9a821adfc67b83fbbd587ceb8b5e /gn3/commands.py
parent3d873435f0d464864d4d691d6be4db40931fac05 (diff)
downloadgenenetwork3-17abad9300e4a96a14f94da486ef8307f7d27e06.tar.gz
Remove deprecated `gn3.db_utils.database_connector` function
Remove the deprecated function and fix a myriad of bugs that arise from removing the function. Issue: https://issues.genenetwork.org/issues/bugfix_coupling_current_app_and_db_utils
Diffstat (limited to 'gn3/commands.py')
-rw-r--r--gn3/commands.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/gn3/commands.py b/gn3/commands.py
index 0e78fd2..a90e895 100644
--- a/gn3/commands.py
+++ b/gn3/commands.py
@@ -14,6 +14,8 @@ from typing import Tuple
from typing import Union
from typing import Sequence
from uuid import uuid4
+
+from flask import current_app
from redis.client import Redis # Used only in type hinting
from gn3.chancy import random_string
@@ -80,7 +82,8 @@ def compose_pcorrs_command(
prefix_cmd = (
f"{sys.executable}", "-m", "scripts.partial_correlations",
- primary_trait, ",".join(control_traits), __parse_method__(method))
+ primary_trait, ",".join(control_traits), __parse_method__(method),
+ current_app.config["SQL_URI"])
if (
kwargs.get("target_database") is not None
and kwargs.get("target_traits") is None):