From 399b4ae468fec701a8c664a672f56cccfc43896b Mon Sep 17 00:00:00 2001 From: Nathan Gaddis Date: Wed, 30 Oct 2024 14:55:20 +0000 Subject: [PATCH] Fixed bug in batch_extract_gvcf_variants --- t1dgrs2_pipeline/v2.0/Dockerfile | 1 + .../v2.0/scripts/batch_extract_gvcf_variants.py | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/t1dgrs2_pipeline/v2.0/Dockerfile b/t1dgrs2_pipeline/v2.0/Dockerfile index 61730d1..9e54050 100644 --- a/t1dgrs2_pipeline/v2.0/Dockerfile +++ b/t1dgrs2_pipeline/v2.0/Dockerfile @@ -83,3 +83,4 @@ WORKDIR /data RUN chown -R docker:staff /data ENTRYPOINT [ "/opt/entrypoint.sh" ] + diff --git a/t1dgrs2_pipeline/v2.0/scripts/batch_extract_gvcf_variants.py b/t1dgrs2_pipeline/v2.0/scripts/batch_extract_gvcf_variants.py index 538ed13..9e110b6 100644 --- a/t1dgrs2_pipeline/v2.0/scripts/batch_extract_gvcf_variants.py +++ b/t1dgrs2_pipeline/v2.0/scripts/batch_extract_gvcf_variants.py @@ -119,9 +119,9 @@ def get_running_workflows(): files = os.listdir(control_gvcf_dir) files_with_paths = [control_gvcf_dir + file for file in files] control_files_to_process = dict(zip(files, files_with_paths)) - -# Merge gvcf lists -files_to_process = sample_files_to_process | control_files_to_process + files_to_process = sample_files_to_process | control_files_to_process +else: + files_to_process = sample_files_to_process.copy() # Loop over all files file_plink_merge_list = "{}plink_merge_list.txt".format(output_dir) @@ -132,7 +132,7 @@ def get_running_workflows(): if "md5" in file or "tbi" in file: continue - if control_gvcf_dir in path: + if control_gvcf_dir is not None and control_gvcf_dir in path: result = re.search(r'^(\S+).hard-filtered.gvcf.gz$', file) else: if args.sequencing_provider == 'revvity':