Skip to content

Commit

Permalink
Merge branch 'master' into update-bclconvert
Browse files Browse the repository at this point in the history
  • Loading branch information
sateeshperi authored Nov 28, 2024
2 parents a63933e + 61e2a51 commit 189973a
Show file tree
Hide file tree
Showing 26 changed files with 1,197 additions and 56 deletions.
6 changes: 6 additions & 0 deletions modules/nf-core/gzrt/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json
channels:
- conda-forge
- bioconda
dependencies:
- "bioconda::gzrt=0.8"
53 changes: 53 additions & 0 deletions modules/nf-core/gzrt/main.nf
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
process GZRT {
tag "$meta.id"
label 'process_single'

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/gzrt:0.8--he4a0461_0':
'biocontainers/gzrt:0.8--he4a0461_0' }"

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

output:
tuple val(meta), path("*_recovered.fastq.gz"), emit: fastqrecovered
path "versions.yml" , emit: versions

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

script:
if (fastqgz.extension != "gz") {
error "GZRT works with .gz files only."
}

def prefix = task.ext.prefix ?: "${meta.id}"
"""
mkfifo temp_recovered.fastq
gzrecover -o temp_recovered.fastq ${fastqgz} &
gzip < temp_recovered.fastq > ${prefix}_recovered.fastq.gz
rm temp_recovered.fastq
soft_line="${task.process}"
ver_line="gzrt: \$(gzrecover -V |& sed '1!d ; s/gzrecover //')"
cat <<-END_VERSIONS > versions.yml
"\${soft_line}":
\${ver_line}
END_VERSIONS
"""

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
"""
echo "gzrt module" > ${prefix}_recovered.fastq && gzip ${prefix}_recovered.fastq
soft_line="${task.process}"
ver_line="gzrt: \$(gzrecover -V |& sed '1!d ; s/gzrecover //')"
cat <<-END_VERSIONS > versions.yml
"\${soft_line}":
\${ver_line}
END_VERSIONS
"""
}
55 changes: 55 additions & 0 deletions modules/nf-core/gzrt/meta.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: "gzrt"
description: gzrecover is a program that will attempt to extract any readable data out of a gzip file that has been corrupted
keywords:
- corrupted
- fastq
- recovery
tools:
- "gzrt":
description: "Unofficial build of the gzip Recovery Toolkit aka gzrecover"
homepage: "https://www.urbanophile.com/arenn/hacking/gzrt/gzrt.html"
documentation: "https://www.urbanophile.com/arenn/hacking/gzrt/gzrt.html"
tool_dev_url: "https://github.com/arenn/gzrt"
doi: "no DOI available"
licence: ["GPL v2"]
identifier: ""

input:
- - meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', single_end:false ]`
- fastqgz:
type: file
description: FASTQ.gz file
pattern: "*.{gz}"
ontologies:
- edam: "http://edamontology.org/format_3989"

output:
- fastqrecovered:
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. `[ id:'sample1', single_end:false ]`
- "*_recovered.fastq.gz":
type: file
description: Recovered FASTQ.gz file
pattern: "*.{gz}"
ontologies:
- edam: "http://edamontology.org/format_3989"

- versions:
- "versions.yml":
type: file
description: File containing software versions
pattern: "versions.yml"

