diff --git a/CHANGELOG.md b/CHANGELOG.md index d111be4..c2764ae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [[1.1.3](https://github.com/sanger-tol/variantcalling/releases/tag/1.1.3)] - Shang Tang (patch 3) - [2024-05-24] + +### Enhancements & fixes + +- Fixed the bug in the filtering of multiple PacBio files + ## [[1.1.2](https://github.com/sanger-tol/variantcalling/releases/tag/1.1.2)] - Shang Tang (patch 2) - [2024-03-14] ### Enhancements & fixes diff --git a/modules/local/pacbio_filter.nf b/modules/local/pacbio_filter.nf index 18dd11c..8ff62e0 100644 --- a/modules/local/pacbio_filter.nf +++ b/modules/local/pacbio_filter.nf @@ -11,8 +11,8 @@ process PACBIO_FILTER { tuple val(meta), path(txt) output: - path("*.blocklist"), emit: list - path "versions.yml", emit: versions + tuple val(meta), path("*.blocklist"), emit: list + path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when diff --git a/nextflow.config b/nextflow.config index ca837be..f67f186 100644 --- a/nextflow.config +++ b/nextflow.config @@ -215,7 +215,7 @@ manifest { description = """Variant calling pipeline for PacBio data using DeepVariant""" mainScript = 'main.nf' nextflowVersion = '!>=22.10.1' - version = '1.1.2' + version = '1.1.3' doi = 'https://doi.org/10.5281/zenodo.7890527' } diff --git a/subworkflows/local/filter_pacbio.nf b/subworkflows/local/filter_pacbio.nf index 2e306bf..3f6916c 100644 --- a/subworkflows/local/filter_pacbio.nf +++ b/subworkflows/local/filter_pacbio.nf @@ -61,9 +61,18 @@ workflow FILTER_PACBIO { // Create filtered BAM file SAMTOOLS_CONVERT.out.bam | join ( SAMTOOLS_CONVERT.out.csi ) + | join ( PACBIO_FILTER.out.list ) + | set { ch_reads_and_list } + + ch_reads_and_list + | map { meta, bam, csi, list -> [meta, bam, csi] } | set { ch_reads } - SAMTOOLS_FILTER ( ch_reads, [ [], [] ], PACBIO_FILTER.out.list ) + ch_reads_and_list + | map { meta, bam, csi, list -> list } + | set { ch_lists } + + SAMTOOLS_FILTER ( ch_reads, [ [], [] ], ch_lists ) ch_versions = ch_versions.mix ( SAMTOOLS_FILTER.out.versions.first() )