From d9aeed1c05e7310992e5a00128e59b8598145c87 Mon Sep 17 00:00:00 2001 From: Oriol Pich Date: Wed, 20 Jul 2022 15:14:40 +0100 Subject: [PATCH 1/3] Fix snp list argument when phasing --- src/hatchet/utils/run.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hatchet/utils/run.py b/src/hatchet/utils/run.py index 5344e795..9210b72f 100644 --- a/src/hatchet/utils/run.py +++ b/src/hatchet/utils/run.py @@ -158,8 +158,8 @@ def main(args=None): f'{output}/phase/', '-L', ] - + (['-N'] if config.genotype_snps.chr_notation else []) + glob.glob(f'{output}/snps/*.vcf.gz') + + (['-N'] if config.genotype_snps.chr_notation else []) + extra_args ) From 50722c2f4f8cc47332298a3d839fe8e42e8eeb44 Mon Sep 17 00:00:00 2001 From: Oriol Pich Date: Wed, 20 Jul 2022 17:24:21 +0100 Subject: [PATCH 2/3] Fix liftover arguments from picard --- src/hatchet/utils/phase_snps.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hatchet/utils/phase_snps.py b/src/hatchet/utils/phase_snps.py index 4ff6eec4..413de7b4 100644 --- a/src/hatchet/utils/phase_snps.py +++ b/src/hatchet/utils/phase_snps.py @@ -247,8 +247,8 @@ def liftover(self, infile, chromosome, outname, chain, refgen, ch): # e.g. small contigs variably present among the assemblies cmd1 = ( - f'{self.picard} LiftoverVcf -I {infile} -O {tmpfile} -CHAIN {chain} -R {refgen} -REJECT {rejfile} ' - '--WARN_ON_MISSING_CONTIG true' + f'{self.picard} LiftoverVcf -I={infile} -O={tmpfile} -CHAIN={chain} -R={refgen} -REJECT={rejfile} ' + '--WARN_ON_MISSING_CONTIG=true' ) # need to change 'chr' notation depending on liftover direction c = chromosome if not ch else f'chr{chromosome}' From c6fe9388d35c0a0b10a3a030f6013f4961738a44 Mon Sep 17 00:00:00 2001 From: Oriol Pich Date: Wed, 20 Jul 2022 17:41:14 +0100 Subject: [PATCH 3/3] Remove dashes for latest picard compatibility --- src/hatchet/utils/phase_snps.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hatchet/utils/phase_snps.py b/src/hatchet/utils/phase_snps.py index 413de7b4..99deee4c 100644 --- a/src/hatchet/utils/phase_snps.py +++ b/src/hatchet/utils/phase_snps.py @@ -247,8 +247,8 @@ def liftover(self, infile, chromosome, outname, chain, refgen, ch): # e.g. small contigs variably present among the assemblies cmd1 = ( - f'{self.picard} LiftoverVcf -I={infile} -O={tmpfile} -CHAIN={chain} -R={refgen} -REJECT={rejfile} ' - '--WARN_ON_MISSING_CONTIG=true' + f'{self.picard} LiftoverVcf I={infile} O={tmpfile} CHAIN={chain} R={refgen} REJECT={rejfile} ' + 'WARN_ON_MISSING_CONTIG=true' ) # need to change 'chr' notation depending on liftover direction c = chromosome if not ch else f'chr{chromosome}'