diff --git a/genpipes/core/epilogue.py b/genpipes/core/epilogue.py index 83d9714f7..7e8a4c09c 100755 --- a/genpipes/core/epilogue.py +++ b/genpipes/core/epilogue.py @@ -1,4 +1,4 @@ -#!/cvmfs/soft.mugqic/CentOS6/software/python/Python-3.12.2/bin/python +#!/usr/bin/env python import csv import os diff --git a/genpipes/core/prologue.py b/genpipes/core/prologue.py index 390a5322b..8c39e05dd 100755 --- a/genpipes/core/prologue.py +++ b/genpipes/core/prologue.py @@ -1,4 +1,4 @@ -#!/cvmfs/soft.mugqic/CentOS6/software/python/Python-3.12.2/bin/python +#!/usr/bin/env python import csv import os diff --git a/genpipes/core/scheduler.py b/genpipes/core/scheduler.py index 80c4886e1..712988f87 100755 --- a/genpipes/core/scheduler.py +++ b/genpipes/core/scheduler.py @@ -333,7 +333,8 @@ def job2json_project_tracking(self, pipeline, job, job_status): -j \\"{job_name}\\" \\{metrics} -o \\"{json_outfile}\\" \\ -f {status} -export PT_JSON_OUTFILE=\\"{json_outfile}\\" {command_separator} +export PT_JSON_OUTFILE=\\"{json_outfile}\\" +export TIMESTAMP=\\"{timestamp}\\" {command_separator} """.format( job2json_project_tracking_script="genpipes tools job2json_project_tracking", samples=",".join([sample.name for sample in job.samples]), @@ -341,6 +342,7 @@ def job2json_project_tracking(self, pipeline, job, job_status): job_name=job.name, metrics=('\n -m \\"' + ','.join(job.metrics) + '\\" \\') if job.metrics else '', json_outfile=json_outfile, + timestamp=pipeline.timestamp, status=job_status, command_separator="&&" if (job_status=='\\"RUNNING\\"') else "" ) if json_outfile else "" diff --git a/genpipes/pipelines/dnaseq/__init__.py b/genpipes/pipelines/dnaseq/__init__.py index 739125357..edc759426 100755 --- a/genpipes/pipelines/dnaseq/__init__.py +++ b/genpipes/pipelines/dnaseq/__init__.py @@ -2822,7 +2822,7 @@ def report_pcgr(self): if self.project_tracking_json: samples = [sample] - pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_{self.timestamp}.o") + pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_$TIMESTAMP.o") jobs.append( concat_jobs( [ @@ -2960,7 +2960,7 @@ def report_pcgr(self): samples = [tumor_pair.normal, tumor_pair.tumor] if self.project_tracking_json: - pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_{self.timestamp}.o") + pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_$TIMESTAMP.o") jobs.append( concat_jobs( [ @@ -3958,7 +3958,7 @@ def cnvkit_batch(self): name=f"cnvkit_batch.cna.{sample_name}", samples=samples, readsets=readsets, - input_dependency=[input_cna, output_cna], + input_dependency=[input_cna], output_dependency=[header, output_cna_body, output_cna] ) ) @@ -4197,7 +4197,7 @@ def cnvkit_batch(self): name=f"cnvkit_batch.cna.{sample_name}", samples=[tumor_pair.normal, tumor_pair.tumor], readsets=[*list(tumor_pair.normal.readsets), *list(tumor_pair.tumor.readsets)], - input_dependency=[input_cna, output_cna], + input_dependency=[input_cna], output_dependency=[header, output_cna_body, output_cna], removable_files=[header, output_cna_body] ) diff --git a/genpipes/pipelines/longread_dnaseq/__init__.py b/genpipes/pipelines/longread_dnaseq/__init__.py index 39efbe482..9152eea6c 100644 --- a/genpipes/pipelines/longread_dnaseq/__init__.py +++ b/genpipes/pipelines/longread_dnaseq/__init__.py @@ -1911,7 +1911,7 @@ def report_pcgr(self): if self.project_tracking_json: samples = [sample] - pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_{self.timestamp}.o") + pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_$TIMESTAMP.o") jobs.append( concat_jobs( [ @@ -2024,7 +2024,7 @@ def report_pcgr(self): samples = [tumor_pair.normal, tumor_pair.tumor] if self.project_tracking_json: - pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_{self.timestamp}.o") + pcgr_output_file = os.path.join(self.output_dir, "job_output", "report_pcgr", f"{job_name}_$TIMESTAMP.o") jobs.append( concat_jobs( [ diff --git a/genpipes/pipelines/rnaseq_light/__init__.py b/genpipes/pipelines/rnaseq_light/__init__.py index 4c7c86d73..9f4ca8fb7 100644 --- a/genpipes/pipelines/rnaseq_light/__init__.py +++ b/genpipes/pipelines/rnaseq_light/__init__.py @@ -77,7 +77,7 @@ def kallisto(self): transcriptome_file = global_conf.global_get('kallisto', 'transcriptome_idx', param_type="filepath") tx2genes_file = global_conf.global_get('kallisto', 'transcript2genes', param_type="filepath") bootstraps = global_conf.global_get('kallisto', 'bootstraps') - other_param = global_conf.global_get('kallisto', 'other_options', required=False) + other_param = global_conf.global_get('kallisto', 'other_parameters', required=False) jobs = []