authors:
- "@mazzalab"
maintainers:
- "@mazzalab"
- "@tm4zza"
55 changes: 55 additions & 0 deletions modules/nf-core/gzrt/tests/main.nf.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
nextflow_process {

name "Test Process GZRT"
script "../main.nf"
process "GZRT"

tag "modules"
tag "modules_nfcore"
tag "gzrt"

test("Run gzrt on 30 paired-end reads - fastq.gz") {

when {
process {
"""
input[0] = [
[ id:'test', single_end:false ], // meta map
file('https://raw.githubusercontent.com/nf-core/test-datasets/fastqrepair/testdata/test_30reads_R1.fastq.gz', checkIfExists: true),
]
"""
}
}

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

}

test("Run gzrt on 30 paired-end reads - fastq.gz - stub") {
options "-stub"

when {
process {
"""
input[0] = [
[ id:'test', single_end:false ], // meta map
file('https://raw.githubusercontent.com/nf-core/test-datasets/fastqrepair/testdata/test_30reads_R1.fastq.gz', checkIfExists: true),
]
"""
}
}

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

}
72 changes: 72 additions & 0 deletions modules/nf-core/gzrt/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
{
"Run gzrt on 30 paired-end reads - fastq.gz": {
"content": [
{
"0": [
[
{
"id": "test",
"single_end": false
},
"test_recovered.fastq.gz:md5,5eca10f954656478b5af96868222eec4"
]
],
"1": [
"versions.yml:md5,b9467d4cb860eb2941a2078a3dd3cf41"
],
"fastqrecovered": [
[
{
"id": "test",
"single_end": false
},
"test_recovered.fastq.gz:md5,5eca10f954656478b5af96868222eec4"
]
],
"versions": [
"versions.yml:md5,b9467d4cb860eb2941a2078a3dd3cf41"
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-27T20:04:34.442659"
},
"Run gzrt on 30 paired-end reads - fastq.gz - stub": {
"content": [
{
"0": [
[
{
"id": "test",
"single_end": false
},
"test_recovered.fastq.gz:md5,0f8202ea19c8ce3f69f4413bf139b29c"
]
],
"1": [
"versions.yml:md5,b9467d4cb860eb2941a2078a3dd3cf41"
],
"fastqrecovered": [
[
{
"id": "test",
"single_end": false
},
"test_recovered.fastq.gz:md5,0f8202ea19c8ce3f69f4413bf139b29c"
]
],
"versions": [
"versions.yml:md5,b9467d4cb860eb2941a2078a3dd3cf41"
]
}
],
"meta": {
"nf-test": "0.9.2",
"nextflow": "24.10.1"
},
"timestamp": "2024-11-27T20:04:46.182206"
}
}
2 changes: 1 addition & 1 deletion modules/nf-core/hifiasm/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ channels:
- conda-forge
- bioconda
dependencies:
- bioconda::hifiasm=0.20.0
- bioconda::hifiasm=0.21.0
4 changes: 2 additions & 2 deletions modules/nf-core/hifiasm/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ process HIFIASM {

conda "${moduleDir}/environment.yml"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/hifiasm:0.20.0--h43eeafb_0' :
'biocontainers/hifiasm:0.20.0--h43eeafb_0' }"
'https://depot.galaxyproject.org/singularity/hifiasm:0.21.0--h43eeafb_0' :
'biocontainers/hifiasm:0.21.0--h43eeafb_0' }"

input:
tuple val(meta) , path(reads)
Expand Down
34 changes: 17 additions & 17 deletions modules/nf-core/hifiasm/tests/main.nf.test.snap
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,14 @@
]
],
[
"versions.yml:md5,6a23f7ea8bae71905c537cd521cffcb8"
"versions.yml:md5,4c02458be007ef6776c2991fbb13f879"
]
],
"meta": {
"nf-test": "0.9.0",
"nextflow": "24.04.4"
"nf-test": "0.9.2",
"nextflow": "24.10.1"
},
"timestamp": "2024-10-23T14:01:04.528764919"
"timestamp": "2024-11-28T10:51:30.175326435"
},
"homo_sapiens pacbio hifi [fastq, [,], [fastq, fastq] ]": {
"content": [
Expand Down Expand Up @@ -78,14 +78,14 @@
]
],
[
"versions.yml:md5,6a23f7ea8bae71905c537cd521cffcb8"
"versions.yml:md5,4c02458be007ef6776c2991fbb13f879"
]
],
"meta": {
"nf-test": "0.9.0",
"nextflow": "24.04.4"
"nf-test": "0.9.2",
"nextflow": "24.10.1"
},
"timestamp": "2024-10-23T14:08:48.081396092"
"timestamp": "2024-11-28T10:52:15.111066189"
},
"homo_sapiens pacbio hifi [fastq, [,], [,] ] - stub": {
"content": [
Expand Down Expand Up @@ -115,7 +115,7 @@
]
],
"11": [
"versions.yml:md5,6a23f7ea8bae71905c537cd521cffcb8"
"versions.yml:md5,4c02458be007ef6776c2991fbb13f879"
],
"2": [
[
Expand Down Expand Up @@ -270,15 +270,15 @@
]
],
"versions": [
"versions.yml:md5,6a23f7ea8bae71905c537cd521cffcb8"
"versions.yml:md5,4c02458be007ef6776c2991fbb13f879"
]
}
],
"meta": {
"nf-test": "0.9.0",
"nextflow": "24.04.4"
"nf-test": "0.9.2",
"nextflow": "24.10.1"
},
"timestamp": "2024-10-23T14:09:13.475508542"
"timestamp": "2024-11-28T10:53:06.003871811"
},
"homo_sapiens pacbio hifi [fastq, [yak, yak], [,] ]": {
"content": [
Expand Down Expand Up @@ -307,13 +307,13 @@
]
],
[
"versions.yml:md5,6a23f7ea8bae71905c537cd521cffcb8"
"versions.yml:md5,4c02458be007ef6776c2991fbb13f879"
]
],
"meta": {
"nf-test": "0.9.0",
"nextflow": "24.04.4"
"nf-test": "0.9.2",
"nextflow": "24.10.1"
},
"timestamp": "2024-10-23T13:33:47.765243676"
"timestamp": "2024-11-28T10:51:45.301359171"
}
}
1 change: 0 additions & 1 deletion modules/nf-core/mafft/guidetree/meta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,4 +44,3 @@ authors:
- "@luisas"
maintainers:
- "@luisas"

5 changes: 5 additions & 0 deletions modules/nf-core/mgikit/demultiplex/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
channels:
- conda-forge
- bioconda
dependencies:
- bioconda::mgikit=0.1.6
Loading

0 comments on commit 189973a

Please sign in to comment.