Skip to content

Commit b5eb3ae

Browse files
committed
truvari topics migration
1 parent b1d9121 commit b5eb3ae

File tree

15 files changed

+250
-186
lines changed

15 files changed

+250
-186
lines changed

modules/nf-core/truvari/bench/environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ channels:
44
- conda-forge
55
- bioconda
66
dependencies:
7-
- bioconda::truvari=5.3.0
7+
- bioconda::truvari=5.4.0

modules/nf-core/truvari/bench/main.nf

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ process TRUVARI_BENCH {
44

55
conda "${moduleDir}/environment.yml"
66
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
7-
'https://depot.galaxyproject.org/singularity/truvari:5.3.0--pyhdfd78af_0':
8-
'biocontainers/truvari:5.3.0--pyhdfd78af_0' }"
7+
'https://depot.galaxyproject.org/singularity/truvari:5.4.0--pyhdfd78af_0':
8+
'biocontainers/truvari:5.4.0--pyhdfd78af_0' }"
99

1010
input:
1111
tuple val(meta), path(vcf), path(tbi), path(truth_vcf), path(truth_tbi), path(bed)
@@ -23,7 +23,8 @@ process TRUVARI_BENCH {
2323
tuple val(meta), path("*.tp-comp.vcf.gz.tbi"), emit: tp_comp_tbi
2424
tuple val(meta), path("*.summary.json") , emit: summary
2525
tuple val(meta), path("*.log.txt") , emit: log
26-
path "versions.yml" , emit: versions
26+
tuple val("${task.process}"), val('truvari'), eval("truvari version 2>&1 | sed 's/Truvari v//'"), topic: versions, emit: versions_truvari
27+
2728

2829
when:
2930
task.ext.when == null || task.ext.when
@@ -53,10 +54,6 @@ process TRUVARI_BENCH {
5354
mv ${prefix}/summary.json ./${prefix}.summary.json
5455
mv ${prefix}/log.txt ./${prefix}.log.txt
5556
56-
cat <<-END_VERSIONS > versions.yml
57-
"${task.process}":
58-
truvari: \$(echo \$(truvari version 2>&1) | sed 's/^Truvari v//' ))
59-
END_VERSIONS
6057
"""
6158

6259
stub:
@@ -72,10 +69,5 @@ process TRUVARI_BENCH {
7269
touch ${prefix}.tp-comp.vcf.gz.tbi
7370
touch ${prefix}.summary.json
7471
touch ${prefix}.log.txt
75-
76-
cat <<-END_VERSIONS > versions.yml
77-
"${task.process}":
78-
truvari: \$(echo \$(truvari version 2>&1) | sed 's/^Truvari v//' ))
79-
END_VERSIONS
8072
"""
8173
}

modules/nf-core/truvari/bench/meta.yml

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -185,13 +185,27 @@ output:
185185
pattern: "*.log.txt"
186186
ontologies:
187187
- edam: http://edamontology.org/format_1964
188+
versions_truvari:
189+
- - ${task.process}:
190+
type: string
191+
description: The process the versions were collected from
192+
- truvari:
193+
type: string
194+
description: The name of the tool
195+
- "truvari version 2>&1 | sed 's/Truvari v//'":
196+
type: eval
197+
description: The expression to obtain the version of the tool
198+
topics:
188199
versions:
189-
- versions.yml:
190-
type: file
191-
description: File containing software versions
192-
pattern: "versions.yml"
193-
ontologies:
194-
- edam: http://edamontology.org/format_3750 # YAML
200+
- - ${task.process}:
201+
type: string
202+
description: The process the versions were collected from
203+
- truvari:
204+
type: string
205+
description: The name of the tool
206+
- "truvari version 2>&1 | sed 's/Truvari v//'":
207+
type: eval
208+
description: The expression to obtain the version of the tool
195209
authors:
196210
- "@nvnieuwk"
197211
maintainers:

