diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0bf047d57f..41d23c25be 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -52,6 +52,15 @@ jobs: NXF_VER: - "23.04.0" - "latest-everything" + exclude: + - tags: "sentieon/bwamem" + - tags: "sentieon/dedup" + - tags: "sentieon/dnascope" + - tags: "sentieon/dnascope_joint_germline" + - tags: "sentieon/dnascope_skip_filter" + - tags: "sentieon/haplotyper" + - tags: "sentieon/haplotyper_joint_germline" + - tags: "sentieon/haplotyper_skip_filter" env: NXF_ANSI_LOG: false TEST_DATA_BASE: "${{ github.workspace }}/test-datasets" diff --git a/CHANGELOG.md b/CHANGELOG.md index afe7020a22..fd648ec62d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,14 +14,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [#1335](https://github.com/nf-core/sarek/pull/1335) - Add index computation of `bcftools_annotations`, if not provided - [#1340](https://github.com/nf-core/sarek/pull/1340) - Adds Azure test profiles and megatests. - [#1372](https://github.com/nf-core/sarek/pull/1372) - Add NCBench test profile for Agilent datasets +- [#1409](https://github.com/nf-core/sarek/pull/1409) - Add params `modules_testdata_base_path` to test profile ### Changed -- [#1339](https://github.com/nf-core/sarek/pull/1339) - Update sentieon-modules +- [#1339](https://githu.com/nf-core/sarek/pull/1339), [#1401](https://github.com/nf-core/sarek/pull/1401) - Update sentieon-modules to Sentieon `202308.01` and adding support for running Sentieon with Conda and Apptainer - [#1344](https://github.com/nf-core/sarek/pull/1344) - Enable CRAM QC, when starting from variantcalling - [#1359](https://github.com/nf-core/sarek/pull/1359) - Removing params usage from local modules - [#1359](https://github.com/nf-core/sarek/pull/1359) - Removing params usage from local subworkflows - [#1360](https://github.com/nf-core/sarek/pull/1360) - Sync `TEMPLATE` with `tools` `2.11` +- [#1411](https://github.com/nf-core/sarek/pull/1411) - Temporally disable sentieon related tests ### Fixed @@ -32,7 +34,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [#1351](https://github.com/nf-core/sarek/pull/1351) - Fix params name for test profiles (`bcftools_annotations`) - [#1357](https://github.com/nf-core/sarek/pull/1364) - Fixed bug where samples were dropped while reconstituting BAM files - [#1373](https://github.com/nf-core/sarek/pull/1373) - Add `chr` prefix to NCBench bed file & enable trimming -- [#1373](https://github.com/nf-core/sarek/pull/1381) - Swap NGSCheckMate bed file for GATK.GRCh37 to one without the `chr` prefix +- [#1381](https://github.com/nf-core/sarek/pull/1381) - Swap NGSCheckMate bed file for GATK.GRCh37 to one without the `chr` prefix +- [#1383](https://github.com/nf-core/sarek/pull/1383) - Fix `--three_prime_clip_r{1,2}` parameter documentation +- [#1390](https://github.com/nf-core/sarek/pull/1390) - Fix badges in README +- [#1403](https://github.com/nf-core/sarek/pull/1403) - Fix intervals usage with dot in chromosome names ### Removed diff --git a/README.md b/README.md index 6df2cd5b09..e922c7c323 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,7 @@ nf-core/sarek + [![GitHub Actions CI Status](https://github.com/nf-core/sarek/workflows/nf-core%20CI/badge.svg)](https://github.com/nf-core/sarek/actions?query=workflow%3A%22nf-core+CI%22) [![GitHub Actions Linting Status](https://github.com/nf-core/sarek/workflows/nf-core%20linting/badge.svg)](https://github.com/nf-core/sarek/actions?query=workflow%3A%22nf-core+linting%22) [![AWS CI](https://img.shields.io/badge/CI%20tests-full%20size-FF9900?labelColor=000000&logo=Amazon%20AWS)](https://nf-co.re/sarek/results) @@ -40,7 +41,7 @@ Depending on the options and samples provided, the pipeline can currently perfor - Map Reads to Reference (`BWA-mem`, `BWA-mem2`, `dragmap` or `Sentieon BWA-mem`) - Process BAM file (`GATK MarkDuplicates`, `GATK BaseRecalibrator` and `GATK ApplyBQSR` or `Sentieon LocusCollector` and `Sentieon Dedup`) - Summarise alignment statistics (`samtools stats`, `mosdepth`) -- Variant calling (enabled by `--tools`, see [compatibility](#which-variant-calling-tool-is-implemented-for-which-data-type)): +- Variant calling (enabled by `--tools`, see [compatibility](https://nf-co.re/sarek/latest/docs/usage#which-variant-calling-tool-is-implemented-for-which-data-type)): - `ASCAT` - `CNVkit` - `Control-FREEC` diff --git a/conf/modules/deepvariant.config b/conf/modules/deepvariant.config index ff67bc1a4b..021990f7f6 100644 --- a/conf/modules/deepvariant.config +++ b/conf/modules/deepvariant.config @@ -17,7 +17,7 @@ process { withName: 'DEEPVARIANT' { ext.args = { params.wes ? "--model_type WES" : "--model_type WGS" } - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.deepvariant" : "${meta.id}.deepvariant.${intervals.simpleName}" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.deepvariant" : "${meta.id}.deepvariant.${intervals.baseName}" } ext.when = { params.tools && params.tools.split(',').contains('deepvariant') } publishDir = [ mode: params.publish_dir_mode, diff --git a/conf/modules/freebayes.config b/conf/modules/freebayes.config index a30ec62308..2c224aeffd 100644 --- a/conf/modules/freebayes.config +++ b/conf/modules/freebayes.config @@ -27,7 +27,7 @@ process { withName: 'FREEBAYES' { ext.args = { '--min-alternate-fraction 0.1 --min-mapping-quality 1' } //To make sure no naming conflicts ensure with module BCFTOOLS_SORT & the naming being correct in the output folder - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}" : "${meta.id}.${target_bed.simpleName}" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}" : "${meta.id}.${target_bed.baseName}" } ext.when = { params.tools && params.tools.split(',').contains('freebayes') } publishDir = [ enabled: false diff --git a/conf/modules/haplotypecaller.config b/conf/modules/haplotypecaller.config index f376f4f41d..d5b8a3db40 100644 --- a/conf/modules/haplotypecaller.config +++ b/conf/modules/haplotypecaller.config @@ -17,7 +17,7 @@ process { withName: 'GATK4_HAPLOTYPECALLER' { ext.args = { params.joint_germline ? "-ERC GVCF" : "" } - ext.prefix = { meta.num_intervals <= 1 ? ( params.joint_germline ? "${meta.id}.haplotypecaller.g" : "${meta.id}.haplotypecaller" ) : ( params.joint_germline ? "${meta.id}.haplotypecaller.${intervals.simpleName}.g" :"${meta.id}.haplotypecaller.${intervals.simpleName}" ) } + ext.prefix = { meta.num_intervals <= 1 ? ( params.joint_germline ? "${meta.id}.haplotypecaller.g" : "${meta.id}.haplotypecaller" ) : ( params.joint_germline ? "${meta.id}.haplotypecaller.${intervals.baseName}.g" :"${meta.id}.haplotypecaller.${intervals.baseName}" ) } ext.when = { params.tools && params.tools.split(',').contains('haplotypecaller') } publishDir = [ mode: params.publish_dir_mode, diff --git a/conf/modules/mpileup.config b/conf/modules/mpileup.config index 43cae7f1bd..dbdfa27fec 100644 --- a/conf/modules/mpileup.config +++ b/conf/modules/mpileup.config @@ -24,7 +24,7 @@ process { withName: 'BCFTOOLS_MPILEUP' { ext.args2 = { '--multiallelic-caller' } ext.args3 = { "-i 'count(GT==\"RR\")==0'" } // only report non homozygous reference variants - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.bcftools" : "${meta.id}_${intervals.simpleName}.bcftools" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.bcftools" : "${meta.id}_${intervals.baseName}.bcftools" } ext.when = { params.tools && params.tools.split(',').contains('mpileup') } publishDir = [ mode: params.publish_dir_mode, diff --git a/conf/modules/mutect2.config b/conf/modules/mutect2.config index 2f74ee6327..5892437ddc 100644 --- a/conf/modules/mutect2.config +++ b/conf/modules/mutect2.config @@ -18,7 +18,7 @@ process { withName: 'GATK4_MUTECT2' { ext.args = { params.ignore_soft_clipped_bases ? "--dont-use-soft-clipped-bases true --f1r2-tar-gz ${task.ext.prefix}.f1r2.tar.gz" : "--f1r2-tar-gz ${task.ext.prefix}.f1r2.tar.gz" } - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.mutect2" : "${meta.id}.mutect2.${intervals.simpleName}" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.mutect2" : "${meta.id}.mutect2.${intervals.baseName}" } ext.when = { params.tools && params.tools.split(',').contains('mutect2') } publishDir = [ mode: params.publish_dir_mode, @@ -91,7 +91,7 @@ process { } withName: 'GETPILEUPSUMMARIES.*' { - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.mutect2" : "${meta.id}.mutect2.${intervals.simpleName}" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.mutect2" : "${meta.id}.mutect2.${intervals.baseName}" } publishDir = [ mode: params.publish_dir_mode, path: { "${params.outdir}/variant_calling/" }, diff --git a/conf/modules/recalibrate.config b/conf/modules/recalibrate.config index 7ca0a476f1..41aa3a4146 100644 --- a/conf/modules/recalibrate.config +++ b/conf/modules/recalibrate.config @@ -16,7 +16,7 @@ process { withName: 'GATK4_APPLYBQSR|GATK4SPARK_APPLYBQSR' { - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.recal" : "${meta.id}_${intervals.simpleName}.recal" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.recal" : "${meta.id}_${intervals.baseName}.recal" } publishDir = [ mode: params.publish_dir_mode, path: { "${params.outdir}/preprocessing/" }, diff --git a/conf/modules/sentieon_dnascope.config b/conf/modules/sentieon_dnascope.config index 224c33c89c..50cf373ea8 100644 --- a/conf/modules/sentieon_dnascope.config +++ b/conf/modules/sentieon_dnascope.config @@ -16,7 +16,7 @@ process { withName: 'SENTIEON_DNASCOPE' { - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.dnascope" : "${meta.id}.dnascope.${intervals.simpleName}" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.dnascope" : "${meta.id}.dnascope.${intervals.baseName}" } ext.when = { params.tools && params.tools.split(',').contains('sentieon_dnascope') } publishDir = [ mode: params.publish_dir_mode, diff --git a/conf/modules/sentieon_haplotyper.config b/conf/modules/sentieon_haplotyper.config index 8b01b04c22..c2b9582223 100644 --- a/conf/modules/sentieon_haplotyper.config +++ b/conf/modules/sentieon_haplotyper.config @@ -16,7 +16,7 @@ process { withName: 'SENTIEON_HAPLOTYPER' { - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.haplotyper" : "${meta.id}.haplotyper.${intervals.simpleName}" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.haplotyper" : "${meta.id}.haplotyper.${intervals.baseName}" } ext.when = { params.tools && params.tools.split(',').contains('sentieon_haplotyper') } publishDir = [ mode: params.publish_dir_mode, diff --git a/conf/modules/strelka.config b/conf/modules/strelka.config index 23620dfdaf..badffb5df8 100644 --- a/conf/modules/strelka.config +++ b/conf/modules/strelka.config @@ -17,7 +17,7 @@ process { withName: 'STRELKA_.*' { ext.args = { params.wes ? '--exome' : '' } - ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.strelka" : "${meta.id}.strelka.${target_bed.simpleName}" } + ext.prefix = { meta.num_intervals <= 1 ? "${meta.id}.strelka" : "${meta.id}.strelka.${target_bed.baseName}" } ext.when = { params.tools && params.tools.split(',').contains('strelka') } publishDir = [ mode: params.publish_dir_mode, diff --git a/conf/test.config b/conf/test.config index 2612b92cd0..0852c5b542 100644 --- a/conf/test.config +++ b/conf/test.config @@ -52,6 +52,9 @@ params { // Ignore params that will throw warning through params validation validationSchemaIgnoreParams = 'genomes' + + // Base directory for nf-core/modules test data + modules_testdata_base_path = 's3://ngi-igenomes/testdata/nf-core/modules/' } process { diff --git a/modules.json b/modules.json index a8f8a7e436..555c3fb73e 100644 --- a/modules.json +++ b/modules.json @@ -391,42 +391,42 @@ }, "sentieon/applyvarcal": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "sentieon/bwamem": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "sentieon/dedup": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "sentieon/dnamodelapply": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "sentieon/dnascope": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "sentieon/gvcftyper": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "sentieon/haplotyper": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "sentieon/varcal": { "branch": "master", - "git_sha": "89b6873f15dd31ed17f4d10ede2fa623e2a128ff", + "git_sha": "220da1aa7d6ab6555817035041dd2fc05cb518d3", "installed_by": ["modules"] }, "snpeff/download": { diff --git a/modules/nf-core/sentieon/applyvarcal/main.nf b/modules/nf-core/sentieon/applyvarcal/main.nf index 304d0a0431..d1d3435dc9 100644 --- a/modules/nf-core/sentieon/applyvarcal/main.nf +++ b/modules/nf-core/sentieon/applyvarcal/main.nf @@ -27,7 +27,7 @@ process SENTIEON_APPLYVARCAL { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -74,7 +74,7 @@ process SENTIEON_APPLYVARCAL { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' diff --git a/modules/nf-core/sentieon/bwamem/main.nf b/modules/nf-core/sentieon/bwamem/main.nf index e25515e7eb..230297d087 100644 --- a/modules/nf-core/sentieon/bwamem/main.nf +++ b/modules/nf-core/sentieon/bwamem/main.nf @@ -27,7 +27,7 @@ process SENTIEON_BWAMEM { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -77,7 +77,7 @@ process SENTIEON_BWAMEM { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' diff --git a/modules/nf-core/sentieon/dedup/main.nf b/modules/nf-core/sentieon/dedup/main.nf index 01ee885a17..fbcd595f47 100644 --- a/modules/nf-core/sentieon/dedup/main.nf +++ b/modules/nf-core/sentieon/dedup/main.nf @@ -32,7 +32,7 @@ process SENTIEON_DEDUP { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -84,20 +84,22 @@ process SENTIEON_DEDUP { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' } - def prefix = task.ext.prefix ?: "${meta.id}" + def suffix = task.ext.suffix ?: ".cram" // The suffix should be either ".cram" or ".bam". + def metrics = task.ext.metrics ?: "${prefix}${suffix}.metrics" """ $fix_ld_library_path - touch ${prefix}.cram - touch ${prefix}.cram.crai - touch ${prefix}.metrics - touch ${prefix}.score + touch "${prefix}${suffix}" + touch "${prefix}${suffix}\$(echo ${suffix} | sed 's/m\$/i/')" + touch "${metrics}" + touch "${metrics}.multiqc.tsv" + touch "${prefix}.score" cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/nf-core/sentieon/dnamodelapply/main.nf b/modules/nf-core/sentieon/dnamodelapply/main.nf index 1cbb02e3b3..b728a5ec31 100644 --- a/modules/nf-core/sentieon/dnamodelapply/main.nf +++ b/modules/nf-core/sentieon/dnamodelapply/main.nf @@ -28,7 +28,7 @@ process SENTIEON_DNAMODELAPPLY { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -77,7 +77,7 @@ process SENTIEON_DNAMODELAPPLY { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' diff --git a/modules/nf-core/sentieon/dnascope/main.nf b/modules/nf-core/sentieon/dnascope/main.nf index 7e5adefc7c..6adea35eea 100644 --- a/modules/nf-core/sentieon/dnascope/main.nf +++ b/modules/nf-core/sentieon/dnascope/main.nf @@ -35,7 +35,7 @@ process SENTIEON_DNASCOPE { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -94,7 +94,7 @@ process SENTIEON_DNASCOPE { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' diff --git a/modules/nf-core/sentieon/gvcftyper/main.nf b/modules/nf-core/sentieon/gvcftyper/main.nf index d2be759fe3..4b5c9df4e3 100644 --- a/modules/nf-core/sentieon/gvcftyper/main.nf +++ b/modules/nf-core/sentieon/gvcftyper/main.nf @@ -29,7 +29,7 @@ process SENTIEON_GVCFTYPER { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -72,7 +72,7 @@ process SENTIEON_GVCFTYPER { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' diff --git a/modules/nf-core/sentieon/haplotyper/main.nf b/modules/nf-core/sentieon/haplotyper/main.nf index d349525dea..87a9343474 100644 --- a/modules/nf-core/sentieon/haplotyper/main.nf +++ b/modules/nf-core/sentieon/haplotyper/main.nf @@ -33,7 +33,7 @@ process SENTIEON_HAPLOTYPER { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -90,7 +90,7 @@ process SENTIEON_HAPLOTYPER { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' diff --git a/modules/nf-core/sentieon/varcal/main.nf b/modules/nf-core/sentieon/varcal/main.nf index 7a0c807127..17a3b71845 100644 --- a/modules/nf-core/sentieon/varcal/main.nf +++ b/modules/nf-core/sentieon/varcal/main.nf @@ -32,7 +32,7 @@ process SENTIEON_VARCAL { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' @@ -96,7 +96,7 @@ process SENTIEON_VARCAL { // The following code sets LD_LIBRARY_PATH in the script-section when the module is run by Singularity. // That turned out to be one way of overcoming the following issue with the Singularity-Sentieon-containers from galaxy, Sentieon (LD_LIBRARY_PATH) and the way Nextflow runs Singularity-containers. // The galaxy container uses a runscript which is responsible for setting LD_PRELOAD properly. Nextflow executes singularity containers using `singularity exec`, which avoids the run script, leading to the LD_LIBRARY_PATH/libstdc++.so.6 error. - if (workflow.containerEngine == 'singularity') { + if (workflow.containerEngine in ['singularity','apptainer']) { fix_ld_library_path = 'LD_LIBRARY_PATH=/usr/local/lib/:\$LD_LIBRARY_PATH;export LD_LIBRARY_PATH' } else { fix_ld_library_path = '' diff --git a/nextflow_schema.json b/nextflow_schema.json index a7f7ed7065..b70486246b 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -158,7 +158,7 @@ "default": 0, "fa_icon": "fas fa-cut", "description": "Remove bp from the 3' end of read 1", - "help_text": "This may remove some unwanted bias from the 3'. Corresponds to the FastP flag `--three_prime_clip_r1`.", + "help_text": "This may remove some unwanted bias from the 3'. Corresponds to the FastP flag `--trim_tail1`.", "hidden": true }, "three_prime_clip_r2": { @@ -166,7 +166,7 @@ "default": 0, "fa_icon": "fas fa-cut", "description": "Remove bp from the 3' end of read 2", - "help_text": "This may remove some unwanted bias from the 3' end. Corresponds to the FastP flag `--three_prime_clip_r2`.", + "help_text": "This may remove some unwanted bias from the 3' end. Corresponds to the FastP flag `--trim_tail2`.", "hidden": true }, "trim_nextseq": { diff --git a/subworkflows/local/bam_joint_calling_germline_gatk/main.nf b/subworkflows/local/bam_joint_calling_germline_gatk/main.nf index f0d9148c07..494a7854b7 100644 --- a/subworkflows/local/bam_joint_calling_germline_gatk/main.nf +++ b/subworkflows/local/bam_joint_calling_germline_gatk/main.nf @@ -37,7 +37,7 @@ workflow BAM_JOINT_CALLING_GERMLINE_GATK { // Rename based on num_intervals, group all samples by their interval_name/interval_file and restructure for channel // Group by [0, 3] to avoid a list of metas and make sure that any intervals gendb_input = input - .map{ meta, gvcf, tbi, intervals -> [ [ id:'joint_variant_calling', intervals_name:intervals.simpleName, num_intervals:meta.num_intervals ], gvcf, tbi, intervals ] } + .map{ meta, gvcf, tbi, intervals -> [ [ id:'joint_variant_calling', intervals_name:intervals.baseName, num_intervals:meta.num_intervals ], gvcf, tbi, intervals ] } .groupTuple(by:3) //join on interval file .map{ meta_list, gvcf, tbi, intervals -> // meta is now a list of [meta1, meta2] but they are all the same. So take the first element. diff --git a/subworkflows/local/bam_joint_calling_germline_sentieon/main.nf b/subworkflows/local/bam_joint_calling_germline_sentieon/main.nf index 3f19b33d52..768b596901 100644 --- a/subworkflows/local/bam_joint_calling_germline_sentieon/main.nf +++ b/subworkflows/local/bam_joint_calling_germline_sentieon/main.nf @@ -33,7 +33,7 @@ workflow BAM_JOINT_CALLING_GERMLINE_SENTIEON { versions = Channel.empty() sentieon_input = input - .map{ meta, gvcf, tbi, intervals -> [ [ id:'joint_variant_calling', intervals_name:intervals.simpleName, num_intervals:meta.num_intervals ], gvcf, tbi, intervals ] } + .map{ meta, gvcf, tbi, intervals -> [ [ id:'joint_variant_calling', intervals_name:intervals.baseName, num_intervals:meta.num_intervals ], gvcf, tbi, intervals ] } .groupTuple(by:[0, 3]) SENTIEON_GVCFTYPER(sentieon_input, fasta, fai, dbsnp, dbsnp_tbi) diff --git a/subworkflows/local/bam_variant_calling_haplotypecaller/main.nf b/subworkflows/local/bam_variant_calling_haplotypecaller/main.nf index 1dbef4c613..cf167eec40 100644 --- a/subworkflows/local/bam_variant_calling_haplotypecaller/main.nf +++ b/subworkflows/local/bam_variant_calling_haplotypecaller/main.nf @@ -29,7 +29,7 @@ workflow BAM_VARIANT_CALLING_HAPLOTYPECALLER { cram_intervals = cram.combine(intervals) // Move num_intervals to meta map // Add interval_name to allow correct merging with interval files - .map{ meta, cram, crai, intervals, num_intervals -> [ meta + [ interval_name:intervals.simpleName, num_intervals:num_intervals, variantcaller:'haplotypecaller' ], cram, crai, intervals, [] ] } + .map{ meta, cram, crai, intervals, num_intervals -> [ meta + [ interval_name:intervals.baseName, num_intervals:num_intervals, variantcaller:'haplotypecaller' ], cram, crai, intervals, [] ] } GATK4_HAPLOTYPECALLER(cram_intervals, fasta, fasta_fai, dict.map{ meta, dict -> [ dict ] }, dbsnp, dbsnp_tbi) diff --git a/subworkflows/local/bam_variant_calling_sentieon_haplotyper/main.nf b/subworkflows/local/bam_variant_calling_sentieon_haplotyper/main.nf index 4b280d271c..b0bd6bd9a0 100644 --- a/subworkflows/local/bam_variant_calling_sentieon_haplotyper/main.nf +++ b/subworkflows/local/bam_variant_calling_sentieon_haplotyper/main.nf @@ -34,7 +34,7 @@ workflow BAM_VARIANT_CALLING_SENTIEON_HAPLOTYPER { .map{ meta, cram, crai, intervals, num_intervals -> [ meta + [ num_intervals:num_intervals, - intervals_name:intervals.simpleName, + intervals_name:intervals.baseName, variantcaller:'sentieon_haplotyper'], cram, crai, diff --git a/subworkflows/local/prepare_genome/main.nf b/subworkflows/local/prepare_genome/main.nf index 5ceb16f8aa..46a2fa5985 100644 --- a/subworkflows/local/prepare_genome/main.nf +++ b/subworkflows/local/prepare_genome/main.nf @@ -123,7 +123,7 @@ workflow PREPARE_GENOME { hashtable = DRAGMAP_HASHTABLE.out.hashmap.map{ meta, index -> [index] }.collect() // path: dragmap/* dbsnp_tbi = TABIX_DBSNP.out.tbi.map{ meta, tbi -> [tbi] }.collect() // path: dbsnb.vcf.gz.tbi dict = GATK4_CREATESEQUENCEDICTIONARY.out.dict // path: genome.fasta.dict - fasta_fai = SAMTOOLS_FAIDX.out.fai.map{ meta, fai -> [fai] } // path: genome.fasta.fai + fasta_fai = SAMTOOLS_FAIDX.out.fai.map{ meta, fai -> [fai] }.flatten().first() // path: genome.fasta.fai germline_resource_tbi = TABIX_GERMLINE_RESOURCE.out.tbi.map{ meta, tbi -> [tbi] }.collect() // path: germline_resource.vcf.gz.tbi known_snps_tbi = TABIX_KNOWN_SNPS.out.tbi.map{ meta, tbi -> [tbi] }.collect() // path: {known_indels*}.vcf.gz.tbi known_indels_tbi = TABIX_KNOWN_INDELS.out.tbi.map{ meta, tbi -> [tbi] }.collect() // path: {known_indels*}.vcf.gz.tbi diff --git a/tests/config/pytesttags.yml b/tests/config/pytesttags.yml index 1612a9bb17..0c3c05c554 100644 --- a/tests/config/pytesttags.yml +++ b/tests/config/pytesttags.yml @@ -327,7 +327,7 @@ sentieon/dnascope: - tests/csv/3.0/mapped_single_bam.csv - tests/test_sentieon_dnascope.yml -sentieon_dnascope_skip_filter: +sentieon/dnascope_skip_filter: - conf/modules/sentieon_dnascope.config - modules/nf-core/sentieon/dnascope/** - modules/nf-core/gatk4/mergevcfs/** @@ -355,7 +355,7 @@ sentieon/haplotyper: - tests/csv/3.0/mapped_single_bam.csv - tests/test_sentieon_haplotyper.yml -sentieon_haplotyper_skip_filter: +sentieon/haplotyper_skip_filter: - conf/modules/sentieon_haplotyper.config - modules/nf-core/sentieon/haplotyper/** - modules/nf-core/gatk4/mergevcfs/** @@ -390,7 +390,7 @@ joint_germline: - tests/test_joint_germline.yml ## sentieon_dnascope_joint_germline -sentieon_dnascope_joint_germline: +sentieon/dnascope_joint_germline: - conf/modules/prepare_genome.config - conf/modules/sentieon_dnascope.config - conf/modules/sentieon_dnascope_joint_germline.config @@ -401,7 +401,7 @@ sentieon_dnascope_joint_germline: - tests/test_sentieon_dnascop_joint_germline.yml ## sentieon_haplotyper_joint_germline -sentieon_haplotyper_joint_germline: +sentieon/haplotyper_joint_germline: - conf/modules/prepare_genome.config - conf/modules/sentieon_haplotyper.config - conf/modules/sentieon_haplotyper_joint_germline.config diff --git a/tests/test_sentieon_dnascope_joint_germline.yml b/tests/test_sentieon_dnascope_joint_germline.yml index 295bb45e7e..dd6c22558e 100644 --- a/tests/test_sentieon_dnascope_joint_germline.yml +++ b/tests/test_sentieon_dnascope_joint_germline.yml @@ -2,7 +2,7 @@ command: nextflow run main.nf -profile test_cache,targeted,software_license --sentieon_extension --input ./tests/csv/3.0/mapped_joint_bam.csv --tools sentieon_dnascope --step variant_calling --joint_germline --outdir results --sentieon_dnascope_emit_mode gvcf tags: - germline - - sentieon_dnascope_joint_germline + - sentieon/dnascope_joint_germline - variant_calling files: - path: results/csv/variantcalled.csv @@ -64,7 +64,7 @@ command: nextflow run main.nf -profile test_cache,targeted,software_license --sentieon_extension --input ./tests/csv/3.0/mapped_joint_bam.csv --tools sentieon_dnascope --step variant_calling --joint_germline --outdir results --sentieon_dnascope_emit_mode gvcf --nucleotides_per_second 100 tags: - germline - - sentieon_dnascope_joint_germline + - sentieon/dnascope_joint_germline - variant_calling files: - path: results/csv/variantcalled.csv diff --git a/tests/test_sentieon_dnascope_skip_filter.yml b/tests/test_sentieon_dnascope_skip_filter.yml index bd2a49b551..3950f7a438 100644 --- a/tests/test_sentieon_dnascope_skip_filter.yml +++ b/tests/test_sentieon_dnascope_skip_filter.yml @@ -2,7 +2,7 @@ command: nextflow run main.nf -profile test_cache,targeted,software_license --sentieon_extension --input ./tests/csv/3.0/mapped_single_bam.csv --tools sentieon_dnascope --step variant_calling --skip_tools dnascope_filter --outdir results tags: - germline - - sentieon_dnascope_skip_filter + - sentieon/dnascope_skip_filter - variant_calling files: - path: results/csv/variantcalled.csv @@ -46,7 +46,7 @@ command: nextflow run main.nf -profile test_cache,targeted,software_license --sentieon_extension --input ./tests/csv/3.0/mapped_single_bam.csv --tools sentieon_dnascope --step variant_calling --skip_tools dnascope_filter --no_intervals --outdir results tags: - germline - - sentieon_dnascope_skip_filter + - sentieon/dnascope_skip_filter - no_intervals - variant_calling files: diff --git a/tests/test_sentieon_haplotyper_joint_germline.yml b/tests/test_sentieon_haplotyper_joint_germline.yml index 3474764886..b42f36a20c 100644 --- a/tests/test_sentieon_haplotyper_joint_germline.yml +++ b/tests/test_sentieon_haplotyper_joint_germline.yml @@ -2,9 +2,8 @@ command: nextflow run main.nf -profile test_cache,software_license,targeted --sentieon_extension --input ./tests/csv/3.0/mapped_joint_bam.csv --tools sentieon_haplotyper --step variant_calling --joint_germline --outdir results --sentieon_haplotyper_emit_mode gvcf tags: - germline - - sentieon_haplotyper_joint_germline + - sentieon/haplotyper_joint_germline - variant_calling - - sentieon/haplotyper files: - path: results/csv/variantcalled.csv md5sum: 6ec10f6455c2b5290c7f6fc687c529ca @@ -53,9 +52,8 @@ command: nextflow run main.nf -profile test_cache,software_license,targeted --sentieon_extension --input ./tests/csv/3.0/mapped_joint_bam.csv --tools sentieon_haplotyper --step variant_calling --joint_germline --outdir results --sentieon_haplotyper_emit_mode gvcf --nucleotides_per_second 100 tags: - germline - - sentieon_haplotyper_joint_germline + - sentieon/haplotyper_joint_germline - variant_calling - - sentieon/haplotyper files: - path: results/csv/variantcalled.csv md5sum: 6ec10f6455c2b5290c7f6fc687c529ca @@ -102,7 +100,7 @@ command: nextflow run main.nf -profile test_cache,software_license,tools_germline --sentieon_extension --input ./tests/csv/3.0/mapped_joint_bam.csv --tools sentieon_haplotyper --step variant_calling --joint_germline --outdir results --sentieon_haplotyper_emit_mode gvcf -stub-run tags: - germline - - sentieon_haplotyper_joint_germline + - sentieon/haplotyper_joint_germline - variant_calling - vqsr files: diff --git a/tests/test_sentieon_haplotyper_skip_filter.yml b/tests/test_sentieon_haplotyper_skip_filter.yml index f333f41558..f93b0afca5 100644 --- a/tests/test_sentieon_haplotyper_skip_filter.yml +++ b/tests/test_sentieon_haplotyper_skip_filter.yml @@ -2,9 +2,8 @@ command: nextflow run main.nf -profile test_cache,software_license,targeted --sentieon_extension --input ./tests/csv/3.0/mapped_single_bam.csv --tools sentieon_haplotyper --step variant_calling --skip_tools haplotyper_filter --outdir results tags: - germline - - sentieon_haplotyper_skip_filter + - sentieon/haplotyper_skip_filter - variant_calling - - sentieon/haplotyper files: - path: results/csv/variantcalled.csv md5sum: e08d6aa77d914bc2c933e70696b74cdd @@ -48,10 +47,9 @@ command: nextflow run main.nf -profile test_cache,software_license,targeted --sentieon_extension --input ./tests/csv/3.0/mapped_single_bam.csv --tools sentieon_haplotyper --step variant_calling --skip_tools haplotyper_filter --no_intervals --outdir results tags: - germline - - sentieon_haplotyper_skip_filter + - sentieon/haplotyper_skip_filter - no_intervals - variant_calling - - sentieon/haplotyper files: - path: results/csv/variantcalled.csv md5sum: e08d6aa77d914bc2c933e70696b74cdd diff --git a/workflows/sarek.nf b/workflows/sarek.nf index 6478909470..694e2a19ab 100644 --- a/workflows/sarek.nf +++ b/workflows/sarek.nf @@ -324,7 +324,7 @@ workflow SAREK { // Built from the fasta file: dict = params.dict ? Channel.fromPath(params.dict).map{ it -> [ [id:'dict'], it ] }.collect() : PREPARE_GENOME.out.dict - fasta_fai = params.fasta_fai ? Channel.fromPath(params.fasta_fai).collect() + fasta_fai = params.fasta_fai ? Channel.fromPath(params.fasta_fai).first() : PREPARE_GENOME.out.fasta_fai bwa = params.bwa ? Channel.fromPath(params.bwa).collect() : PREPARE_GENOME.out.bwa