about summary refs log tree commit diff
path: root/scripts
diff options
context:
space:
mode:
authorFrederick Muriuki Muriithi2025-06-03 12:12:58 -0500
committerFrederick Muriuki Muriithi2025-06-03 12:12:58 -0500
commitfd997d55b745a192f9946de1a7652fd28c700280 (patch)
tree9c12494e86f72526a075852bb7e42c02a81ffcff /scripts
parent9280e6232152991fca762d74f415b704a452673d (diff)
downloadgn-uploader-fd997d55b745a192f9946de1a7652fd28c700280.tar.gz
Add more logging to track progress.
Diffstat (limited to 'scripts')
-rw-r--r--scripts/load_phenotypes_to_db.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/load_phenotypes_to_db.py b/scripts/load_phenotypes_to_db.py
index d2d1d2c..0b1f738 100644
--- a/scripts/load_phenotypes_to_db.py
+++ b/scripts/load_phenotypes_to_db.py
@@ -282,6 +282,7 @@ def load_data(conn: mysqldb.Connection, job: dict) -> int:
                                      samples=samples,
                                      control_data=_control_data,
                                      filesdir=_outdir)
+    logger.info("Saved %s new phenotype data rows.", _num_data_rows)
     # 4. Cross-reference Phenotype, Publication, and PublishData in PublishXRef
     logger.info("Cross-referencing new phenotypes to their data and publications.")
     xrefs = cross_reference_phenotypes_publications_and_data(
@@ -295,6 +296,8 @@ def load_data(conn: mysqldb.Connection, job: dict) -> int:
                                       samples=samples,
                                       control_data=_control_data,
                                       filesdir=_outdir)
+    logger.info("Saved %s new phenotype standard error rows.", _num_se_rows)
+
     logger.info("Saving new phenotypes sample counts.")
     _num_n_rows = save_phenotypes_n(conn=conn,
                                     dataidmap=dataidmap,
@@ -302,6 +305,7 @@ def load_data(conn: mysqldb.Connection, job: dict) -> int:
                                     samples=samples,
                                     control_data=_control_data,
                                     filesdir=_outdir)
+    logger.info("Saved %s new phenotype sample counts rows.", num_n_rows)
     # 6. If entirely new data, update authorisations (break this down)
     logger.info("Updating authorisation.")
     update_auth(_token, _species, _population, _dataset, _phenos)