aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzsloan2023-05-22 17:39:52 +0000
committerzsloan2023-05-22 17:39:52 +0000
commitdb6f7c5099445ce52ff8869438aabd4dc3b332f3 (patch)
treec5d06f46bdae27a0796e99f99a6379d11d654d19
parent44603ac3dab3f2628112f964080c1871f6c77d84 (diff)
downloadgenenetwork3-db6f7c5099445ce52ff8869438aabd4dc3b332f3.tar.gz
Use f-string for setting genofile_path
Also set default value for os.environ.get("GENENETWORK_FILES")
-rw-r--r--gn3/db/datasets.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/gn3/db/datasets.py b/gn3/db/datasets.py
index 4fdf797..4372818 100644
--- a/gn3/db/datasets.py
+++ b/gn3/db/datasets.py
@@ -13,7 +13,7 @@ def retrieve_sample_list(group: str):
"""
samplelist = []
- genofile_path = os.environ.get("GENENETWORK_FILES") + "/genotype/" + group + ".geno"
+ genofile_path = f"{os.environ.get("GENENETWORK_FILES", "/home/gn2/production/genotype_files/")}/genotype/{group}.geno"
if os.path.isfile(genofile_path):
with open(genofile_path, encoding="utf-8") as genofile:
line = ""