Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
12e0fe9
rebase - git pull --rebase upstream master - merge conflicts
eit-maxlcummins Dec 4, 2025
526467b
add missing test for main.nf.test
eit-maxlcummins Oct 28, 2025
3cacf33
simplify string replacement for trinity version eval to remove use of…
eit-maxlcummins Oct 28, 2025
9d7bbc8
update meta.yml to capture new version topics change
eit-maxlcummins Oct 28, 2025
4bad473
update assemblyscan to v1.0.0, allowing json or tsv output
eit-maxlcummins Dec 4, 2025
1cd9ffb
[automated] Fix linting with Prettier
nf-core-bot Dec 15, 2025
c355258
Merge branch 'master' into assemblyscan_1.0.0
prototaxites Dec 15, 2025
4eda94b
update versions capturing to new approach and update snapshot
charles-plessy Jan 15, 2026
7230bd8
add charles-plessy to authors
eit-maxlcummins Jan 15, 2026
1fc8eef
Merge branch 'master' into assemblyscan_1.0.0
SPPearce Jan 15, 2026
76df8c2
combine outputs into single channel
eit-maxlcummins Jan 15, 2026
8cfb23a
update meta.yml for dynamic report output and versions topic channel
eit-maxlcummins Jan 15, 2026
cfce70b
more fixes to meta.yml for versions topic
eit-maxlcummins Jan 15, 2026
4a03751
more fixes to meta.yml for versions topic
eit-maxlcummins Jan 15, 2026
809134c
manually add json test from @charles-plessy - some prior git cherry p…
eit-maxlcummins Jan 15, 2026
db9dd8f
lint module
eit-maxlcummins Jan 15, 2026
307b6f2
remove unnecessary optional flag post output channel merge
eit-maxlcummins Jan 15, 2026
cc0b8a5
final meta.yml changes :pray:
eit-maxlcummins Jan 15, 2026
58349e5
[automated] Fix linting with Prettier
nf-core-bot Jan 15, 2026
eb768a8
Merge branch 'master' into assemblyscan_1.0.0
eit-maxlcummins Jan 15, 2026
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
2 changes: 1 addition & 1 deletion modules/nf-core/assemblyscan/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ channels:
- conda-forge
- bioconda
dependencies:
- bioconda::assembly-scan=0.4.1
- bioconda::assembly-scan=1.0.0
27 changes: 17 additions & 10 deletions modules/nf-core/assemblyscan/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,34 @@ process ASSEMBLYSCAN {

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/assembly-scan:0.4.1--pyhdfd78af_0' :
'biocontainers/assembly-scan:0.4.1--pyhdfd78af_0' }"
'https://depot.galaxyproject.org/singularity/assembly-scan:1.0.0--pyhdfd78af_0' :
'biocontainers/assembly-scan:1.0.0--pyhdfd78af_0' }"

input:
tuple val(meta), path(assembly)

output:
tuple val(meta), path("*.json"), emit: json
path "versions.yml" , emit: versions
tuple val(meta), path("*.{json,tsv}"), emit: report
tuple val("${task.process}"), val('assemblyscan'), eval("assembly-scan --version 2>&1 | sed 's/^.*assembly-scan //; s/Using.*\$//'"), topic: versions, emit: versions_assemblyscan

when:
task.ext.when == null || task.ext.when

script:
def prefix = task.ext.prefix ?: "${meta.id}"
def args = task.ext.args ?: ''
def prefix = task.ext.prefix ?: "${meta.id}"
def file_format = (task.ext.args?.contains("--json")) ? "json" : "tsv"
"""
assembly-scan \\
${args} \\
${assembly} > ${prefix}.${file_format}
"""
assembly-scan ${assembly} > ${prefix}.json

