diff --git a/README.md b/README.md index 01a740a..1201c69 100644 --- a/README.md +++ b/README.md @@ -226,6 +226,20 @@ Variant annotation output can be found in `qc_annotation` and the recurrent amino acid change heatmap can be found in `plots/_aa_mutation_heatmap.pdf`. +## Pangolin Version 4 +Pangolin version 4 included several changes which required updates +to the `ncov-tools` environment. By default, `ncov-tools` will run pangolin +4 and will require changes to `ncov-parser` version 1.9 to parse the output +and populate the summary QC file. + +Backward compability with Pangolin 3 is available and will require the following +parameter addition in the `config.yaml` file: +``` +pangolin_version: "3" +``` +Note that the specific version is not required, only if it is "3" or "4". + + ## Credit and Acknowledgements * The tree-with-SNPs plot was inspired by a plot shared by Mads Albertsen. diff --git a/VERSION.txt b/VERSION.txt index c009739..da0694b 100644 --- a/VERSION.txt +++ b/VERSION.txt @@ -1 +1 @@ -v.1.8.0 +v.1.9.0 diff --git a/workflow/envs/environment.yml b/workflow/envs/environment.yml index e4f0069..52ec21e 100644 --- a/workflow/envs/environment.yml +++ b/workflow/envs/environment.yml @@ -30,11 +30,10 @@ dependencies: - usher - pip: - dendropy>=4.4.0 - - pyvcf + - pyvcf3 - ncov-parser - - git+https://github.com/hCoV-2019/lineages.git - - git+https://github.com/hCoV-2019/pangolin.git + - git+https://github.com/cov-lineages/pangolin.git + - git+https://github.com/cov-lineages/pangolin-data.git - git+https://github.com/cov-lineages/constellations.git - git+https://github.com/cov-lineages/scorpio.git - - git+https://github.com/cov-lineages/pangolin-data.git - git+https://github.com/jts/ncov-watch.git diff --git a/workflow/rules/analysis.smk b/workflow/rules/analysis.smk index 851e9e8..cacecc8 100644 --- a/workflow/rules/analysis.smk +++ b/workflow/rules/analysis.smk @@ -152,7 +152,8 @@ rule make_sample_qc_summary: py_script="get_qc.py", metadata_opt=get_qc_summary_metadata_opt, platform_opt=get_platform_opt, - run_name_opt=get_run_name_opt + run_name_opt=get_run_name_opt, + pangolin_version_opt=get_pangolin_version_opt shell: "{params.py_script} --alleles {input.alleles} \ --coverage {input.samplecoverage} \ @@ -162,7 +163,7 @@ rule make_sample_qc_summary: --sample {wildcards.sample} \ --lineage {input.lineagereport} \ --aa_table {input.aa_table} \ - --mutations {input.watch} \ + --mutations {input.watch} {params.pangolin_version_opt} \ --run_name {params.run_name_opt} > {output}" # merge the per-sample summary files into the run-level report diff --git a/workflow/rules/common.smk b/workflow/rules/common.smk index e0f3810..3bd9ddd 100644 --- a/workflow/rules/common.smk +++ b/workflow/rules/common.smk @@ -235,6 +235,15 @@ def get_annotated_variants(wildcards): def get_all_masked_consensus(wildcards): return ["masked_fasta/{sample}.masked_consensus.fasta".format(sample=s) for s in get_sample_names()] +def get_pangolin_version_opt(wildcards): + if "pangolin_version" in config: + return "--pangolin_ver %s" % (config['pangolin_version']) + else: + return "" + + + + # generate the amplicon-level bed file from the input primer bed rule make_amplicon_bed: