Skip to content

Commit

Permalink
Merge branch 'master' into islandpath
Browse files Browse the repository at this point in the history
* master:
  Ngscheckmate (nf-core#3094)
  New module Mindagap (nf-core#2860)
  Coreograph Module (nf-core#3201)
  new module wisecondorx/newref (nf-core#3212)
  Add core detection test data to config (nf-core#3199)
  Collectinsertsizemetrics (nf-core#3179)
  update appropriate label for freyja boot (nf-core#3215)
  Emit files from uncompression utilities (nf-core#3144)
  new tool: art_illumina (nf-core#3162)
  Addition of new module: Issue nf-core#3113 Survivor/filter (nf-core#3168)
  Removed -1 in CPU size specification for samtools in BWA module (nf-core#3205)
  nf-test Transition CI (nf-core#3191)
  new module: sourmash/index (nf-core#3163)
  Chopper (nf-core#3174)
  Update mapdage2 module (nf-core#3185)
  Add imaging test data in config (nf-core#3190)
  New subworkflow: Fastq_fastp_trim_fastqc (nf-core#3146)
  • Loading branch information
jvfe committed Mar 30, 2023
2 parents 1b97bcb + 3cfd245 commit 1e2dd45
Show file tree
Hide file tree
Showing 88 changed files with 2,657 additions and 65 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/nf-core-linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
with:
python-version: "3.x"

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
# HACK
if: startsWith( matrix.tags, 'subworkflow' ) != true

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: /usr/local/bin/nextflow
key: ${{ runner.os }}
Expand Down
180 changes: 180 additions & 0 deletions .github/workflows/nf-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,180 @@
name: nf-test
on:
push:
branches: [master]
pull_request:
branches: [master]
merge_group:
types: [checks_requested]
branches: [master]

# Cancel if a newer run is started
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
changes:
name: Check for changes
runs-on: ubuntu-latest
outputs:
# Expose matched filters as job 'modules' output variable
modules: ${{ steps.filter.outputs.changes }}
steps:
- uses: actions/checkout@v3

- uses: dorny/paths-filter@v2
id: filter
with:
filters: "tests/config/nftest_modules.yml"

test:
runs-on: ubuntu-20.04

name: ${{ matrix.tags }} ${{ matrix.profile }}
needs: changes
if: needs.changes.outputs.modules != '[]'
strategy:
fail-fast: false
matrix:
tags: ["${{ fromJson(needs.changes.outputs.modules) }}"]
profile: ["docker", "singularity", "conda"]
exclude:
- profile: "conda"
tags: bases2fastq
- profile: "conda"
tags: bcl2fastq
- profile: "conda"
tags: bclconvert
- profile: "conda"
tags: cellranger/count
- profile: "conda"
tags: cellranger/mkfastq
- profile: "conda"
tags: cellranger/mkgtf
- profile: "conda"
tags: cellranger/mkref
- profile: "conda"
tags: deepvariant
- profile: "conda"
tags: ensemblvep/vep
- profile: "conda"
tags: fastk/fastk
- profile: "conda"
tags: fastk/histex
- profile: "conda"
tags: fastk/merge
- profile: "conda"
tags: fcs/fcsadaptor
- profile: "conda"
tags: fcs/fcsgx
- profile: "conda"
tags: gatk4/cnnscorevariants
- profile: "conda"
tags: gatk4/determinegermlinecontigploidy
- profile: "conda"
tags: genescopefk
- profile: "conda"
tags: ilastik/multicut
- profile: "conda"
tags: ilastik/pixelclassification
- profile: "conda"
tags: imputeme/vcftoprs
- profile: "conda"
tags: merquryfk/katcomp
- profile: "conda"
tags: merquryfk/katgc
- profile: "conda"
tags: merquryfk/merquryfk
- profile: "conda"
tags: merquryfk/ploidyplot
- profile: "conda"
tags: sentieon/bwaindex
- profile: "conda"
tags: sentieon/bwamem
- profile: "conda"
tags: universc
- profile: "singularity"
tags: universc
- profile: "conda"
tags: subworkflows/vcf_annotate_ensemblvep
env:
NXF_ANSI_LOG: false
SENTIEON_LICENSE_BASE64: ${{ secrets.SENTIEON_LICENSE_BASE64 }}
steps:
- uses: actions/checkout@v3

- uses: actions/cache@v3
with:
path: /usr/local/bin/nextflow
key: ${{ runner.os }}
restore-keys: |
${{ runner.os }}-nextflow-
- name: Install Nextflow
env:
CAPSULE_LOG: none
run: |
wget -qO- get.nextflow.io | bash
sudo mv nextflow /usr/local/bin/
- name: Cache nf-test installation
id: cache-software
uses: actions/cache@v3
with:
path: |
/usr/local/bin/nf-test
/home/runner/.nf-test/nf-test.jar
key: ${{ runner.os }}-nftest

- name: Install nf-test
if: steps.cache-software.outputs.cache-hit != 'true'
run: |
wget -qO- https://code.askimed.com/install/nf-test | bash
sudo mv nf-test /usr/local/bin/
- name: Set up Singularity
if: matrix.profile == 'singularity'
uses: eWaterCycle/setup-singularity@v5
with:
singularity-version: 3.7.1

- name: Set up miniconda
if: matrix.profile == 'conda'
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
channels: conda-forge,bioconda,defaults
python-version: ${{ matrix.python-version }}

- name: Conda setup
if: matrix.profile == 'conda'
run: |
conda clean -a
conda install -n base conda-libmamba-solver
conda config --set solver libmamba
# Set up secrets
- name: Set up nextflow secrets
if: env.SENTIEON_LICENSE_BASE64 != null
run: |
nextflow secrets set SENTIEON_LICENSE_BASE64 ${{ secrets.SENTIEON_LICENSE_BASE64 }}
nextflow secrets set SENTIEON_AUTH_MECH_BASE64 ${{ secrets.SENTIEON_AUTH_MECH_BASE64 }}
SENTIEON_ENCRYPTION_KEY=$(echo -n "${{ secrets.ENCRYPTION_KEY_BASE64 }}" | base64 -d)
SENTIEON_LICENSE_MESSAGE=$(echo -n "${{ secrets.LICENSE_MESSAGE_BASE64 }}" | base64 -d)
SENTIEON_AUTH_DATA=$(python tests/modules/nf-core/sentieon/license_message.py encrypt --key "$SENTIEON_ENCRYPTION_KEY" --message "$SENTIEON_LICENSE_MESSAGE")
SENTIEON_AUTH_DATA_BASE64=$(echo -n "$SENTIEON_AUTH_DATA" | base64 -w 0)
nextflow secrets set SENTIEON_AUTH_DATA_BASE64 $SENTIEON_AUTH_DATA_BASE64
# Test the module
- name: Run nf-test
run: |
nf-test test \
--profile=${{ matrix.profile }} \
--tag ${{ matrix.tags }} \
--tap=test.tap
- uses: pcolby/tap-summary@v1
with:
path: >-
test.tap
6 changes: 4 additions & 2 deletions .github/workflows/pytest-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ jobs:
tags: universc
- profile: "conda"
tags: subworkflows/vcf_annotate_ensemblvep
- profile: "conda"
tags: coreograph
env:
NXF_ANSI_LOG: false
SENTIEON_LICENSE_BASE64: ${{ secrets.SENTIEON_LICENSE_BASE64 }}
Expand All @@ -109,7 +111,7 @@ jobs:
with:
python-version: "3.x"

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
Expand All @@ -119,7 +121,7 @@ jobs:
- name: Install Python dependencies
run: python -m pip install --upgrade pip pytest-workflow cryptography

- uses: actions/cache@v2
- uses: actions/cache@v3
with:
path: /usr/local/bin/nextflow
key: ${{ runner.os }}
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
work/
results/
test_output/
.nf-test/
output/
.DS_Store
*.code-workspace
Expand Down
Empty file added logg
Empty file.
71 changes: 71 additions & 0 deletions modules/nf-core/art/illumina/main.nf
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
process ART_ILLUMINA {

tag "$meta.id"
label 'process_single'

// WARN: Version information not provided by tool on CLI. Please update version string below when bumping container versions.
conda "bioconda::art=2016.06.05"
container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ?
'https://depot.galaxyproject.org/singularity/art:2016.06.05--h589041f_9':
'quay.io/biocontainers/art:2016.06.05--h589041f_9' }"

input:
tuple val(meta), path(fasta)
val(sequencing_system)
val(fold_coverage)
val(read_length)

output:
tuple val(meta), path("*.fq.gz"), emit: fastq
tuple val(meta), path("*.aln"), optional:true , emit: aln
tuple val(meta), path("*.sam"), optional:true , emit: sam
path "versions.yml" , emit: versions

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

script:
def args = task.ext.args ?: ''
def args2 = task.ext.args2 ?: ''
def prefix = task.ext.prefix ?: "${meta.id}"
def VERSION = '2016.06.05' // WARN: Version information not provided by tool on CLI. Please update this string when bumping container versions.
"""
art_illumina \\
-ss $sequencing_system \\
-i $fasta \\
-l $read_length \\
-f $fold_coverage \\
-o $prefix \\
$args
gzip \\
--no-name \\
$args2 \\
$prefix*.fq
cat <<-END_VERSIONS > versions.yml
"${task.process}":
art: $VERSION
END_VERSIONS
"""

stub:
def prefix = task.ext.prefix ?: "${meta.id}"
def VERSION = '2016.06.05'
"""
touch ${prefix}.fq.gz
touch ${prefix}1.fq.gz
touch ${prefix}2.fq.gz
touch ${prefix}.aln
touch ${prefix}1.aln
touch ${prefix}2.aln
touch ${prefix}.sam
touch ${prefix}1.sam
touch ${prefix}2.sam
cat <<-END_VERSIONS > versions.yml
"${task.process}":
art: $VERSION
END_VERSIONS
"""
}
61 changes: 61 additions & 0 deletions modules/nf-core/art/illumina/meta.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: "art_illumina"
description: Simulation tool to generate synthetic Illumina next-generation sequencing reads
keywords:
- fastq
- fasta
- illumina
- simulate
tools:
- "art":
description: "ART is a set of simulation tools to generate synthetic next-generation sequencing reads. ART simulates sequencing reads by mimicking real sequencing process with empirical error models or quality profiles summarized from large recalibrated sequencing data. ART can also simulate reads using user own read error model or quality profiles. "
homepage: "https://www.niehs.nih.gov/research/resources/software/biostatistics/art/index.cfm"
documentation: ""
tool_dev_url: ""
doi: "https://doi.org/10.1093/bioinformatics/btr708"
licence: "GPL version 3 license"

input:
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. [ id:'test' ]
- fasta:
type: file
description: FASTA file of input DNA/RNA reference
pattern: "*.{fasta,fa}"
- sequencing_system:
type: string
description: The name of Illumina sequencing system of the built-in profile used for simulation
- fold_coverage:
type: integer
description: The fold of read coverage to be simulated or number of reads/read pairs generated for each amplicon
- read_length:
type: integer
description: The length of reads to be simulated

output:
- versions:
type: file
description: File containing software versions
pattern: "versions.yml"
- meta:
type: map
description: |
Groovy Map containing sample information
e.g. [ id:'test', single_end:false ]
- fastq:
type: file
description: Simulated reads
pattern: "*.fq.gz"
- aln:
type: file
description: OPTIONAL Alignment file of the simulated reads. Enabled by default, to disable, use -na/--noALN.
pattern: "*.aln"
- sam:
type: file
description: OPTIONAL Alignment file in SAM format of the simulated reads. Enabled with -sam/--samout.
pattern: "*.sam"

authors:
- "@MarieLataretu"
2 changes: 1 addition & 1 deletion modules/nf-core/bwa/sampe/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ process BWA_SAMPE {
$read_group \\
\$INDEX \\
$sai \\
$reads | samtools sort -@ ${task.cpus - 1} -O bam - > ${prefix}.bam
$reads | samtools sort -@ ${task.cpus} -O bam - > ${prefix}.bam
cat <<-END_VERSIONS > versions.yml
"${task.process}":
Expand Down
Loading

0 comments on commit 1e2dd45

Please sign in to comment.