modules/nf-core/truvari/bench/tests/main.nf.test

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ nextflow_process {
1010
tag "truvari"
1111
tag "truvari/bench"
1212

13-
test("without bed") {
13+
test("homo sapiens - simulated sv - without bed") {
1414

1515
when {
1616
process {
@@ -46,18 +46,17 @@ nextflow_process {
4646
file(process.out.tp_base_tbi[0][1]).name,
4747
path(process.out.tp_comp_vcf[0][1]).vcf.summary,
4848
file(process.out.tp_comp_tbi[0][1]).name,
49-
path(process.out.versions[0]).yaml,
5049
file(process.out.log[0][1]).name,
5150
process.out.summary,
52-
process.out.versions
51+
process.out.findAll { key, val -> key.startsWith('versions') }
5352
).match()
5453
}
5554
)
5655
}
5756
}
5857

5958

60-
test("with bed") {
59+
test("homo sapiens - simulated sv - with bed") {
6160

6261
when {
6362
process {
@@ -93,18 +92,17 @@ nextflow_process {
9392
file(process.out.tp_base_tbi[0][1]).name,
9493
path(process.out.tp_comp_vcf[0][1]).vcf.summary,
9594
file(process.out.tp_comp_tbi[0][1]).name,
96-
path(process.out.versions[0]).yaml,
9795
file(process.out.log[0][1]).name,
9896
process.out.summary,
99-
process.out.versions
97+
process.out.findAll { key, val -> key.startsWith('versions') }
10098
).match()
10199
}
102100
)
103101
}
104102
}
105103

106104

107-
test("without bed -- stub") {
105+
test("homo sapiens - simulated sv - without bed -- stub") {
108106
options '-stub'
109107
when {
110108
process {
@@ -133,7 +131,7 @@ nextflow_process {
133131
assertAll(
134132
{ assert snapshot(
135133
process.out,
136-
path(process.out.versions[0]).yaml
134+
process.out.findAll { key, val -> key.startsWith('versions') }
137135
).match()
138136
}
139137
)

modules/nf-core/truvari/bench/tests/main.nf.test.snap

Lines changed: 92 additions & 78 deletions
Original file line numberDiff line numberDiff line change
@@ -1,73 +1,5 @@
11
{
2-
"without bed": {
3-
"content": [
4-
"VcfFile [chromosomes=[chr21], sampleCount=1, variantCount=136, phased=false, phasedAutodetect=false]",
5-
"test.fn.vcf.gz.tbi",
6-
"VcfFile [chromosomes=[chr21], sampleCount=1, variantCount=136, phased=false, phasedAutodetect=false]",
7-
"test.fp.vcf.gz.tbi",
8-
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
9-
"test.tp-base.vcf.gz.tbi",
10-
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
11-
"test.tp-comp.vcf.gz.tbi",
12-
{
13-
"TRUVARI_BENCH": {
14-
"truvari": "5.3.0)"
15-
}
16-
},
17-
"test.log.txt",
18-
[
19-
[
20-
{
21-
"id": "test"
22-
},
23-
"test.summary.json:md5,aff467e3dbccf2c00a7aa81c2a36f62a"
24-
]
25-
],
26-
[
27-
"versions.yml:md5,4af58a090ba71ffe3af4c39b26cae34e"
28-
]
29-
],
30-
"meta": {
31-
"nf-test": "0.8.4",
32-
"nextflow": "25.04.7"
33-
},
34-
"timestamp": "2025-11-17T15:29:53.083049"
35-
},
36-
"with bed": {
37-
"content": [
38-
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
39-
"test.fn.vcf.gz.tbi",
40-
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
41-
"test.fp.vcf.gz.tbi",
42-
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
43-
"test.tp-base.vcf.gz.tbi",
44-
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
45-
"test.tp-comp.vcf.gz.tbi",
46-
{
47-
"TRUVARI_BENCH": {
48-
"truvari": "5.3.0)"
49-
}
50-
},
51-
"test.log.txt",
52-
[
53-
[
54-
{
55-
"id": "test"
56-
},
57-
"test.summary.json:md5,397452f6fd093809aee763a3d2310552"
58-
]
59-
],
60-
[
61-
"versions.yml:md5,4af58a090ba71ffe3af4c39b26cae34e"
62-
]
63-
],
64-
"meta": {
65-
"nf-test": "0.8.4",
66-
"nextflow": "25.04.7"
67-
},
68-
"timestamp": "2025-11-17T15:30:23.206355"
69-
},
70-
"without bed -- stub": {
2+
"homo sapiens - simulated sv - without bed -- stub": {
713
"content": [
724
{
735
"0": [
@@ -87,7 +19,11 @@
8719
]
8820
],
8921
"10": [
90-
"versions.yml:md5,4af58a090ba71ffe3af4c39b26cae34e"
22+
[
23+
"TRUVARI_BENCH",
24+
"truvari",
25+
"5.4.0"
26+
]
9127
],
9228
"2": [
9329
[
@@ -233,20 +169,98 @@
233169
"test.tp-comp.vcf.gz:md5,68b329da9893e34099c7d8ad5cb9c940"
234170
]
235171
],
236-
"versions": [
237-
"versions.yml:md5,4af58a090ba71ffe3af4c39b26cae34e"
172+
"versions_truvari": [
173+
[
174+
"TRUVARI_BENCH",
175+
"truvari",
176+
"5.4.0"
177+
]
238178
]
239179
},
240180
{
241-
"TRUVARI_BENCH": {
242-
"truvari": "5.3.0)"
243-
}
181+
"versions_truvari": [
182+
[
183+
"TRUVARI_BENCH",
184+
"truvari",
185+
"5.4.0"
186+
]
187+
]
188+
}
189+
],
190+
"meta": {
191+
"nf-test": "0.9.3",
192+
"nextflow": "25.04.3"
193+
},
194+
"timestamp": "2026-02-13T14:56:31.307328807"
195+
},
196+
"homo sapiens - simulated sv - without bed": {
197+
"content": [
198+
"VcfFile [chromosomes=[chr21], sampleCount=1, variantCount=136, phased=false, phasedAutodetect=false]",
199+
"test.fn.vcf.gz.tbi",
200+
"VcfFile [chromosomes=[chr21], sampleCount=1, variantCount=136, phased=false, phasedAutodetect=false]",
201+
"test.fp.vcf.gz.tbi",
202+
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
203+
"test.tp-base.vcf.gz.tbi",
204+
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
205+
"test.tp-comp.vcf.gz.tbi",
206+
"test.log.txt",
207+
[
208+
[
209+
{
210+
"id": "test"
211+
},
212+
"test.summary.json:md5,aff467e3dbccf2c00a7aa81c2a36f62a"
213+
]
214+
],
215+
{
216+
"versions_truvari": [
217+
[
218+
"TRUVARI_BENCH",
219+
"truvari",
220+
"5.4.0"
221+
]
222+
]
223+
}
224+
],
225+
"meta": {
226+
"nf-test": "0.9.3",
227+
"nextflow": "25.04.3"
228+
},
229+
"timestamp": "2026-02-13T14:55:57.915305217"
230+
},
231+
"homo sapiens - simulated sv - with bed": {
232+
"content": [
233+
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
234+
"test.fn.vcf.gz.tbi",
235+
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
236+
"test.fp.vcf.gz.tbi",
237+
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
238+
"test.tp-base.vcf.gz.tbi",
239+
"VcfFile [chromosomes=[], sampleCount=1, variantCount=0, phased=true, phasedAutodetect=true]",
240+
"test.tp-comp.vcf.gz.tbi",
241+
"test.log.txt",
242+
[
243+
[
244+
{
245+
"id": "test"
246+
},
247+
"test.summary.json:md5,397452f6fd093809aee763a3d2310552"
248+
]
249+
],
250+
{
251+
"versions_truvari": [
252+
[
253+
"TRUVARI_BENCH",
254+
"truvari",
255+
"5.4.0"
256+
]
257+
]
244258
}
245259
],
246260
"meta": {
247-
"nf-test": "0.8.4",
248-
"nextflow": "25.04.7"
261+
"nf-test": "0.9.3",
262+
"nextflow": "25.04.3"
249263
},
250-
"timestamp": "2025-11-17T15:23:19.329822"
264+
"timestamp": "2026-02-13T14:56:15.650693746"
251265
}
252266
}

modules/nf-core/truvari/consistency/environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ channels:
44
- conda-forge
55
- bioconda
66
dependencies:
7-
- bioconda::truvari=5.3.0
7+
- bioconda::truvari=5.4.0

modules/nf-core/truvari/consistency/main.nf

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@ process TRUVARI_CONSISTENCY {
55

66
conda "${moduleDir}/environment.yml"
77
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
8-
'https://depot.galaxyproject.org/singularity/truvari:5.3.0--pyhdfd78af_0':
9-
'biocontainers/truvari:5.3.0--pyhdfd78af_0' }"
8+
'https://depot.galaxyproject.org/singularity/truvari:5.4.0--pyhdfd78af_0':
9+
'biocontainers/truvari:5.4.0--pyhdfd78af_0' }"
1010

1111
input:
1212
tuple val(meta), path(vcfs)
1313

1414
output:
1515
tuple val(meta), path("*.{txt,json}") , emit: consistency
16-
path "versions.yml" , emit: versions
16+
tuple val("${task.process}"), val('truvari'), eval("truvari version 2>&1 | sed 's/Truvari v//'"), topic: versions, emit: versions_truvari
1717

1818
when:
1919
task.ext.when == null || task.ext.when
@@ -29,23 +29,13 @@ process TRUVARI_CONSISTENCY {
2929
$args \\
3030
$vcfs > ${prefix}.${extension}
3131
32-
cat <<-END_VERSIONS > versions.yml
33-
"${task.process}":
34-
truvari: \$(echo \$(truvari version 2>&1) | sed 's/^Truvari v//' ))
35-
END_VERSIONS
3632
"""
3733

3834
stub:
39-
def args = task.ext.args ?: ''
4035
def prefix = task.ext.prefix ?: "${meta.id}"
4136
def extension = args.contains("-j") ? "json" : "txt"
4237

4338
"""
4439
touch ${prefix}.${extension}
45-
46-
cat <<-END_VERSIONS > versions.yml
47-
"${task.process}":
48-
truvari: \$(echo \$(truvari version 2>&1) | sed 's/^Truvari v//' ))
49-
END_VERSIONS
5040
"""
5141
}

0 commit comments

Comments
 (0)