cat <<-END_VERSIONS > versions.yml
"${task.process}":
assemblyscan: \$( assembly-scan --version 2>&1 | sed 's/^.*assembly-scan //; s/Using.*\$//' )
END_VERSIONS
stub:
def args = task.ext.args ?: ''
def prefix = task.ext.prefix ?: "${meta.id}"
def file_format = (task.ext.args?.contains("--json")) ? "json" : "tsv"
"""
touch ${prefix}.${file_format}
"""
}
38 changes: 28 additions & 10 deletions modules/nf-core/assemblyscan/meta.yml
Comment thread
eit-maxlcummins marked this conversation as resolved.
Original file line number Diff line number Diff line change
Expand Up @@ -25,28 +25,46 @@ input:
pattern: "*.fasta"
ontologies: []
output:
json:
report:
- - meta:
type: map
description: |
Groovy Map containing sample information
e.g. [ id:'test', single_end:false ]
- "*.json":
- "*.{json,tsv}":
type: file
description: Assembly statistics in JSON format
pattern: "*.json"
description: Assembly statistics in tsv or JSON format
pattern: "*.{json,tsv}"
ontologies:
- edam: http://edamontology.org/format_3475 # TSV
- edam: http://edamontology.org/format_3464 # JSON
versions_assemblyscan:
- - ${task.process}:
type: string
description: The process the versions were collected from
- assemblyscan:
type: string
description: The tool name
- "assembly-scan --version 2>&1 | sed 's/^.*assembly-scan //; s/Using.*\\$//'":
type: string
description: The command used to generate the version of the tool
topics:
versions:
- versions.yml:
type: file
description: File containing software versions
pattern: "versions.yml"
ontologies:
- edam: http://edamontology.org/format_3750 # YAML
- - ${task.process}:
type: string
description: The process the versions were collected from
- assemblyscan:
type: string
description: The tool name
- "assembly-scan --version 2>&1 | sed 's/^.*assembly-scan //; s/Using.*\\$//'":
type: string
description: The command used to generate the version of the tool
authors:
- "@sateeshperi"
- "@mjcipriano"
- "@eit-maxlcummins"
- "@charles-plessy"
maintainers:
- "@sateeshperi"
- "@mjcipriano"
- "@eit-maxlcummins"
5 changes: 5 additions & 0 deletions modules/nf-core/assemblyscan/tests/json.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
process {
withName: 'ASSEMBLYSCAN' {
ext.args = "--json"
}
}
42 changes: 42 additions & 0 deletions modules/nf-core/assemblyscan/tests/main.nf.test
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,27 @@ nextflow_process {
tag "modules_nfcore"
tag "assemblyscan"

test("genome.fasta - json") {

when {
config './json.config'
process {
"""
input[0] = [ [ id:'test', single_end:false ],
file(params.modules_testdata_base_path + 'genomics/sarscov2/genome/genome.fasta', checkIfExists: true)
]
"""
}
}

then {
assertAll(
{ assert process.success },
{ assert snapshot(process.out).match() }
)
}
}

test("genome.fasta") {

when {
Expand All @@ -26,4 +47,25 @@ nextflow_process {
)
}
}

test("genome.fasta - stub") {

options "-stub"
when {
process {
"""
input[0] = [ [ id:'test', single_end:false ],
file(params.modules_testdata_base_path + 'genomics/sarscov2/genome/genome.fasta', checkIfExists: true)
]
"""
}
}

then {
assertAll(
{ assert process.success },
{ assert snapshot(process.out).match() }
)
}
}
}
112 changes: 105 additions & 7 deletions modules/nf-core/assemblyscan/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -8,26 +8,124 @@
"id": "test",
"single_end": false
},
"test.json:md5,9140e3d43f2d676f62e1325ace5dd8bd"
"test.tsv:md5,d3bda95a4a6f65cd94adeccca998b0b6"
]
],
"1": [
"versions.yml:md5,406f16dbbbf8f98709caafe49ca10e21"
[
"ASSEMBLYSCAN",
"assemblyscan",
"1.0.0"
]
],
"report": [
[
{
"id": "test",
"single_end": false
},
"test.tsv:md5,d3bda95a4a6f65cd94adeccca998b0b6"
]
],
"versions_assemblyscan": [
[
"ASSEMBLYSCAN",
"assemblyscan",
"1.0.0"
]
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "25.04.6"
},
"timestamp": "2026-01-15T10:01:03.158484579"
},
"genome.fasta - json": {
"content": [
{
"0": [
[
{
"id": "test",
"single_end": false
},
"test.json:md5,bcef4e2bf296339c1ca7c513b483de96"
]
],
"1": [
[
"ASSEMBLYSCAN",
"assemblyscan",
"1.0.0"
]
],
"json": [
"report": [
[
{
"id": "test",
"single_end": false
},
"test.json:md5,9140e3d43f2d676f62e1325ace5dd8bd"
"test.json:md5,bcef4e2bf296339c1ca7c513b483de96"
]
],
"versions": [
"versions.yml:md5,406f16dbbbf8f98709caafe49ca10e21"
"versions_assemblyscan": [
[
"ASSEMBLYSCAN",
"assemblyscan",
"1.0.0"
]
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "25.04.6"
},
"timestamp": "2026-01-15T10:59:22.469878465"
},
"genome.fasta - stub": {
"content": [
{
"0": [
[
{
"id": "test",
"single_end": false
},
"test.tsv:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"1": [
[
"ASSEMBLYSCAN",
"assemblyscan",
"1.0.0"
]
],
"report": [
[
{
"id": "test",
"single_end": false
},
"test.tsv:md5,d41d8cd98f00b204e9800998ecf8427e"
]
],
"versions_assemblyscan": [
[
"ASSEMBLYSCAN",
"assemblyscan",
"1.0.0"
]
]
}
],
"timestamp": "2023-10-18T15:04:38.644743625"
"meta": {
"nf-test": "0.9.2",
"nextflow": "25.04.6"
},
"timestamp": "2026-01-15T10:01:08.630557227"
}
}