From b3890dddd6c9f14f8053c910e4b1ab6781d6a036 Mon Sep 17 00:00:00 2001 From: Miguel Brown Date: Thu, 9 May 2024 16:58:12 -0400 Subject: [PATCH 1/4] :pencil: update reference pointers :pencil: fix doc quote --- docs/SOMATIC_SNV_ANNOT_README.md | 2 +- workflows/kfdrc-somatic-snv-annot-workflow.cwl | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/SOMATIC_SNV_ANNOT_README.md b/docs/SOMATIC_SNV_ANNOT_README.md index 3f43c78..fb46f76 100644 --- a/docs/SOMATIC_SNV_ANNOT_README.md +++ b/docs/SOMATIC_SNV_ANNOT_README.md @@ -38,7 +38,7 @@ Secondary files needed for each reference file will be a sub-bullet point - `Homo_sapiens_assembly38.fasta.fai` - `Homo_sapiens_assembly38.dict` - `echtvar_anno_zips`: `gnomad.v3.1.1.custom.echtvar.zip` - - `bcftools_strip_columns`: "csv string of columns to strip if needed to avoid conflict, i.e INFO/AF + - `bcftools_strip_columns`: csv string of columns to strip if needed to avoid conflict, i.e INFO/AF - `bcftools_public_filter`: 'FILTER="PASS"|INFO/HotSpotAllele=1' - `gatk_filter_name`: ["NORM_DP_LOW", "GNOMAD_AF_HIGH"] - `gatk_filter_expression`: ["vc.getGenotype('insert_normal_sample_name').getDP() <= 7", "gnomad_3_1_1_AF != '.' && gnomad_3_1_1_AF > 0.001 && gnomad_3_1_1_FILTER=='PASS'"] # NOTE!! Replace `insert_normal_sample_name` with the value you'd use for `input_normal_name`! # NOTE!! If your annotation includes dot values, those values must first be excluded! If they are not, GATK will error trying to convert those values! diff --git a/workflows/kfdrc-somatic-snv-annot-workflow.cwl b/workflows/kfdrc-somatic-snv-annot-workflow.cwl index 7fd488b..57504c8 100644 --- a/workflows/kfdrc-somatic-snv-annot-workflow.cwl +++ b/workflows/kfdrc-somatic-snv-annot-workflow.cwl @@ -43,7 +43,7 @@ doc: | - `Homo_sapiens_assembly38.fasta.fai` - `Homo_sapiens_assembly38.dict` - `echtvar_anno_zips`: `gnomad.v3.1.1.custom.echtvar.zip` - - `bcftools_strip_columns`: "csv string of columns to strip if needed to avoid conflict, i.e INFO/AF + - `bcftools_strip_columns`: csv string of columns to strip if needed to avoid conflict, i.e INFO/AF - `bcftools_public_filter`: 'FILTER="PASS"|INFO/HotSpotAllele=1' - `gatk_filter_name`: ["NORM_DP_LOW", "GNOMAD_AF_HIGH"] - `gatk_filter_expression`: ["vc.getGenotype('insert_normal_sample_name').getDP() <= 7", "gnomad_3_1_1_AF != '.' && gnomad_3_1_1_AF > 0.001 && gnomad_3_1_1_FILTER=='PASS'"] # NOTE!! Replace `insert_normal_sample_name` with the value you'd use for `input_normal_name`! # NOTE!! If your annotation includes dot values, those values must first be excluded! If they are not, GATK will error trying to convert those values! @@ -146,10 +146,10 @@ inputs: class: File, path: 607713829360f10e3982a423, name: tert.bed}]} protein_snv_hotspots: {type: 'File[]?', doc: "Column-name-containing, tab-delimited file(s) containing protein names and amino acid positions corresponding to hotspots", - "sbg:suggestedValue": [{class: File, path: 645919782fe81458768c552c, name: protein_snv_cancer_hotspots_v2.ENS105_liftover.tsv}]} + "sbg:suggestedValue": [{class: File, path: 663d2bcc27374715fccd8c6a, name: protein_snv_cancer_hotspots_v2.ENS105_liftover.tsv}]} protein_indel_hotspots: {type: 'File[]?', doc: "Column-name-containing, tab-delimited file(s) containing protein names and amino acid position ranges corresponding - to hotspots", "sbg:suggestedValue": [{class: File, path: 645919782fe81458768c552d, + to hotspots", "sbg:suggestedValue": [{class: File, path: 663d2bcc27374715fccd8c6f, name: protein_indel_cancer_hotspots_v2.ENS105_liftover.tsv}]} output_basename: string tool_name: string @@ -161,7 +161,7 @@ inputs: to retain as extra columns in MAF"} maf_center: {type: 'string?', doc: "Sequencing center of variant called", default: "."} custom_enst: {type: 'File?', doc: "Use a file with ens tx IDs for each gene to override - VEP PICK", "sbg:suggestedValue": {class: File, path: 6480c8a61dfc710d24a3a368, + VEP PICK", "sbg:suggestedValue": {class: File, path: 663d2bcc27374715fccd8c65, name: kf_isoform_override.tsv}} outputs: annotated_protected: {type: 'File[]', outputSource: rename_protected/renamed_files} From 1b799acf4ec221d7da9b6d3fba23eb5a2166dfa1 Mon Sep 17 00:00:00 2001 From: Miguel Brown Date: Fri, 10 May 2024 11:15:21 -0400 Subject: [PATCH 2/4] :pencil: minor typo fix --- docs/SOMATIC_SNV_ANNOT_README.md | 2 +- workflows/kfdrc-somatic-snv-annot-workflow.cwl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/SOMATIC_SNV_ANNOT_README.md b/docs/SOMATIC_SNV_ANNOT_README.md index fb46f76..cf9b594 100644 --- a/docs/SOMATIC_SNV_ANNOT_README.md +++ b/docs/SOMATIC_SNV_ANNOT_README.md @@ -65,7 +65,7 @@ For each input, the sub-bullet refers to when to use the suggested input - Vardict: "HGVSg" - `bcftools_strip_columns` # if reannotating an old file: - "FILTER/GNOMAD_AF_HIGH,FILTER/NORM_DP_LOW,INFO/CSQ,INFO/HotSpotAllele" # recommended if re-annotating from an older VEP cache - - "FILTER/GNOMAD_AF_HIGH,FILTER/NORM_DP_LOW,INFO/HotSpotAllele" # recommended if repeating hot spot an d want to keep VEP + - "FILTER/GNOMAD_AF_HIGH,FILTER/NORM_DP_LOW,INFO/HotSpotAllele" # recommended if repeating hot spot and want to keep VEP - `bcftools_prefilter_csv` # if annotating a file with calls you want screen for, use this. i.e `FILTER="PASS"` - `disable_vep_annotation` # set to `True` if existing VEP annotation of file is ok - `tool_name`: diff --git a/workflows/kfdrc-somatic-snv-annot-workflow.cwl b/workflows/kfdrc-somatic-snv-annot-workflow.cwl index 57504c8..1106dd3 100644 --- a/workflows/kfdrc-somatic-snv-annot-workflow.cwl +++ b/workflows/kfdrc-somatic-snv-annot-workflow.cwl @@ -70,7 +70,7 @@ doc: | - Vardict: "HGVSg" - `bcftools_strip_columns` # if reannotating an old file: - "FILTER/GNOMAD_AF_HIGH,FILTER/NORM_DP_LOW,INFO/CSQ,INFO/HotSpotAllele" # recommended if re-annotating from an older VEP cache - - "FILTER/GNOMAD_AF_HIGH,FILTER/NORM_DP_LOW,INFO/HotSpotAllele" # recommended if repeating hot spot an d want to keep VEP + - "FILTER/GNOMAD_AF_HIGH,FILTER/NORM_DP_LOW,INFO/HotSpotAllele" # recommended if repeating hot spot and want to keep VEP - `bcftools_prefilter_csv` # if annotating a file with calls you want screen for, use this. i.e `FILTER="PASS"` - `disable_vep_annotation` # set to `True` if existing VEP annotation of file is ok - `tool_name`: From b40609f43d14ae1238ae9c158f97f2d29584e72f Mon Sep 17 00:00:00 2001 From: Miguel Brown Date: Fri, 10 May 2024 11:17:05 -0400 Subject: [PATCH 3/4] :pencil: update git release pull --- workflows/kfdrc-somatic-snv-annot-workflow.cwl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workflows/kfdrc-somatic-snv-annot-workflow.cwl b/workflows/kfdrc-somatic-snv-annot-workflow.cwl index 1106dd3..909df6f 100644 --- a/workflows/kfdrc-somatic-snv-annot-workflow.cwl +++ b/workflows/kfdrc-somatic-snv-annot-workflow.cwl @@ -352,5 +352,5 @@ $namespaces: "sbg:license": Apache License 2.0 "sbg:publisher": KFDRC "sbg:links": -- id: 'https://github.com/kids-first/kf-annotation-tools/releases/tag/v1.2.0' +- id: 'https://github.com/kids-first/kf-annotation-tools/releases/tag/v1.2.1' label: github-release From 425dfa1da6ca5a2b490b78b9143bb8a83a077812 Mon Sep 17 00:00:00 2001 From: Miguel Brown Date: Fri, 10 May 2024 12:10:23 -0400 Subject: [PATCH 4/4] :wrench: added a working pipefail to tool --- tools/bcftools_filter_vcf.cwl | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tools/bcftools_filter_vcf.cwl b/tools/bcftools_filter_vcf.cwl index 63c3758..1c5e5b3 100644 --- a/tools/bcftools_filter_vcf.cwl +++ b/tools/bcftools_filter_vcf.cwl @@ -10,7 +10,7 @@ requirements: ramMin: 1000 coresMin: 1 - class: InlineJavascriptRequirement -baseCommand: [] +baseCommand: [bash -c 'set -eo pipefail &&] arguments: - position: 1 shellQuote: false @@ -22,18 +22,18 @@ arguments: } var cmd = "bcftools view "; if (inputs.include_expression != null){ - cmd += "--include '" + inputs.include_expression + "' " + inputs.input_vcf.path; + cmd += "--include \"" + inputs.include_expression + "\" " + inputs.input_vcf.path; if (inputs.exclude_expression != null){ - cmd += " | bcftools view --exclude '" + inputs.exclude_expression + "' -O z > " + out_base + ".vcf.gz;"; + cmd += " | bcftools view --exclude \"" + inputs.exclude_expression + "\"' -O z > " + out_base + ".vcf.gz;"; } else { cmd += " -O z > " + out_base + ".vcf.gz;"; } } else if (inputs.include_expression == null && inputs.exclude_expression != null){ - cmd += "--exclude '" + inputs.exclude_expression + "' " + inputs.input_vcf.path + " -O z > " + out_base + ".vcf.gz;"; + cmd += "--exclude \"" + inputs.exclude_expression + "\" " + inputs.input_vcf.path + " -O z > " + out_base + ".vcf.gz;"; } else if (inputs.include_expression == null && inputs.exclude_expression == null){ cmd = "cp " + inputs.input_vcf.path + " ./" + out_base + ".vcf.gz;"; } - cmd += "tabix " + out_base + ".vcf.gz;" + cmd += "tabix " + out_base + ".vcf.gz;'" return cmd; }