diff options
author | Munyoki Kilyungi | 2022-09-05 10:30:53 +0300 |
---|---|---|
committer | BonfaceKilz | 2022-09-08 14:26:19 +0300 |
commit | ed726c705404098f4a519b7028d69bc560ffc805 (patch) | |
tree | 4051ee87152eac4a0b520aa3bcdac6de69c05c06 /wqflask | |
parent | eef56387e8de5730b6eb2c7d9d61508d83119631 (diff) | |
download | genenetwork2-ed726c705404098f4a519b7028d69bc560ffc805.tar.gz |
Remove sql_alchemy initialisation when profiling correlations
* wqflask/scripts/profile_corrs.py: Remove sqlalchemy, connect_db and
shutdown_session.
(__main__): Remove "g.db".
Diffstat (limited to 'wqflask')
-rw-r--r-- | wqflask/scripts/profile_corrs.py | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/wqflask/scripts/profile_corrs.py b/wqflask/scripts/profile_corrs.py index 1badeb70..a42e2935 100644 --- a/wqflask/scripts/profile_corrs.py +++ b/wqflask/scripts/profile_corrs.py @@ -3,14 +3,12 @@ import sys import pstats import cProfile -import sqlalchemy from flask import g, request from utility.startup_config import app_config from wqflask import app from wqflask.user_session import UserSession -from wqflask.views import connect_db, shutdown_session from wqflask.correlation.correlation_gn3_api import compute_correlation def sample_vals(): @@ -65,10 +63,5 @@ if __name__ == "__main__": app_config() with app.app_context(): with app.test_request_context("/corr_compute", data=simulated_form()): - g.db = sqlalchemy.create_engine( ## Setup global db connection - app.config.get('SQL_URI'), encoding="latin1") g.user_session = UserSession() main() - ## dispose global db connection - g.db.dispose() - g.db.close() |