Skip to content

Commit e2c8bb0

Browse files
authored
Update whatshap module to single input tuple and topics channels (#11041)
* clean version leftover in whatshap * change input channel structure
1 parent d5a80a3 commit e2c8bb0

File tree

4 files changed

+6
-31
lines changed

4 files changed

+6
-31
lines changed

modules/nf-core/whatshap/haplotag/tests/main.nf.test

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,11 @@ nextflow_process {
3333
[ id:'test' ], // meta map
3434
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/vcf/NA03697B2_new.pbmm2.repeats.vcf.gz', checkIfExists: true),
3535
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/vcf/NA03697B2_new.pbmm2.repeats.vcf.gz.csi', checkIfExists: true),
36-
]
37-
38-
input[1] = [
39-
[ id:'test' ], // meta map
4036
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam', checkIfExists: true),
4137
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam.bai', checkIfExists: true),
4238
]
4339

44-
input[2] = Channel.of([
40+
input[1] = Channel.of([
4541
[ id:'test' ], // meta map
4642
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/genome/genome3.fasta', checkIfExists: true)
4743
]).join(SAMTOOLS_FAIDX.out.fai)

modules/nf-core/whatshap/phase/main.nf

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,8 @@ process WHATSHAP_PHASE {
88
: 'community.wave.seqera.io/library/whatshap:2.8--7fe530bc624a3e5a' }"
99

1010
input:
11-
tuple val(meta), path(vcf), path(tbi)
12-
tuple val(meta2), path(bam), path(bai)
13-
tuple val(meta3), path(fasta), path(fai)
11+
tuple val(meta), path(vcf), path(tbi), path(bam), path(bai)
12+
tuple val(meta2), path(fasta), path(fai)
1413

1514
output:
1615
tuple val(meta), path("*.vcf.gz"), emit: vcf
@@ -41,11 +40,6 @@ process WHATSHAP_PHASE {
4140
${prefix}.vcf
4241
4342
tabix -p vcf ${prefix}.vcf.gz
44-
45-
cat <<-END_VERSIONS > versions.yml
46-
"${task.process}":
47-
whatshap: \$(whatshap --version 2>&1 | sed 's/whatshap //g')
48-
END_VERSIONS
4943
"""
5044

5145
stub:

modules/nf-core/whatshap/phase/meta.yml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,6 @@ input:
3333
type: file
3434
description: VCF index file (optional but recommended)
3535
pattern: "*.{tbi,csi}"
36-
- - meta2:
37-
type: map
38-
description: |
39-
Groovy Map containing bam information
40-
e.g. [ id:'test', single_end:false ]
4136
- bam:
4237
type: file
4338
description: BAM file with aligned reads
@@ -46,7 +41,7 @@ input:
4641
type: file
4742
description: BAM index file (optional but recommended)
4843
pattern: "*.bai"
49-
- - meta3:
44+
- - meta2:
5045
type: map
5146
description: |
5247
Groovy Map containing reference information

modules/nf-core/whatshap/phase/tests/main.nf.test

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,11 @@ nextflow_process {
3535
[ id:'test' ], // meta map
3636
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/vcf/NA03697B2_new.pbmm2.repeats.vcf.gz', checkIfExists: true),
3737
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/vcf/NA03697B2_new.pbmm2.repeats.vcf.gz.csi', checkIfExists: true),
38-
39-
]
40-
41-
input[1] = [
42-
[ id:'test' ], // meta map
4338
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam', checkIfExists: true),
4439
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam.bai', checkIfExists: true),
4540
]
4641

47-
input[2] = Channel.of([
42+
input[1] = Channel.of([
4843
[ id:'test' ], // meta map
4944
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/genome/genome3.fasta', checkIfExists: true)
5045
]).join(SAMTOOLS_FAIDX.out.fai)
@@ -76,16 +71,11 @@ nextflow_process {
7671
[ id:'test' ], // meta map
7772
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/vcf/NA03697B2_new.pbmm2.repeats.vcf.gz', checkIfExists: true),
7873
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/vcf/NA03697B2_new.pbmm2.repeats.vcf.gz.csi', checkIfExists: true),
79-
80-
]
81-
82-
input[1] = [
83-
[ id:'test' ], // meta map
8474
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam', checkIfExists: true),
8575
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/pacbio/bam/NA03697B2_downsampled.pbmm2.repeats.bam.bai', checkIfExists: true),
8676
]
8777

88-
input[2] = Channel.of([
78+
input[1] = Channel.of([
8979
[ id:'test' ], // meta map
9080
file(params.modules_testdata_base_path + 'genomics/homo_sapiens/genome/genome3.fasta', checkIfExists: true)
9181
]).join(SAMTOOLS_FAIDX.out.fai)

0 commit comments

Comments
 (0)