diff --git a/modules/nf-core/elprep/filter/meta.yml b/modules/nf-core/elprep/filter/meta.yml index 51ae6deffeaa..51af18741083 100644 --- a/modules/nf-core/elprep/filter/meta.yml +++ b/modules/nf-core/elprep/filter/meta.yml @@ -115,6 +115,7 @@ output: type: file description: BAM/SAM file pattern: "*.{bam,sam}" + ontologies: [] logs: - - meta: type: map @@ -125,6 +126,7 @@ output: type: file description: Log file pattern: "elprep-*.log" + ontologies: [] metrics: - - meta: type: map @@ -135,6 +137,7 @@ output: type: file description: Metrics file pattern: "*.{metrics.txt}" + ontologies: [] recall: - - meta: type: map @@ -145,6 +148,7 @@ output: type: file description: Recall file pattern: "*.{recall}" + ontologies: [] gvcf: - - meta: type: map @@ -155,6 +159,7 @@ output: type: file description: VCF file pattern: "*.{vcf.gz}" + ontologies: [] table: - - meta: type: map @@ -165,6 +170,7 @@ output: type: file description: Table pattern: "*.{table}" + ontologies: [] activity_profile: - - meta: type: map @@ -175,6 +181,7 @@ output: type: file description: Activity profile pattern: "*.{activity_profile.igv}" + ontologies: [] assembly_regions: - - meta: type: map @@ -185,6 +192,7 @@ output: type: file description: Assembly regions pattern: "*.{assembly_regions.igv}" + ontologies: [] versions: - versions.yml: type: file diff --git a/modules/nf-core/trimgalore/main.nf b/modules/nf-core/trimgalore/main.nf index 5fe53669f766..d974f7b1dc08 100644 --- a/modules/nf-core/trimgalore/main.nf +++ b/modules/nf-core/trimgalore/main.nf @@ -16,7 +16,9 @@ process TRIMGALORE { tuple val(meta), path("*unpaired{,_1,_2}.fq.gz") , emit: unpaired, optional: true tuple val(meta), path("*.html") , emit: html, optional: true tuple val(meta), path("*.zip") , emit: zip, optional: true - path "versions.yml" , emit: versions + tuple val("${task.process}"), val('trim_galore'), eval("trim_galore --version 2>&1 | grep -Eo '[0-9]+(\\.[0-9]+)+'"), topic: versions, emit: versions_trim_galore + tuple val("${task.process}"), val('cutadapt'), eval("echo \$(cutadapt --version 2>&1)"), topic: versions, emit: versions_cutadapt + tuple val("${task.process}"), val('pigz'), eval("echo \$( pigz --version 2>&1 | sed 's/pigz //g' )"), topic: versions, emit: versions_pigz when: task.ext.when == null || task.ext.when @@ -52,13 +54,6 @@ process TRIMGALORE { --cores ${cores} \\ --gzip \\ ${prefix}.fastq.gz - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - trimgalore: \$(echo \$(trim_galore --version 2>&1) | sed 's/^.*version //; s/Last.*\$//') - cutadapt: \$(cutadapt --version) - pigz: \$( pigz --version 2>&1 | sed 's/pigz //g' ) - END_VERSIONS """ } else { @@ -72,13 +67,6 @@ process TRIMGALORE { --gzip \\ ${prefix}_1.fastq.gz \\ ${prefix}_2.fastq.gz - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - trimgalore: \$(echo \$(trim_galore --version 2>&1) | sed 's/^.*version //; s/Last.*\$//') - cutadapt: \$(cutadapt --version) - pigz: \$( pigz --version 2>&1 | sed 's/pigz //g' ) - END_VERSIONS """ } @@ -96,12 +84,5 @@ process TRIMGALORE { } """ ${output_command} - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - trimgalore: \$(echo \$(trim_galore --version 2>&1) | sed 's/^.*version //; s/Last.*\$//') - cutadapt: \$(cutadapt --version) - pigz: \$( pigz --version 2>&1 | sed 's/pigz //g' ) - END_VERSIONS """ } diff --git a/modules/nf-core/trimgalore/meta.yml b/modules/nf-core/trimgalore/meta.yml index 43ac961cb4e7..3c0fd15edf73 100644 --- a/modules/nf-core/trimgalore/meta.yml +++ b/modules/nf-core/trimgalore/meta.yml @@ -16,85 +16,42 @@ tools: licence: ["GPL-3.0-or-later"] identifier: "" input: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - reads: - type: file - description: | - List of input FastQ files of size 1 and 2 for single-end and paired-end data, - respectively. - ontologies: [] + - reads: + type: array + description: List of input FastQ files of size 1 and 2 for single-end and paired-end data, respectively. + ontologies: [] output: reads: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - "*{3prime,5prime,trimmed,val}{,_1,_2}.fq.gz": - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - pattern: "*{3prime,5prime,trimmed,val}{,_1,_2}.fq.gz" + type: array # Matches the tuple val(meta), path(...) in main.nf + description: Trimmed FastQ file(s). + pattern: "*{3prime,5prime,trimmed,val}{,_1,_2}.fq.gz" log: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - "*report.txt": - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - pattern: "*_{report.txt}" + type: file + description: Log file generated by Trim Galore!. + pattern: "*report.txt" unpaired: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - "*unpaired{,_1,_2}.fq.gz": - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - pattern: "*unpaired*.fq.gz" + type: file + description: Unpaired FastQ file(s) generated when processing paired-end data. + pattern: "*unpaired*.fq.gz" html: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - "*.html": - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - pattern: "*_{fastqc.html}" + type: file + description: FastQC report HTML file generated by Trim Galore!. + pattern: "*.html" zip: - - - meta: - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - - "*.zip": - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] - pattern: "*_{fastqc.zip}" - versions: - - versions.yml: - type: file - description: File containing software versions - pattern: "versions.yml" - ontologies: - - edam: http://edamontology.org/format_3750 # YAML + - - meta + - "*.zip" + versions_trim_galore: + type: array # Matches the tuple [task.process, 'trim_galore', version] + description: Trim Galore! version information. + pattern: "*" + versions_cutadapt: + type: array + description: Cutadapt version information (Trim Galore! dependency). + pattern: "*" + versions_pigz: + type: array + description: pigz version information (used for parallel compression/decompression). + pattern: "*" authors: - "@drpatelh" - "@ewels" diff --git a/modules/nf-core/trimgalore/tests/main.nf.test b/modules/nf-core/trimgalore/tests/main.nf.test index c01672c49b9e..31ea61cacaad 100644 --- a/modules/nf-core/trimgalore/tests/main.nf.test +++ b/modules/nf-core/trimgalore/tests/main.nf.test @@ -39,7 +39,7 @@ nextflow_process { { assert path(process.out.log.get(0).get(1)).getText().contains(report1_line) } } }, - { assert snapshot(path(process.out.versions.get(0)).yaml).match() }, + { assert snapshot(process.out.versions_trim_galore).match() }, ) } } @@ -62,8 +62,7 @@ nextflow_process { assertAll( { assert process.success }, { assert snapshot( - process.out, - path(process.out.versions.get(0)).yaml + process.out ).match() }, ) } @@ -121,7 +120,7 @@ nextflow_process { { assert path(process.out.log.get(0).get(1).get(1)).getText().contains(report2_line) } } }, - { assert snapshot(path(process.out.versions.get(0)).yaml).match() }, + { assert snapshot(process.out.versions_trim_galore).match() }, ) } } @@ -152,7 +151,7 @@ nextflow_process { assertAll( { assert process.success }, { assert snapshot( - path(process.out.versions.get(0)).yaml, + process.out.versions_trim_galore, process.out.reads, process.out.unpaired ).match() }, @@ -181,7 +180,7 @@ nextflow_process { assertAll( { assert process.success }, { assert snapshot(process.out).match() }, - { assert snapshot(path(process.out.versions.get(0)).yaml).match("versions") }, + { assert snapshot(process.out.versions_trim_galore).match("versions") } ) } } diff --git a/modules/nf-core/trimgalore/tests/main.nf.test.snap b/modules/nf-core/trimgalore/tests/main.nf.test.snap index c454ad521f63..f4dad84f3cc6 100644 --- a/modules/nf-core/trimgalore/tests/main.nf.test.snap +++ b/modules/nf-core/trimgalore/tests/main.nf.test.snap @@ -1,19 +1,19 @@ { "test_trimgalore_single_end": { "content": [ - { - "TRIMGALORE": { - "trimgalore": "0.6.10", - "cutadapt": 4.9, - "pigz": 2.8 - } - } + [ + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] + ] ], "meta": { - "nf-test": "0.9.2", - "nextflow": "24.10.3" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-01-06T12:25:01.330769598" + "timestamp": "2025-10-29T15:29:36.5109" }, "test_trimgalore_single_end - stub": { "content": [ @@ -46,7 +46,25 @@ ], "5": [ - "versions.yml:md5,5928323d579768de37e83c56c821757f" + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] + ], + "6": [ + [ + "TRIMGALORE", + "cutadapt", + "4.9" + ] + ], + "7": [ + [ + "TRIMGALORE", + "pigz", + "2.8" + ] ], "html": [ @@ -72,26 +90,37 @@ "unpaired": [ ], - "versions": [ - "versions.yml:md5,5928323d579768de37e83c56c821757f" + "versions_cutadapt": [ + [ + "TRIMGALORE", + "cutadapt", + "4.9" + ] + ], + "versions_pigz": [ + [ + "TRIMGALORE", + "pigz", + "2.8" + ] + ], + "versions_trim_galore": [ + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] ], "zip": [ ] - }, - { - "TRIMGALORE": { - "trimgalore": "0.6.10", - "cutadapt": 4.9, - "pigz": 2.8 - } } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "24.10.3" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-01-06T12:25:15.582246999" + "timestamp": "2025-10-29T12:05:37.755723" }, "test_trimgalore_paired_end - stub": { "content": [ @@ -130,7 +159,25 @@ ], "5": [ - "versions.yml:md5,5928323d579768de37e83c56c821757f" + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] + ], + "6": [ + [ + "TRIMGALORE", + "cutadapt", + "4.9" + ] + ], + "7": [ + [ + "TRIMGALORE", + "pigz", + "2.8" + ] ], "html": [ @@ -162,8 +209,26 @@ "unpaired": [ ], - "versions": [ - "versions.yml:md5,5928323d579768de37e83c56c821757f" + "versions_cutadapt": [ + [ + "TRIMGALORE", + "cutadapt", + "4.9" + ] + ], + "versions_pigz": [ + [ + "TRIMGALORE", + "pigz", + "2.8" + ] + ], + "versions_trim_galore": [ + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] ], "zip": [ @@ -171,52 +236,52 @@ } ], "meta": { - "nf-test": "0.9.2", - "nextflow": "24.10.3" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-01-06T12:26:05.201562315" + "timestamp": "2025-10-29T15:28:58.19021" }, "versions": { "content": [ - { - "TRIMGALORE": { - "trimgalore": "0.6.10", - "cutadapt": 4.9, - "pigz": 2.8 - } - } + [ + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] + ] ], "meta": { - "nf-test": "0.9.2", - "nextflow": "24.10.3" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-01-06T12:26:05.229598492" + "timestamp": "2025-10-29T15:28:58.254722" }, "test_trimgalore_paired_end": { "content": [ - { - "TRIMGALORE": { - "trimgalore": "0.6.10", - "cutadapt": 4.9, - "pigz": 2.8 - } - } + [ + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] + ] ], "meta": { - "nf-test": "0.9.2", - "nextflow": "24.10.3" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-01-06T12:25:33.510924538" + "timestamp": "2025-10-29T12:05:53.165749" }, "test_trimgalore_paired_end_keep_unpaired": { "content": [ - { - "TRIMGALORE": { - "trimgalore": "0.6.10", - "cutadapt": 4.9, - "pigz": 2.8 - } - }, + [ + [ + "TRIMGALORE", + "trim_galore", + "0.6.10" + ] + ], [ [ { @@ -243,9 +308,9 @@ ] ], "meta": { - "nf-test": "0.9.2", - "nextflow": "24.10.3" + "nf-test": "0.9.3", + "nextflow": "25.10.0" }, - "timestamp": "2025-01-06T12:25:46.461002981" + "timestamp": "2025-10-29T12:06:09.680104" } } \ No newline at end of file diff --git a/modules/nf-core/trimgalore/tests/nextflow.config b/modules/nf-core/trimgalore/tests/nextflow.config index d8e3ac13790c..4c974dcf37da 100644 --- a/modules/nf-core/trimgalore/tests/nextflow.config +++ b/modules/nf-core/trimgalore/tests/nextflow.config @@ -1,5 +1,7 @@ process { + withName: TRIMGALORE { ext.args = params.module_args } + }