Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 3 additions & 13 deletions modules/nf-core/tabix/tabix/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ process TABIX_TABIX {
tuple val(meta), path(tab)

output:
tuple val(meta), path("*.tbi"), optional:true, emit: tbi
tuple val(meta), path("*.csi"), optional:true, emit: csi
path "versions.yml" , emit: versions
tuple val(meta), path("*.tbi") , optional:true , emit: tbi
tuple val(meta), path("*.csi") , optional:true , emit: csi
tuple val("${task.process}"), val('tabix'), eval("tabix -h 2>&1 | grep -oP 'Version:\\s*\\K[^\\s]+'") , topic: versions , emit: versions_tabix

when:
task.ext.when == null || task.ext.when
Expand All @@ -26,20 +26,10 @@ process TABIX_TABIX {
$args \\
$tab

cat <<-END_VERSIONS > versions.yml
"${task.process}":
tabix: \$(echo \$(tabix -h 2>&1) | sed 's/^.*Version: //; s/ .*\$//')
END_VERSIONS
"""

stub:
"""
touch ${tab}.tbi
touch ${tab}.csi

cat <<-END_VERSIONS > versions.yml
"${task.process}":
tabix: \$(echo \$(tabix -h 2>&1) | sed 's/^.*Version: //; s/ .*\$//')
END_VERSIONS
"""
}
28 changes: 21 additions & 7 deletions modules/nf-core/tabix/tabix/meta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,27 @@ output:
description: coordinate sorted index file
pattern: "*.{csi}"
ontologies: []
versions:
- versions.yml:
type: file
description: File containing software versions
pattern: "versions.yml"
ontologies:
- edam: http://edamontology.org/format_3750 # YAML
versions_tabix:
- - ${task.process}:
type: string
description: The process the versions were collected from
- tabix:
type: string
description: The tool name
- tabix -h 2>&1 | tail -1:
type: string
description: The command used to generate the version of the tool
topics:
- versions:
- - process:
type: string
description: The process the versions were collected from
- tool:
type: string
description: The tool name
- version:
type: string
description: The version of the tool
authors:
- "@joseespinosa"
- "@drpatelh"
Expand Down
17 changes: 11 additions & 6 deletions modules/nf-core/tabix/tabix/tests/main.nf.test
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ nextflow_process {
{ assert process.success },
{ assert snapshot(
process.out,
file(process.out.tbi[0][1]).name
file(process.out.tbi[0][1]).name,
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
}
Expand All @@ -51,7 +52,9 @@ nextflow_process {
{ assert process.success },
{ assert snapshot(
process.out,
file(process.out.tbi[0][1]).name).match() }
file(process.out.tbi[0][1]).name,
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
}

Expand All @@ -75,7 +78,8 @@ nextflow_process {
{ assert process.success },
{ assert snapshot(
process.out,
file(process.out.tbi[0][1]).name
file(process.out.tbi[0][1]).name,
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
}
Expand All @@ -100,7 +104,8 @@ nextflow_process {
{ assert process.success },
{ assert snapshot(
process.out,
file(process.out.csi[0][1]).name
file(process.out.csi[0][1]).name,
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
}
Expand All @@ -126,11 +131,11 @@ nextflow_process {
{ assert process.success },
{ assert snapshot(
process.out,
file(process.out.csi[0][1]).name
file(process.out.csi[0][1]).name,
process.out.findAll { key, val -> key.startsWith("versions")}
).match() }
)
}

}

}
155 changes: 120 additions & 35 deletions modules/nf-core/tabix/tabix/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@

],
"2": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
[
"TABIX_TABIX",
"tabix",
"1.21"
]
],
"csi": [

Expand All @@ -27,17 +31,30 @@
"genome.gff3.gz.tbi:md5,f79a67d95a98076e04fbe0455d825926"
]
],
"versions": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
},
"genome.gff3.gz.tbi"
"genome.gff3.gz.tbi",
{
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "24.10.5"
"nf-test": "0.9.3",
"nextflow": "25.10.0"
},
"timestamp": "2025-03-26T13:52:48.638506004"
"timestamp": "2025-10-29T15:30:55.967501479"
},
"sarscov2_bedgz_tbi": {
"content": [
Expand All @@ -54,7 +71,11 @@

],
"2": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
[
"TABIX_TABIX",
"tabix",
"1.21"
]
],
"csi": [

Expand All @@ -67,17 +88,30 @@
"test.bed.gz.tbi:md5,9a761d51cc81835fd1199201fdbcdd5d"
]
],
"versions": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
},
"test.bed.gz.tbi"
"test.bed.gz.tbi",
{
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "24.10.5"
"nf-test": "0.9.3",
"nextflow": "25.10.0"
},
"timestamp": "2025-03-26T13:52:44.910707349"
"timestamp": "2025-10-29T15:30:50.90188633"
},
"sarscov2_vcf_tbi": {
"content": [
Expand All @@ -94,7 +128,11 @@

],
"2": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
[
"TABIX_TABIX",
"tabix",
"1.21"
]
],
"csi": [

Expand All @@ -107,17 +145,30 @@
"test.vcf.gz.tbi:md5,d22e5b84e4fcd18792179f72e6da702e"
]
],
"versions": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
},
"test.vcf.gz.tbi"
"test.vcf.gz.tbi",
{
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "24.10.5"
"nf-test": "0.9.3",
"nextflow": "25.10.0"
},
"timestamp": "2025-03-26T13:52:52.405662623"
"timestamp": "2025-10-29T15:31:00.935418897"
},
"sarscov2_vcf_csi_stub": {
"content": [
Expand All @@ -139,7 +190,11 @@
]
],
"2": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
[
"TABIX_TABIX",
"tabix",
"1.21"
]
],
"csi": [
[
Expand All @@ -157,17 +212,30 @@
"test.vcf.gz.tbi:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"versions": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
},
"test.vcf.gz.csi"
"test.vcf.gz.csi",
{
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "24.10.5"
"nf-test": "0.9.3",
"nextflow": "25.10.0"
},
"timestamp": "2025-03-26T13:52:59.633992323"
"timestamp": "2025-10-29T15:31:10.669125187"
},
"sarscov2_vcf_csi": {
"content": [
Expand All @@ -184,7 +252,11 @@
]
],
"2": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
[
"TABIX_TABIX",
"tabix",
"1.21"
]
],
"csi": [
[
Expand All @@ -197,16 +269,29 @@
"tbi": [

],
"versions": [
"versions.yml:md5,3bfeccaff5f93fb7fca5f6dc0f0975d5"
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
},
"test.vcf.gz.csi"
"test.vcf.gz.csi",
{
"versions_tabix": [
[
"TABIX_TABIX",
"tabix",
"1.21"
]
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "24.10.5"
"nf-test": "0.9.3",
"nextflow": "25.10.0"
},
"timestamp": "2025-03-26T13:52:56.083553332"
"timestamp": "2025-10-29T15:31:05.605794542"
}
}
1 change: 0 additions & 1 deletion subworkflows/nf-core/vcf_annotate_ensemblvep/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ workflow VCF_ANNOTATE_ENSEMBLVEP {

// Gather versions of all tools used
ch_versions = ch_versions.mix(ENSEMBLVEP_VEP.out.versions)
ch_versions = ch_versions.mix(TABIX_TABIX.out.versions)

emit:
vcf_tbi = ch_vcf_tbi // channel: [ val(meta), path(vcf), path(tbi) ]
Expand Down
Loading