diff --git a/.github/workflows/awsfulltest.yml b/.github/workflows/awsfulltest.yml index fe30ca56..baaa0461 100644 --- a/.github/workflows/awsfulltest.yml +++ b/.github/workflows/awsfulltest.yml @@ -46,7 +46,6 @@ jobs: "cosmic_username": "${{ secrets.cosmic_username }}", "cosmic_passwd": "${{ secrets.cosmic_passwd }}", "all": true, - "build_references": true } profiles: test_full,aws_tower - uses: actions/upload-artifact@v4 @@ -55,19 +54,3 @@ jobs: path: | seqera_platform_action_*.log seqera_platform_action_*.json - - name: Launch run workflow via tower - uses: seqeralabs/action-tower-launch@v2 - with: - workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }} - access_token: ${{ secrets.TOWER_ACCESS_TOKEN }} - compute_env: ${{ secrets.TOWER_COMPUTE_ENV }} - workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/rnafusion/work-${{ github.sha }} - parameters: | - { - "outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/rnafusion/results-${{ github.sha }}", - "genomes_base": "s3://${{ secrets.AWS_S3_BUCKET }}/rnafusion/results-${{ github.sha }}/references", - "cosmic_username": "${{ secrets.cosmic_username }}", - "cosmic_passwd": "${{ secrets.cosmic_passwd }}", - "all": true, - } - profiles: test_full,aws_tower diff --git a/.github/workflows/awstest.yml b/.github/workflows/awstest.yml index 8f6bfb01..977adb49 100644 --- a/.github/workflows/awstest.yml +++ b/.github/workflows/awstest.yml @@ -26,8 +26,7 @@ jobs: "cosmic_username": "${{ secrets.cosmic_username }}", "cosmic_passwd": "${{ secrets.cosmic_passwd }}", "all": true, - "stub": true, - "build_references": true + "stub": true } profiles: test,aws_tower - uses: actions/upload-artifact@v4 @@ -36,27 +35,3 @@ jobs: path: | tower_action_*.log tower_action_*.json - - - name: Launch workflow via tower - uses: seqeralabs/action-tower-launch@v2 - with: - workspace_id: ${{ secrets.TOWER_WORKSPACE_ID }} - access_token: ${{ secrets.TOWER_ACCESS_TOKEN }} - compute_env: ${{ secrets.TOWER_COMPUTE_ENV }} - workdir: s3://${{ secrets.AWS_S3_BUCKET }}/work/rnafusion/work-${{ github.sha }} - parameters: | - { - "outdir": "s3://${{ secrets.AWS_S3_BUCKET }}/rnafusion/results-${{ github.sha }}", - "genomes_base": "s3://${{ secrets.AWS_S3_BUCKET }}/rnafusion/results-${{ github.sha }}/references", - "cosmic_username": "${{ secrets.cosmic_username }}", - "cosmic_passwd": "${{ secrets.cosmic_passwd }}", - "all": true, - "stub": true - } - profiles: test,aws_tower - - uses: actions/upload-artifact@v4 - with: - name: Seqera Platform debug log file - path: | - seqera_platform_action_*.log - seqera_platform_action_*.json diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 71ff7245..a510d72d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -39,7 +39,6 @@ jobs: - "latest-stable" test_profile: - "test_stub" - - "test_build" compute_profile: - "docker" - "singularity" diff --git a/CHANGELOG.md b/CHANGELOG.md index c75b3bf3..d947b900 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Add nf-test to local module: `STARFUSION_BUILD`. [#585](https://github.com/nf-core/rnafusion/pull/585) - Add nf-test to local module: `STARFUSION_DETECT`. [#586](https://github.com/nf-core/rnafusion/pull/586) - Added a new module `CTATSPLICING_STARTOCANCERINTRONS` and a new parameter `--ctatsplicing`. This options creates reports on cancer splicing abberations and requires one or both of `--arriba` and `--starfusion` to be given. [#587](https://github.com/nf-core/rnafusion/pull/587) +- Add parameter `--references_only` when no data should be analysed, but only the references should be built [#505](https://github.com/nf-core/rnafusion/pull/505) ### Changed @@ -34,6 +35,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Remove double nested folder introduced in [#577](https://github.com/nf-core/rnafusion/pull/577), [#581](https://github.com/nf-core/rnafusion/pull/581) - Use docker.io and galaxy containers for fusioncatcher and starfusion (incl. fusioninspector) instead of wave as they are not functional on wave [#588](https://github.com/nf-core/rnafusion/pull/588) - Update STAR-Fusion to 1.14 [#588](https://github.com/nf-core/rnafusion/pull/588) +- Use "-genePredExt -geneNameAsName2 -ignoreGroupsWithoutExons" (to mimic gms/tomte) for GTF_TO_REFFLAT [#505](https://github.com/nf-core/rnafusion/pull/505) +- Integrate reference building in the main workflow [#505](https://github.com/nf-core/rnafusion/pull/505) +- Move from ensembl to gencode base [#505](https://github.com/nf-core/rnafusion/pull/505) +- Update from ensembl 102 to gencode 46 default references [#505](https://github.com/nf-core/rnafusion/pull/505) ### Fixed @@ -48,12 +53,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Removed - Remove fusionGDB from documentation and fusion-report download stubs [#503](https://github.com/nf-core/rnafusion/pull/503) +- Removed test-build as reference building gets integrated in the main workflow [#505](https://github.com/nf-core/rnafusion/pull/505) +- Removed parameter `--build_references` ### Parameters -| Old parameter | New parameter | -| ------------- | ------------- | -| | `--no_cosmic` | +| Old parameter | New parameter | +| -------------------- | ------------------- | +| | `--no_cosmic` | +| `--build_references` | `--references_only` | ## v3.0.2 - [2024-04-10] diff --git a/README.md b/README.md index 41e2bc96..809de85f 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ ## Introduction -**nf-core/rnafusion** is a bioinformatics best-practice analysis pipeline for RNA sequencing consisting of several tools designed for detecting and visualizing fusion genes. Results from up to 5 fusion callers tools are created, and are also aggregated, most notably in a pdf visualiation document, a vcf data collection file, and html and tsv reports. +**nf-core/rnafusion** is a bioinformatics best-practice analysis pipeline for RNA sequencing consisting of several tools designed for detecting and visualizing fusion genes. Results from up to 5 fusion callers tools are created, and are also aggregated, most notably in a pdf visualisation document, a vcf data collection file, and html and tsv reports. On release, automated continuous integration tests run the pipeline on a full-sized dataset on the AWS cloud infrastructure. This ensures that the pipeline runs on AWS, has sensible resource allocation defaults set to run on real-world datasets, and permits the persistent storage of results to benchmark between pipeline releases and other analysis sources. The results obtained from the full-sized test can be viewed on the [nf-core website](https://nf-co.re/rnafusion/results). @@ -31,9 +31,9 @@ In rnafusion the full-sized test includes reference building and fusion detectio ### Build references -`--build_references` triggers a parallel workflow to build references, which is a prerequisite to running the pipeline: +`--references_only` triggers a workflow to ONLY build references, otherwise the references are build when the analysis is run: -1. Download ensembl fasta and gtf files +1. Download gencode fasta and gtf files 2. Create [STAR](https://github.com/alexdobin/STAR) index 3. Download [Arriba](https://github.com/suhrig/arriba) references 4. Download [FusionCatcher](https://github.com/ndaniel/fusioncatcher) references @@ -78,7 +78,7 @@ First, build the references: nextflow run nf-core/rnafusion \ -profile test, \ --outdir \ - --build_references \ + --references_only \ -stub ``` diff --git a/conf/modules.config b/conf/modules.config index 1730b17b..b3643f48 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -18,10 +18,6 @@ process { saveAs: { filename -> filename.equals('versions.yml') ? null : filename } ] - withName: GFFREAD { - ext.args = '-w -S' - } - withName: 'ARRIBA_ARRIBA' { publishDir = [ path: { "${params.outdir}/arriba" }, @@ -40,7 +36,7 @@ process { } withName: 'ARRIBA_VISUALISATION' { - ext.when = { !params.fusioninspector_only && (params.starfusion || params.all) } + ext.when = { {!params.fusioninspector_only} && ({params.starfusion} || {params.all}) } ext.prefix = { "${meta.id}_combined_fusions_arriba_visualisation" } publishDir = [ path: { "${params.outdir}/arriba_visualisation" }, @@ -73,9 +69,9 @@ process { ] } - withName: 'ENSEMBL_DOWNLOAD' { + withName: 'GENCODE_DOWNLOAD' { publishDir = [ - path: { "${params.genomes_base}/ensembl" }, + path: { "${params.genomes_base}/gencode" }, mode: params.publish_dir_mode, saveAs: { filename -> filename.equals('versions.yml') ? null : filename } ] @@ -87,7 +83,7 @@ process { withName: 'FASTQC' { ext.args = '--quiet' - ext.when = { !params.skip_qc } + ext.when = {!params.skip_qc} publishDir = [ path: { "${params.outdir}/fastqc" }, mode: params.publish_dir_mode, @@ -97,6 +93,7 @@ process { withName: 'FASTQC_FOR_FASTP' { ext.args = '--quiet' + ext.when = { !params.skip_qc } ext.prefix = { "${meta.id}_trimmed" } publishDir = [ path: { "${params.outdir}/fastqc_for_fastp" }, @@ -119,7 +116,7 @@ process { withName: 'FUSIONINSPECTOR' { ext.when = { !params.skip_vis } - ext.args = { params.fusioninspector_limitSjdbInsertNsj != 1000000 ? "--STAR_xtra_params \"--limitSjdbInsertNsj ${params.fusioninspector_limitSjdbInsertNsj}\"" : '' } + ext.args = { ${params.fusioninspector_limitSjdbInsertNsj} != 1000000 ? "--STAR_xtra_params \"--limitSjdbInsertNsj ${params.fusioninspector_limitSjdbInsertNsj}\"" : '' } ext.args2 = '--annotate --examine_coding_effect' } @@ -146,12 +143,39 @@ process { withName: 'GATK4_BEDTOINTERVALLIST' { publishDir = [ - path: { "${params.genomes_base}/ensembl" }, + path: { "${params.genomes_base}/gencode" }, mode: params.publish_dir_mode, saveAs: { filename -> filename.equals('versions.yml') ? null : filename } ] } + withName: 'GATK4_MARKDUPLICATES' { + ext.when = { {!params.skip_qc} && {!params.fusioninspector_only} && ( {params.starfusion}|| {params.all}) } + publishDir = [ + path: { "${params.outdir}/picard" }, + mode: params.publish_dir_mode, + saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, + ] + } + + withName: 'GFFREAD' { + ext.args = { '-w -S' } + publishDir = [ + path: { "${params.genomes_base}/gffread" }, + mode: params.publish_dir_mode, + saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, + ] + } + + withName: 'GTF_TO_REFFLAT' { + ext.args = "-genePredExt -geneNameAsName2 -ignoreGroupsWithoutExons" + publishDir = [ + path: { "${params.genomes_base}/gencode" }, + mode: params.publish_dir_mode, + saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, + ] + } + withName: 'HGNC_DOWNLOAD' { publishDir = [ path: { "${params.genomes_base}/hgnc" }, @@ -161,7 +185,7 @@ process { } withName: 'MULTIQC' { ext.when = { !params.skip_qc } - ext.args = params.multiqc_title ? "--title \"$params.multiqc_title\"" : '' + ext.args = {params.multiqc_title} ? "--title \"$params.multiqc_title\"" : '' publishDir = [ path: { "${params.outdir}/multiqc" }, mode: params.publish_dir_mode, @@ -170,21 +194,12 @@ process { } withName: 'PICARD_COLLECTRNASEQMETRICS' { - ext.when = { !params.skip_qc && !params.fusioninspector_only && (params.starfusion || params.all) } + ext.when = { {!params.skip_qc} && {!params.fusioninspector_only} && ( {params.starfusion} || {params.all}) } } - withName: 'GATK4_MARKDUPLICATES' { - ext.when = { !params.skip_qc && !params.fusioninspector_only && (params.starfusion || params.all) } - publishDir = [ - path: { "${params.outdir}/picard" }, - mode: params.publish_dir_mode, - saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, - ] - } - withName: 'PICARD_COLLECTINSERTSIZEMETRICS' { - ext.when = { !params.skip_qc && !params.fusioninspector_only && (params.starfusion || params.all) } + ext.when = { ${!params.skip_qc} && ${!params.fusioninspector_only} && (${params.starfusion} || ${params.all}) } ext.prefix = { "${meta.id}_collectinsertsize"} publishDir = [ path: { "${params.outdir}/picard" }, @@ -215,7 +230,7 @@ process { withName: 'SAMTOOLS_FAIDX' { publishDir = [ - path: { "${params.genomes_base}/ensembl" }, + path: { "${params.genomes_base}/gencode" }, mode: params.publish_dir_mode, saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, ] @@ -375,16 +390,11 @@ process { ] } - withName: 'UCSC_GTFTOGENEPRED' { - ext.args = "-genePredExt -geneNameAsName2" - publishDir = [ - path: { "${params.genomes_base}/ensembl" }, - mode: params.publish_dir_mode, - saveAs: { filename -> filename.equals('versions.yml') ? null : filename }, - ] - } - withName: 'VCF_COLLECT' { ext.when = { {!params.fusioninspector_only} && {!params.skip_vcf} } } + + withName: '.*' { + ext.when = { !params.references_only || task.process.contains('BUILD_REFERENCES') } + } } diff --git a/conf/test.config b/conf/test.config index b3d32585..2d403c75 100644 --- a/conf/test.config +++ b/conf/test.config @@ -16,6 +16,8 @@ params { // Input data input = 'https://raw.githubusercontent.com/nf-core/test-datasets/rnafusion/testdata/human/samplesheet_valid.csv' + all = true + no_cosmic = true } // Limit and standardize resources for github actions and reproducibility diff --git a/conf/test_build.config b/conf/test_build.config index cce3196e..e577ada5 100644 --- a/conf/test_build.config +++ b/conf/test_build.config @@ -15,7 +15,7 @@ params { config_profile_description = 'Minimal test dataset to check pipeline function' // Input data - build_references = true + references_only = true input = 'https://raw.githubusercontent.com/nf-core/test-datasets/rnafusion/testdata/human/samplesheet_valid.csv' no_cosmic = true all = true diff --git a/docs/usage.md b/docs/usage.md index 1bddcf71..b3942057 100644 --- a/docs/usage.md +++ b/docs/usage.md @@ -10,7 +10,7 @@ The pipeline is divided into two parts: 1. Download and build references -- specified with `--build_references` parameter +- specified with `--references_only` parameter - required only once before running the pipeline - **Important**: has to be run with each new release @@ -32,7 +32,7 @@ The rnafusion pipeline needs references for the fusion detection tools, so downl ```bash nextflow run nf-core/rnafusion \ -profile \ - --build_references --all \ + --references_only --all \ --cosmic_username --cosmic_passwd \ --genomes_base \ --outdir @@ -43,7 +43,7 @@ References for each tools can also be downloaded separately with: ```bash nextflow run nf-core/rnafusion \ -profile \ - --build_references -- -- ... \ + --references_only -- -- ... \ --cosmic_username --cosmic_passwd \ --genomes_base \ --outdir @@ -64,7 +64,7 @@ Use credentials from QIAGEN and add `--qiagen` ```bash nextflow run nf-core/rnafusion \ -profile \ - --build_references -- -- ... \ + --references_only -- -- ... \ --cosmic_username --cosmic_passwd \ --genomes_base \ --outdir --qiagen @@ -81,7 +81,7 @@ If process `FUSIONREPORT_DOWNLOAD` times out, it could be due to network restric ```bash nextflow run nf-core/rnafusion \ -profile \ - --build_references \ + --references_only \ --cosmic_username --cosmic_passwd \ --fusionreport \ --genomes_base \ @@ -93,7 +93,7 @@ Where the custom configuration could look like (adaptation to local machine nece ```text process { - withName: 'NFCORE_RNAFUSION:BUILD_REFERENCES:FUSIONREPORT_DOWNLOAD' { + withName: 'NFCORE_RNAFUSION:RNAFUSION:BUILD_REFERENCES:FUSIONREPORT_DOWNLOAD' { memory = '8.GB' cpus = 4 } @@ -162,7 +162,7 @@ If you are not covered by the research COSMIC license and want to avoid using CO > **IMPORTANT: Either `--all` or `--`** is necessary to run detection tools -`--genomes_base` should be the path to the directory containing the folder `references/` that was built with `--build_references`. +`--genomes_base` should be the path to the directory containing the folder `references/` that was built with `--references_only`. Note that the pipeline will create the following files in your working directory: @@ -397,7 +397,6 @@ If `-profile` is not specified, the pipeline will run locally and expect all sof - `test` - A profile with a complete configuration for automated testing - Includes links to test data so needs no other parameters - - Needs to run in two steps: with `--build_references` first and then without `--build_references` to run the analysis - !!!! Run with `-stub` as all references need to be downloaded otherwise !!!! ### `-resume` diff --git a/main.nf b/main.nf index ced04ca9..78781bed 100644 --- a/main.nf +++ b/main.nf @@ -18,7 +18,6 @@ include { PIPELINE_INITIALISATION } from './subworkflows/local/utils_nfcore_rnafusion_pipeline' include { PIPELINE_COMPLETION } from './subworkflows/local/utils_nfcore_rnafusion_pipeline' include { getGenomeAttribute } from './subworkflows/local/utils_nfcore_rnafusion_pipeline' -include { BUILD_REFERENCES } from './workflows/build_references' include { RNAFUSION } from './workflows/rnafusion' @@ -51,12 +50,10 @@ workflow NFCORE_RNAFUSION { // WORKFLOW: Run pipeline // - if (params.build_references) { - BUILD_REFERENCES () - } else { - RNAFUSION(samplesheet) - } + RNAFUSION(samplesheet) + emit: + multiqc_report = RNAFUSION.out.multiqc_report } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -73,18 +70,14 @@ workflow { PIPELINE_INITIALISATION ( params.version, params.validate_params, - params.monochrome_logs, args, params.outdir, - params.input ) // // WORKFLOW: Run main workflow // - NFCORE_RNAFUSION ( - PIPELINE_INITIALISATION.out.samplesheet - ) + NFCORE_RNAFUSION (PIPELINE_INITIALISATION.out.samplesheet) // // SUBWORKFLOW: Run completion tasks @@ -96,6 +89,7 @@ workflow { params.outdir, params.monochrome_logs, params.hook_url, + NFCORE_RNAFUSION.out.multiqc_report, ) } diff --git a/modules.json b/modules.json index f8ae46ae..b41d5fa5 100644 --- a/modules.json +++ b/modules.json @@ -17,7 +17,7 @@ }, "arriba/download": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "467c202a876d26af544fa8c4b22a050a535462a7", "installed_by": ["modules"] }, "bedops/convert2bed": { @@ -32,7 +32,7 @@ }, "cat/fastq": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "a1abf90966a2a4016d3c3e41e228bfcbd4811ccc", "installed_by": ["modules"] }, "fastp": { @@ -42,27 +42,27 @@ }, "fastqc": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "dc94b6ee04a05ddb9f7ae050712ff30a13149164", "installed_by": ["modules"] }, "gatk4/bedtointervallist": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "1999eff2c530b2b185a25cc42117a1686f09b685", "installed_by": ["modules"] }, "gatk4/createsequencedictionary": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "1999eff2c530b2b185a25cc42117a1686f09b685", "installed_by": ["modules"] }, "gatk4/markduplicates": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "1999eff2c530b2b185a25cc42117a1686f09b685", "installed_by": ["modules"] }, "gffread": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "bd5f75ccaf2345269810e66e85de8a70e4de8764", "installed_by": ["modules"] }, "multiqc": { @@ -72,7 +72,7 @@ }, "picard/collectinsertsizemetrics": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "49f4e50534fe4b64101e62ea41d5dc43b1324358", "installed_by": ["modules"] }, "picard/collectrnaseqmetrics": { @@ -82,7 +82,7 @@ }, "picard/collectwgsmetrics": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "49f4e50534fe4b64101e62ea41d5dc43b1324358", "installed_by": ["modules"] }, "rrnatranscripts": { @@ -93,12 +93,12 @@ }, "salmon/index": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "49f4e50534fe4b64101e62ea41d5dc43b1324358", "installed_by": ["modules"] }, "salmon/quant": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "49f4e50534fe4b64101e62ea41d5dc43b1324358", "installed_by": ["modules"] }, "samtools/faidx": { @@ -113,22 +113,22 @@ }, "samtools/sort": { "branch": "master", - "git_sha": "b13f07be4c508d6ff6312d354d09f2493243e208", + "git_sha": "b7800db9b069ed505db3f9d91b8c72faea9be17b", "installed_by": ["modules"] }, "samtools/view": { "branch": "master", - "git_sha": "b13f07be4c508d6ff6312d354d09f2493243e208", + "git_sha": "2d20463181b1c38981a02e90d3084b5f9fa8d540", "installed_by": ["modules"] }, "star/align": { "branch": "master", - "git_sha": "30a97c755895b7dfe40a730b0695c554a10f1cdd", + "git_sha": "a5ad53288c79fa52c5ae708c317e09ec2dd149ab", "installed_by": ["modules"] }, "star/genomegenerate": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "a5ad53288c79fa52c5ae708c317e09ec2dd149ab", "installed_by": ["modules"] }, "stringtie/merge": { @@ -138,7 +138,7 @@ }, "stringtie/stringtie": { "branch": "master", - "git_sha": "666652151335353eef2fcd58880bcef5bc2928e1", + "git_sha": "49f4e50534fe4b64101e62ea41d5dc43b1324358", "installed_by": ["modules"] }, "ucsc/gtftogenepred": { @@ -152,17 +152,17 @@ "nf-core": { "utils_nextflow_pipeline": { "branch": "master", - "git_sha": "3aa0aec1d52d492fe241919f0c6100ebf0074082", + "git_sha": "c2b22d85f30a706a3073387f30380704fcae013b", "installed_by": ["subworkflows"] }, "utils_nfcore_pipeline": { "branch": "master", - "git_sha": "1b6b9a3338d011367137808b49b923515080e3ba", + "git_sha": "51ae5406a030d4da1e49e4dab49756844fdd6c7a", "installed_by": ["subworkflows"] }, "utils_nfschema_plugin": { "branch": "master", - "git_sha": "bbd5a41f4535a8defafe6080e00ea74c45f4f96c", + "git_sha": "2fd2cd6d0e7b273747f32e465fdc6bcc3ae0814e", "installed_by": ["subworkflows"] } } diff --git a/modules/local/arriba/visualisation/main.nf b/modules/local/arriba/visualisation/main.nf index cc120119..f1aa097b 100644 --- a/modules/local/arriba/visualisation/main.nf +++ b/modules/local/arriba/visualisation/main.nf @@ -22,17 +22,17 @@ process ARRIBA_VISUALISATION { script: def args = task.ext.args ?: '' - def cytobands = cytobands ? " --cytobands=$cytobands" : "" + def arg_cytobands = cytobands ? " --cytobands=$cytobands" : "" + def arg_protein_domains = protein_domains ? "--proteinDomains=$protein_domains" : "" def prefix = task.ext.prefix ?: "${meta.id}" - def protein_domains = protein_domains ? "--proteinDomains=$protein_domains" : "" """ draw_fusions.R \\ --fusions=$fusions \\ --alignments=$bam \\ --output=${prefix}.pdf \\ --annotation=${gtf} \\ - $cytobands \\ - $protein_domains \\ + $arg_cytobands \\ + $arg_protein_domains \\ $args cat <<-END_VERSIONS > versions.yml diff --git a/modules/local/ensembl/main.nf b/modules/local/ensembl/main.nf deleted file mode 100644 index 8f708fc2..00000000 --- a/modules/local/ensembl/main.nf +++ /dev/null @@ -1,53 +0,0 @@ -process ENSEMBL_DOWNLOAD { - tag "ensembl" - label 'process_low' - - conda "bioconda::gnu-wget=1.18" - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/gnu-wget:1.18--h5bf99c6_5' : - 'biocontainers/gnu-wget:1.18--h5bf99c6_5' }" - - input: - val ensembl_version - val genome - val meta - - output: - tuple val(meta), path("Homo_sapiens.${genome}.${ensembl_version}.gtf") , emit: gtf - tuple val(meta), path("Homo_sapiens.${genome}.${ensembl_version}.dna.primary_assembly.fa") , emit: primary_assembly - tuple val(meta), path("Homo_sapiens.${genome}.${ensembl_version}.chr.gtf") , emit: chrgtf - path "versions.yml" , emit: versions - - - script: - """ - wget ftp://ftp.ensembl.org/pub/release-${ensembl_version}/gtf/homo_sapiens/Homo_sapiens.${params.genome}.${ensembl_version}.gtf.gz - wget ftp://ftp.ensembl.org/pub/release-${ensembl_version}/fasta/homo_sapiens/dna/Homo_sapiens.${params.genome}.dna.primary_assembly.fa.gz -O Homo_sapiens.${params.genome}.${ensembl_version}.dna.primary_assembly.fa.gz - wget ftp://ftp.ensembl.org/pub/release-${ensembl_version}/gtf/homo_sapiens/Homo_sapiens.${params.genome}.${ensembl_version}.chr.gtf.gz - - gunzip Homo_sapiens.${params.genome}.${ensembl_version}.gtf.gz - gunzip Homo_sapiens.${params.genome}.${ensembl_version}.dna.primary_assembly.fa.gz - gunzip Homo_sapiens.${params.genome}.${ensembl_version}.chr.gtf.gz - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - wget: \$(echo wget -V 2>&1 | grep "GNU Wget" | cut -d" " -f3) - gunzip: \$(echo \$(gunzip --version 2>&1) | sed 's/^.*(gzip) //; s/ Copyright.*\$//') - - END_VERSIONS - """ - - stub: - """ - touch "Homo_sapiens.${genome}.${ensembl_version}.gtf" - touch "Homo_sapiens.${params.genome}.${ensembl_version}.dna.primary_assembly.fa" - touch "Homo_sapiens.${params.genome}.${ensembl_version}.chr.gtf" - - cat <<-END_VERSIONS > versions.yml - "${task.process}": - wget: \$(echo wget -V 2>&1 | grep "GNU Wget" | cut -d" " -f3) - gunzip: \$(echo \$(gunzip --version 2>&1) | sed 's/^.*(gzip) //; s/ Copyright.*\$//') - END_VERSIONS - """ - -} diff --git a/modules/local/ensembl/tests/main.nf.test b/modules/local/ensembl/tests/main.nf.test deleted file mode 100644 index e30a826f..00000000 --- a/modules/local/ensembl/tests/main.nf.test +++ /dev/null @@ -1,37 +0,0 @@ -nextflow_process { - - name "Test Process ENSEMBL_DOWNLOAD" - script "../main.nf" - process "ENSEMBL_DOWNLOAD" - - test("Should download Ensembl files") { - - when { - params { - outdir = "tests/results" - genome = "GRCh38" - } - process { - """ - input[0] = "102" - input[1] = "GRCh38" - input[2] = "GRCh38" - """ - } - } - - then { - assertAll( - { assert process.success }, - { assert snapshot( - file(process.out.gtf[0][1]).name, - file(process.out.primary_assembly[0][1]).name, - file(process.out.chrgtf[0][1]).name, - process.out.versions - ).match() } - ) - } - - } - -} diff --git a/modules/local/ensembl/tests/main.nf.test.snap b/modules/local/ensembl/tests/main.nf.test.snap deleted file mode 100644 index a6eb2971..00000000 --- a/modules/local/ensembl/tests/main.nf.test.snap +++ /dev/null @@ -1,17 +0,0 @@ -{ - "Should download Ensembl files": { - "content": [ - "Homo_sapiens.GRCh38.102.gtf", - "Homo_sapiens.GRCh38.102.dna.primary_assembly.fa", - "Homo_sapiens.GRCh38.102.chr.gtf", - [ - "versions.yml:md5,efb55665a151fe2b4d9eac70c0e01bb0" - ] - ], - "meta": { - "nf-test": "0.9.2", - "nextflow": "24.10.1" - }, - "timestamp": "2024-11-26T14:06:24.319131837" - } -} \ No newline at end of file diff --git a/modules/local/fusioncatcher/build/main.nf b/modules/local/fusioncatcher/build/main.nf new file mode 100644 index 00000000..4aaaf504 --- /dev/null +++ b/modules/local/fusioncatcher/build/main.nf @@ -0,0 +1,41 @@ +process FUSIONCATCHER_BUILD { + tag "fusioncatcher_build" + label 'process_medium' + + container "docker.io/rannickscilifelab/fusioncatcher:1.34" + + input: + val genome_gencode_version + + output: + path "human_v${genome_gencode_version}" , emit: reference + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + + def args = task.ext.args ?: '' + """ + fusioncatcher-build.py \\ + -g homo_sapiens \\ + -o human_v${genome_gencode_version} \\ + $args + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + fusioncatcher: \$(echo \$(fusioncatcher --version 2>&1)) + END_VERSIONS + """ + + stub: + """ + mkdir human_v${genome_gencode_version} + touch human_v${genome_gencode_version}/ensembl_fully_overlapping_genes.txt + cat <<-END_VERSIONS > versions.yml + "${task.process}": + fusioncatcher: \$(echo \$(fusioncatcher --version 2>&1)) + END_VERSIONS + """ +} diff --git a/modules/local/fusioncatcher/build/meta.yml b/modules/local/fusioncatcher/build/meta.yml new file mode 100644 index 00000000..202be7e1 --- /dev/null +++ b/modules/local/fusioncatcher/build/meta.yml @@ -0,0 +1,24 @@ +name: fusioncatcher_build +description: Build genome for fusioncatcher +keywords: + - sort +tools: + - fusioncatcher: + description: Build genome for fusioncatcher + homepage: https://github.com/ndaniel/fusioncatcher/ + documentation: https://github.com/ndaniel/fusioncatcher/blob/master/doc/manual.md + tool_dev_url: https://github.com/ndaniel/fusioncatcher/ + doi: "10.1101/011650" + licence: ["GPL v3"] + +output: + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" + - reference: + type: directory + description: Path to fusioncatcher references + +authors: + - "@praveenraj2018, @rannick" diff --git a/modules/local/fusioncatcher/download/main.nf b/modules/local/fusioncatcher/download/main.nf index f11491b9..c7ea28ec 100644 --- a/modules/local/fusioncatcher/download/main.nf +++ b/modules/local/fusioncatcher/download/main.nf @@ -4,8 +4,13 @@ process FUSIONCATCHER_DOWNLOAD { container "docker.io/rannickscilifelab/fusioncatcher:1.34" + + input: + val genome_gencode_version + + output: - path "*" , emit: reference + path "human_v${genome_gencode_version}" , emit: reference path "versions.yml" , emit: versions when: @@ -14,23 +19,16 @@ process FUSIONCATCHER_DOWNLOAD { script: def args = task.ext.args ?: '' - def args2 = task.ext.args2 ?: '' - def human_version = "v102" - def url = "http://sourceforge.net/projects/fusioncatcher/files/data/human_${human_version}.tar.gz.aa" + // TODO: move to S3 + + // def url = """ - if wget --spider "$url" 2>/dev/null; then - wget $args $url - wget $args http://sourceforge.net/projects/fusioncatcher/files/data/human_${human_version}.tar.gz.ab - wget $args http://sourceforge.net/projects/fusioncatcher/files/data/human_${human_version}.tar.gz.ac - wget $args http://sourceforge.net/projects/fusioncatcher/files/data/human_${human_version}.tar.gz.ad - cat human_${human_version}.tar.gz.* | tar xz - rm human_${human_version}.tar* - else - fusioncatcher-build \\ - -g homo_sapiens \\ - -o human_${human_version} \\ - $args2 - fi + wget $args http://sourceforge.net/projects/fusioncatcher/files/data/human_${genome_gencode_version}.tar.gz.aa + wget $args http://sourceforge.net/projects/fusioncatcher/files/data/human_${genome_gencode_version}.tar.gz.ab + wget $args http://sourceforge.net/projects/fusioncatcher/files/data/human_${genome_gencode_version}.tar.gz.ac + wget $args http://sourceforge.net/projects/fusioncatcher/files/data/human_${genome_gencode_version}.tar.gz.ad + cat human_${genome_gencode_version}.tar.gz.* | tar xz + rm human_${genome_gencode_version}.tar* cat <<-END_VERSIONS > versions.yml "${task.process}": @@ -39,9 +37,9 @@ process FUSIONCATCHER_DOWNLOAD { """ stub: - def human_version = "v102" """ - mkdir human_${human_version} + mkdir human_v${genome_gencode_version} + touch human_v${genome_gencode_version}/ensembl_fully_overlapping_genes.txt cat <<-END_VERSIONS > versions.yml "${task.process}": fusioncatcher: \$(echo \$(fusioncatcher --version 2>&1)) diff --git a/modules/local/fusionreport/detect/main.nf b/modules/local/fusionreport/detect/main.nf index 8981e601..56a29ab4 100644 --- a/modules/local/fusionreport/detect/main.nf +++ b/modules/local/fusionreport/detect/main.nf @@ -11,13 +11,13 @@ process FUSIONREPORT { val(tools_cutoff) output: - path "versions.yml" , emit: versions tuple val(meta), path("*fusionreport.tsv") , emit: fusion_list tuple val(meta), path("*fusionreport_filtered.tsv") , emit: fusion_list_filtered - tuple val(meta), path("*index.html") , emit: report + tuple val(meta), path("*index.html") , emit: report tuple val(meta), path("*_*.html") , optional:true, emit: html tuple val(meta), path("*.csv") , optional:true, emit: csv tuple val(meta), path("*.json") , optional:true, emit: json + path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when diff --git a/modules/local/gencode_download/main.nf b/modules/local/gencode_download/main.nf new file mode 100644 index 00000000..1f466d26 --- /dev/null +++ b/modules/local/gencode_download/main.nf @@ -0,0 +1,49 @@ +process GENCODE_DOWNLOAD { + tag "gencode_download" + label 'process_low' + + conda "bioconda::gnu-wget=1.18" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/gnu-wget:1.18--h5bf99c6_5' : + 'quay.io/biocontainers/gnu-wget:1.18--h5bf99c6_5' }" + + input: + val genome_gencode_version + val genome + + output: + path "*.fa" , emit: fasta + path "*.gtf" , emit: gtf + path "versions.yml", emit: versions + + + when: + task.ext.when == null || task.ext.when + + script: + def folder_gencode = genome.contains("38") ? "" : "/${genome}_mapping" + def gtf_file_name = genome.contains("38") ? "gencode.v${genome_gencode_version}.primary_assembly.annotation.gtf.gz" : "gencode.v${genome_gencode_version}lift${genome_gencode_version}.annotation.gtf.gz" + """ + wget ftp://ftp.ebi.ac.uk/pub/databases/gencode/Gencode_human/release_${genome_gencode_version}/${folder_gencode}${genome}.primary_assembly.genome.fa.gz -O Homo_sapiens_${genome}_${genome_gencode_version}_dna_primary_assembly.fa.gz + gunzip Homo_sapiens_${genome}_${genome_gencode_version}_dna_primary_assembly.fa.gz + wget ftp://ftp.ebi.ac.uk/pub/databases/gencode/Gencode_human/release_${genome_gencode_version}/${folder_gencode}${gtf_file_name} -O Homo_sapiens_${genome}_${genome_gencode_version}.gtf.gz + gunzip Homo_sapiens_${genome}_${genome_gencode_version}.gtf.gz + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + wget: \$(echo wget -V 2>&1 | grep "GNU Wget" | cut -d" " -f3) + END_VERSIONS + """ + + stub: + """ + touch Homo_sapiens.${genome}.${genome_gencode_version}_dna_primary_assembly.fa + touch Homo_sapiens.${genome}.${genome_gencode_version}.gtf + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + wget: \$(echo wget -V 2>&1 | grep "GNU Wget" | cut -d" " -f3) + END_VERSIONS + """ + +} diff --git a/modules/local/get_rrna_transcript/environment.yml b/modules/local/get_rrna_transcript/environment.yml new file mode 100644 index 00000000..66b65c3a --- /dev/null +++ b/modules/local/get_rrna_transcript/environment.yml @@ -0,0 +1,6 @@ +channels: + - conda-forge + - bioconda +dependencies: + - bioconda::pirate=1.0.5 + - bioconda::perl-bioperl=1.7.8 diff --git a/modules/local/get_rrna_transcript/main.nf b/modules/local/get_rrna_transcript/main.nf new file mode 100644 index 00000000..5331f534 --- /dev/null +++ b/modules/local/get_rrna_transcript/main.nf @@ -0,0 +1,43 @@ +process GET_RRNA_TRANSCRIPTS { + tag 'get_rrna_bed' + label 'process_low' + + conda "${moduleDir}/environment.yml" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/pirate:1.0.5--hdfd78af_0' : + 'biocontainers/pirate:1.0.5--hdfd78af_0' }" + + input: + tuple val(meta), path(gtf) + + output: + tuple val(meta), path('rrna.gtf') , emit: rrnagtf + tuple val(meta), path('rrna.bed') , emit: bed + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + """ + $baseDir/bin/get_rrna_transcripts.py --gtf ${gtf} --output rrna.gtf + + $baseDir/bin/gtf2bed rrna.gtf > rrna.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + get_rrna_transcripts: v1.0 + END_VERSIONS + """ + + stub: + """ + touch rrna.gtf + touch rrna.bed + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + get_rrna_transcripts: v1.0 + END_VERSIONS + """ +} diff --git a/modules/local/hgnc/main.nf b/modules/local/hgnc/main.nf index a3559726..aa5c077c 100644 --- a/modules/local/hgnc/main.nf +++ b/modules/local/hgnc/main.nf @@ -7,12 +7,9 @@ process HGNC_DOWNLOAD { 'https://depot.galaxyproject.org/singularity/gnu-wget:1.18--h5bf99c6_5' : 'biocontainers/gnu-wget:1.18--h5bf99c6_5' }" - input: - output: path "hgnc_complete_set.txt" , emit: hgnc_ref path "HGNC-DB-timestamp.txt" , emit: hgnc_date - path "versions.yml" , emit: versions diff --git a/modules/local/starfusion/build/main.nf b/modules/local/starfusion/build/main.nf index f1239789..fcd9cf80 100644 --- a/modules/local/starfusion/build/main.nf +++ b/modules/local/starfusion/build/main.nf @@ -15,6 +15,7 @@ process STARFUSION_BUILD { output: tuple val(meta), path("ctat_genome_lib_build_dir"), emit: reference + path "versions.yml" , emit: versions script: def args = task.ext.args ?: '' @@ -25,8 +26,8 @@ process STARFUSION_BUILD { --dfam_db ${dfam_species} \\ --pfam_db current \\ --fusion_annot_lib $fusion_annot_lib \\ - ${args} \\ - --CPU $task.cpus + --CPU $task.cpus \\ + ${args} cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/local/starfusion/download/main.nf b/modules/local/starfusion/download/main.nf index 989c2420..ace18a9e 100644 --- a/modules/local/starfusion/download/main.nf +++ b/modules/local/starfusion/download/main.nf @@ -8,9 +8,9 @@ process STARFUSION_DOWNLOAD { output: path "ctat_genome_lib_build_dir/*" , emit: reference - path "ctat_genome_lib_build_dir/ref_annot.gtf", emit: chrgtf + // TODO: move to S3 script: """ wget https://data.broadinstitute.org/Trinity/CTAT_RESOURCE_LIB/__genome_libs_StarFv1.10/GRCh38_gencode_v37_CTAT_lib_Mar012021.plug-n-play.tar.gz --no-check-certificate diff --git a/modules/local/uscs/custom_gtftogenepred/main.nf b/modules/local/uscs/custom_gtftogenepred/main.nf new file mode 100644 index 00000000..9cc15765 --- /dev/null +++ b/modules/local/uscs/custom_gtftogenepred/main.nf @@ -0,0 +1,39 @@ +process GTF_TO_REFFLAT { + tag "$meta.id" + label 'process_low' + + conda "bioconda::ucsc-gtftogenepred=377" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/ucsc-gtftogenepred:377--ha8a8165_5' : + 'quay.io/biocontainers/ucsc-gtftogenepred:377--ha8a8165_5' }" + + input: + tuple val(meta), path (gtf) + + output: + path('*.refflat') , emit: refflat + path "versions.yml" , emit: versions + + script: + def genepred = gtf + '.genepred' + def refflat = gtf + '.refflat' + """ + gtfToGenePred -genePredExt -geneNameAsName2 ${gtf} ${genepred} + paste ${genepred} ${genepred} | cut -f12,16-25 > ${refflat} + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + gtfToGenePred: 377 + END_VERSIONS + """ + + stub: + def refflat = gtf + '.refflat' + """ + touch ${refflat} + cat <<-END_VERSIONS > versions.yml + "${task.process}": + gtfToGenePred: 377 + END_VERSIONS + """ +} diff --git a/modules/nf-core/arriba/download/main.nf b/modules/nf-core/arriba/download/main.nf index 96a4e336..c45120ad 100644 --- a/modules/nf-core/arriba/download/main.nf +++ b/modules/nf-core/arriba/download/main.nf @@ -8,17 +8,21 @@ process ARRIBA_DOWNLOAD { 'biocontainers/arriba:2.4.0--h0033a41_2' }" input: + val(genome) output: - path "*" , emit: reference - path "versions.yml" , emit: versions + path "blacklist*${genome}*.tsv.gz" , emit: blacklist + path "cytobands*${genome}*.tsv" , emit: cytobands + path "protein_domains*${genome}*.gff3" , emit: protein_domains + path "known_fusions*${genome}*.tsv.gz" , emit: known_fusions + path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when script: """ - wget https://github.com/suhrig/arriba/releases/download/v2.4.0/arriba_v2.4.0.tar.gz -O arriba_v2.4.0.tar.gz + wget https://github.com/suhrig/arriba/releases/download/v2.4.0/arriba_v2.4.0.tar.gz -O arriba_v2.4.0.tar.gz --no-check-certificate tar -xzvf arriba_v2.4.0.tar.gz rm arriba_v2.4.0.tar.gz mv arriba_v2.4.0/database/* . @@ -36,7 +40,6 @@ process ARRIBA_DOWNLOAD { touch protein_domains_hg38_GRCh38_v2.4.0.gff3 touch cytobands_hg38_GRCh38_v2.4.0.tsv touch known_fusions_hg38_GRCh38_v2.4.0.tsv.gz - touch protein_domains_hg38_GRCh38_v2.4.0.gff3 cat <<-END_VERSIONS > versions.yml "${task.process}": diff --git a/modules/nf-core/arriba/download/meta.yml b/modules/nf-core/arriba/download/meta.yml index 531c66c2..bdf542eb 100644 --- a/modules/nf-core/arriba/download/meta.yml +++ b/modules/nf-core/arriba/download/meta.yml @@ -15,12 +15,34 @@ tools: licence: ["MIT"] identifier: biotools:Arriba +input: + - - genome: + type: string + description: hg38, hg19, GRCh38, GRCh37 for humans are accepted output: - - reference: - - "*": - type: directory - description: Folder with arriba references - pattern: "*" + - blacklist: + - blacklist*${genome}*.tsv.gz: + type: string + description: The blacklist removes recurrent alignment artifacts and transcripts + which are present in healthy tissue + pattern: ".tsv.gz" + - cytobands: + - cytobands*${genome}*.tsv: + type: file + description: Coordinates of the Giemsa staining bands. This information is used + to draw ideograms + pattern: ".tsv" + - protein_domains: + - protein_domains*${genome}*.gff3: + type: file + description: Protein domain annotations + patter: "*.gff3" + - known_fusions: + - known_fusions*${genome}*.tsv.gz: + type: file + description: Arriba is more sensitive to those fusions to improve the detection + rate of expected or highly relevant events, such as recurrent fusions + patter: "*.tsv.gz" - versions: - versions.yml: type: file diff --git a/modules/nf-core/arriba/download/tests/main.nf.test b/modules/nf-core/arriba/download/tests/main.nf.test index cccc95db..2c32c7a0 100644 --- a/modules/nf-core/arriba/download/tests/main.nf.test +++ b/modules/nf-core/arriba/download/tests/main.nf.test @@ -11,11 +11,10 @@ nextflow_process { tag "arriba/download" test("test-arriba-download") { - when { process { """ - + input[0] = 'GRCh38' """ } } @@ -23,11 +22,27 @@ nextflow_process { then { assertAll( { assert process.success }, - { assert snapshot( - process.out.reference[0].collect { file(it).name }.toSorted(), - process.out.versions - ).match() - } + { assert snapshot(process.out).match() } + ) + } + + } + + test("download - stub") { + + options "-stub" + + when { + process { + """ + input[0] = 'GRCh38' + """ + } + } + + then { + assertAll( + { assert process.success } ) } } diff --git a/modules/nf-core/arriba/download/tests/main.nf.test.snap b/modules/nf-core/arriba/download/tests/main.nf.test.snap index eda3f706..fe9b18b9 100644 --- a/modules/nf-core/arriba/download/tests/main.nf.test.snap +++ b/modules/nf-core/arriba/download/tests/main.nf.test.snap @@ -1,35 +1,43 @@ { - "test-arriba-download": { + "download": { "content": [ - [ - "CREDITS", - "RefSeq_viral_genomes_v2.4.0.fa.gz", - "blacklist_hg19_hs37d5_GRCh37_v2.4.0.tsv.gz", - "blacklist_hg38_GRCh38_v2.4.0.tsv.gz", - "blacklist_mm10_GRCm38_v2.4.0.tsv.gz", - "blacklist_mm39_GRCm39_v2.4.0.tsv.gz", - "cytobands_hg19_hs37d5_GRCh37_v2.4.0.tsv", - "cytobands_hg38_GRCh38_v2.4.0.tsv", - "cytobands_mm10_GRCm38_v2.4.0.tsv", - "cytobands_mm39_GRCm39_v2.4.0.tsv", - "known_fusions_hg19_hs37d5_GRCh37_v2.4.0.tsv.gz", - "known_fusions_hg38_GRCh38_v2.4.0.tsv.gz", - "known_fusions_mm10_GRCm38_v2.4.0.tsv.gz", - "known_fusions_mm39_GRCm39_v2.4.0.tsv.gz", - "protein_domains_hg19_hs37d5_GRCh37_v2.4.0.gff3", - "protein_domains_hg38_GRCh38_v2.4.0.gff3", - "protein_domains_mm10_GRCm38_v2.4.0.gff3", - "protein_domains_mm39_GRCm39_v2.4.0.gff3", - "versions.yml" - ], - [ - "versions.yml:md5,98c69df5eaea5caf0b4af7b8d7af4893" - ] + { + "0": [ + "blacklist_hg38_GRCh38_v2.4.0.tsv.gz:md5,e3098a4be51aece78aede64b55c39318" + ], + "1": [ + "cytobands_hg38_GRCh38_v2.4.0.tsv:md5,7bd504feefb33fcfc9be0517439a423c" + ], + "2": [ + "protein_domains_hg38_GRCh38_v2.4.0.gff3:md5,43c387a784ebeed71b4147076cebf978" + ], + "3": [ + "known_fusions_hg38_GRCh38_v2.4.0.tsv.gz:md5,4f00f81ccb5f4db283f1a22b8b0da67c" + ], + "4": [ + "versions.yml:md5,98c69df5eaea5caf0b4af7b8d7af4893" + ], + "blacklist": [ + "blacklist_hg38_GRCh38_v2.4.0.tsv.gz:md5,e3098a4be51aece78aede64b55c39318" + ], + "cytobands": [ + "cytobands_hg38_GRCh38_v2.4.0.tsv:md5,7bd504feefb33fcfc9be0517439a423c" + ], + "known_fusions": [ + "known_fusions_hg38_GRCh38_v2.4.0.tsv.gz:md5,4f00f81ccb5f4db283f1a22b8b0da67c" + ], + "protein_domains": [ + "protein_domains_hg38_GRCh38_v2.4.0.gff3:md5,43c387a784ebeed71b4147076cebf978" + ], + "versions": [ + "versions.yml:md5,98c69df5eaea5caf0b4af7b8d7af4893" + ] + } ], "meta": { - "nf-test": "0.8.4", + "nf-test": "0.9.0", "nextflow": "24.04.4" }, - "timestamp": "2024-08-22T17:00:38.086459" + "timestamp": "2024-10-08T11:12:17.010496" } } \ No newline at end of file diff --git a/modules/nf-core/arriba/download/tests/tags.yml b/modules/nf-core/arriba/download/tests/tags.yml new file mode 100644 index 00000000..f510bbf1 --- /dev/null +++ b/modules/nf-core/arriba/download/tests/tags.yml @@ -0,0 +1,2 @@ +arriba/download: + - "modules/nf-core/arriba/download/**" diff --git a/modules/nf-core/cat/fastq/environment.yml b/modules/nf-core/cat/fastq/environment.yml index c7eb9bd1..71e04c3d 100644 --- a/modules/nf-core/cat/fastq/environment.yml +++ b/modules/nf-core/cat/fastq/environment.yml @@ -2,4 +2,4 @@ channels: - conda-forge - bioconda dependencies: - - conda-forge::coreutils=8.30 + - conda-forge::coreutils=9.5 diff --git a/modules/nf-core/cat/fastq/main.nf b/modules/nf-core/cat/fastq/main.nf index b68e5f91..4364a389 100644 --- a/modules/nf-core/cat/fastq/main.nf +++ b/modules/nf-core/cat/fastq/main.nf @@ -4,8 +4,8 @@ process CAT_FASTQ { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/ubuntu:20.04' : - 'nf-core/ubuntu:20.04' }" + 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/c2/c262fc09eca59edb5a724080eeceb00fb06396f510aefb229c2d2c6897e63975/data' : + 'community.wave.seqera.io/library/coreutils:9.5--ae99c88a9b28c264' }" input: tuple val(meta), path(reads, stageAs: "input*/*") diff --git a/modules/nf-core/cat/fastq/tests/main.nf.test.snap b/modules/nf-core/cat/fastq/tests/main.nf.test.snap index aec119a9..f8689a1c 100644 --- a/modules/nf-core/cat/fastq/tests/main.nf.test.snap +++ b/modules/nf-core/cat/fastq/tests/main.nf.test.snap @@ -12,7 +12,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -24,15 +24,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-01-17T17:30:39.816981" + "timestamp": "2024-10-19T20:02:07.519211144" }, "test_cat_fastq_single_end_same_name": { "content": [ @@ -47,7 +47,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -59,15 +59,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-01-17T17:32:35.229332" + "timestamp": "2024-10-19T20:02:31.618628921" }, "test_cat_fastq_single_end_single_file": { "content": [ @@ -82,7 +82,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -94,15 +94,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-01-17T17:34:00.058829" + "timestamp": "2024-10-19T20:02:57.904149581" }, "test_cat_fastq_paired_end_same_name": { "content": [ @@ -120,7 +120,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -135,15 +135,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-01-17T17:33:33.031555" + "timestamp": "2024-10-19T20:02:44.577183829" }, "test_cat_fastq_single_end - stub": { "content": [ @@ -158,7 +158,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -170,15 +170,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-07-05T12:07:28.244999" + "timestamp": "2024-10-19T20:03:10.603734777" }, "test_cat_fastq_paired_end_same_name - stub": { "content": [ @@ -196,7 +196,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -211,15 +211,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-07-05T12:07:57.070911" + "timestamp": "2024-10-19T20:03:46.041808828" }, "test_cat_fastq_single_end_same_name - stub": { "content": [ @@ -234,7 +234,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -246,15 +246,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-07-05T12:07:46.796254" + "timestamp": "2024-10-19T20:03:34.13865402" }, "test_cat_fastq_paired_end": { "content": [ @@ -272,7 +272,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -287,15 +287,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-01-17T17:32:02.270935" + "timestamp": "2024-10-19T20:02:19.64383573" }, "test_cat_fastq_paired_end - stub": { "content": [ @@ -313,7 +313,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -328,15 +328,15 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-07-05T12:07:37.807553" + "timestamp": "2024-10-19T20:03:22.597246066" }, "test_cat_fastq_single_end_single_file - stub": { "content": [ @@ -351,7 +351,7 @@ ] ], "1": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ], "reads": [ [ @@ -363,14 +363,14 @@ ] ], "versions": [ - "versions.yml:md5,d42d6e24d67004608495883e00bd501b" + "versions.yml:md5,6ef4fd28546a005865b9454bbedbf81a" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "24.04.2" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-07-05T12:14:51.861264" + "timestamp": "2024-10-19T20:03:58.44849001" } } \ No newline at end of file diff --git a/modules/nf-core/fastqc/main.nf b/modules/nf-core/fastqc/main.nf index d8989f48..752c3a10 100644 --- a/modules/nf-core/fastqc/main.nf +++ b/modules/nf-core/fastqc/main.nf @@ -24,7 +24,7 @@ process FASTQC { // Make list of old name and new name pairs to use for renaming in the bash while loop def old_new_pairs = reads instanceof Path || reads.size() == 1 ? [[ reads, "${prefix}.${reads.extension}" ]] : reads.withIndex().collect { entry, index -> [ entry, "${prefix}_${index + 1}.${entry.extension}" ] } def rename_to = old_new_pairs*.join(' ').join(' ') - def renamed_files = old_new_pairs.collect{ old_name, new_name -> new_name }.join(' ') + def renamed_files = old_new_pairs.collect{ _old_name, new_name -> new_name }.join(' ') // The total amount of allocated RAM by FastQC is equal to the number of threads defined (--threads) time the amount of RAM defined (--memory) // https://github.com/s-andrews/FastQC/blob/1faeea0412093224d7f6a07f777fad60a5650795/fastqc#L211-L222 diff --git a/modules/nf-core/fastqc/meta.yml b/modules/nf-core/fastqc/meta.yml index 4827da7a..2b2e62b8 100644 --- a/modules/nf-core/fastqc/meta.yml +++ b/modules/nf-core/fastqc/meta.yml @@ -11,6 +11,7 @@ tools: FastQC gives general quality metrics about your reads. It provides information about the quality score distribution across your reads, the per base sequence content (%A/C/G/T). + You get information about adapter contamination and other overrepresented sequences. homepage: https://www.bioinformatics.babraham.ac.uk/projects/fastqc/ diff --git a/modules/nf-core/gatk4/bedtointervallist/environment.yml b/modules/nf-core/gatk4/bedtointervallist/environment.yml index 55993f44..1f7d0824 100644 --- a/modules/nf-core/gatk4/bedtointervallist/environment.yml +++ b/modules/nf-core/gatk4/bedtointervallist/environment.yml @@ -1,5 +1,10 @@ +--- +# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json channels: - conda-forge - bioconda dependencies: - - bioconda::gatk4=4.5.0.0 + # renovate: datasource=conda depName=bioconda/gatk4 + - bioconda::gatk4=4.6.1.0 + # renovate: datasource=conda depName=bioconda/gcnvkernel + - bioconda::gcnvkernel=0.9 diff --git a/modules/nf-core/gatk4/bedtointervallist/main.nf b/modules/nf-core/gatk4/bedtointervallist/main.nf index 68863d67..89960e04 100644 --- a/modules/nf-core/gatk4/bedtointervallist/main.nf +++ b/modules/nf-core/gatk4/bedtointervallist/main.nf @@ -1,11 +1,11 @@ process GATK4_BEDTOINTERVALLIST { tag "$meta.id" - label 'process_medium' + label 'process_single' conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/gatk4:4.5.0.0--py36hdfd78af_0': - 'biocontainers/gatk4:4.5.0.0--py36hdfd78af_0' }" + 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/b2/b28daf5d9bb2f0d129dcad1b7410e0dd8a9b087aaf3ec7ced929b1f57624ad98/data': + 'community.wave.seqera.io/library/gatk4_gcnvkernel:e48d414933d188cd' }" input: tuple val(meta), path(bed) diff --git a/modules/nf-core/gatk4/bedtointervallist/tests/main.nf.test.snap b/modules/nf-core/gatk4/bedtointervallist/tests/main.nf.test.snap index 48c322fd..6936cf97 100644 --- a/modules/nf-core/gatk4/bedtointervallist/tests/main.nf.test.snap +++ b/modules/nf-core/gatk4/bedtointervallist/tests/main.nf.test.snap @@ -11,7 +11,7 @@ ] ], "1": [ - "versions.yml:md5,29a18c36f27584eb5a5f2f5457088b3b" + "versions.yml:md5,6b3aa4d49cc3ba433ecf92e31f155d00" ], "interval_list": [ [ @@ -22,14 +22,14 @@ ] ], "versions": [ - "versions.yml:md5,29a18c36f27584eb5a5f2f5457088b3b" + "versions.yml:md5,6b3aa4d49cc3ba433ecf92e31f155d00" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.1", + "nextflow": "24.10.0" }, - "timestamp": "2024-03-19T14:20:12.168775" + "timestamp": "2024-10-31T10:37:25.720782902" } } \ No newline at end of file diff --git a/modules/nf-core/gatk4/createsequencedictionary/environment.yml b/modules/nf-core/gatk4/createsequencedictionary/environment.yml index 55993f44..1f7d0824 100644 --- a/modules/nf-core/gatk4/createsequencedictionary/environment.yml +++ b/modules/nf-core/gatk4/createsequencedictionary/environment.yml @@ -1,5 +1,10 @@ +--- +# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json channels: - conda-forge - bioconda dependencies: - - bioconda::gatk4=4.5.0.0 + # renovate: datasource=conda depName=bioconda/gatk4 + - bioconda::gatk4=4.6.1.0 + # renovate: datasource=conda depName=bioconda/gcnvkernel + - bioconda::gcnvkernel=0.9 diff --git a/modules/nf-core/gatk4/createsequencedictionary/main.nf b/modules/nf-core/gatk4/createsequencedictionary/main.nf index c7f1d75b..998622a0 100644 --- a/modules/nf-core/gatk4/createsequencedictionary/main.nf +++ b/modules/nf-core/gatk4/createsequencedictionary/main.nf @@ -1,11 +1,11 @@ process GATK4_CREATESEQUENCEDICTIONARY { tag "$fasta" - label 'process_medium' + label 'process_single' conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/gatk4:4.5.0.0--py36hdfd78af_0': - 'biocontainers/gatk4:4.5.0.0--py36hdfd78af_0' }" + 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/b2/b28daf5d9bb2f0d129dcad1b7410e0dd8a9b087aaf3ec7ced929b1f57624ad98/data': + 'community.wave.seqera.io/library/gatk4_gcnvkernel:e48d414933d188cd' }" input: tuple val(meta), path(fasta) diff --git a/modules/nf-core/gatk4/createsequencedictionary/tests/main.nf.test.snap b/modules/nf-core/gatk4/createsequencedictionary/tests/main.nf.test.snap index 16735f95..e8a600fd 100644 --- a/modules/nf-core/gatk4/createsequencedictionary/tests/main.nf.test.snap +++ b/modules/nf-core/gatk4/createsequencedictionary/tests/main.nf.test.snap @@ -11,7 +11,7 @@ ] ], "1": [ - "versions.yml:md5,e60dd34a71fc2029d81dc67ccb5d6be6" + "versions.yml:md5,e993b2c99f7f6b0fcd8428de15c61439" ], "dict": [ [ @@ -22,15 +22,15 @@ ] ], "versions": [ - "versions.yml:md5,e60dd34a71fc2029d81dc67ccb5d6be6" + "versions.yml:md5,e993b2c99f7f6b0fcd8428de15c61439" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.0" + "nf-test": "0.9.1", + "nextflow": "24.10.0" }, - "timestamp": "2024-05-16T10:16:16.34453" + "timestamp": "2024-10-31T10:51:56.155954077" }, "sarscov2 - fasta": { "content": [ @@ -44,7 +44,7 @@ ] ], "1": [ - "versions.yml:md5,e60dd34a71fc2029d81dc67ccb5d6be6" + "versions.yml:md5,e993b2c99f7f6b0fcd8428de15c61439" ], "dict": [ [ @@ -55,14 +55,14 @@ ] ], "versions": [ - "versions.yml:md5,e60dd34a71fc2029d81dc67ccb5d6be6" + "versions.yml:md5,e993b2c99f7f6b0fcd8428de15c61439" ] } ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.0" + "nf-test": "0.9.1", + "nextflow": "24.10.0" }, - "timestamp": "2024-05-16T13:58:25.822068" + "timestamp": "2024-10-31T10:51:45.562993875" } } \ No newline at end of file diff --git a/modules/nf-core/gatk4/markduplicates/environment.yml b/modules/nf-core/gatk4/markduplicates/environment.yml index 3c73c17e..ec65c32d 100644 --- a/modules/nf-core/gatk4/markduplicates/environment.yml +++ b/modules/nf-core/gatk4/markduplicates/environment.yml @@ -1,8 +1,15 @@ +--- +# yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json channels: - conda-forge - bioconda dependencies: - - bioconda::gatk4=4.5.0.0 + # renovate: datasource=conda depName=bioconda/gatk4 + - bioconda::gatk4=4.6.1.0 + # renovate: datasource=conda depName=bioconda/gcnvkernel + - bioconda::gcnvkernel=0.9 + # renovate: datasource=conda depName=bioconda/htslib - bioconda::htslib=1.19.1 + # renovate: datasource=conda depName=bioconda/samtools - bioconda::samtools=1.19.2 diff --git a/modules/nf-core/gatk4/markduplicates/main.nf b/modules/nf-core/gatk4/markduplicates/main.nf index baadefef..cf770308 100644 --- a/modules/nf-core/gatk4/markduplicates/main.nf +++ b/modules/nf-core/gatk4/markduplicates/main.nf @@ -1,6 +1,6 @@ process GATK4_MARKDUPLICATES { tag "$meta.id" - label 'process_medium' + label 'process_low' conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? diff --git a/modules/nf-core/gffread/tests/main.nf.test b/modules/nf-core/gffread/tests/main.nf.test index 4cd13dcd..d039f367 100644 --- a/modules/nf-core/gffread/tests/main.nf.test +++ b/modules/nf-core/gffread/tests/main.nf.test @@ -23,6 +23,7 @@ nextflow_process { file(params.modules_testdata_base_path + "genomics/sarscov2/genome/genome.gff3", checkIfExists: true) ] input[1] = [] + """ } } @@ -220,4 +221,4 @@ nextflow_process { } -} +} \ No newline at end of file diff --git a/modules/nf-core/picard/collectinsertsizemetrics/environment.yml b/modules/nf-core/picard/collectinsertsizemetrics/environment.yml index ff4a85ed..1d715d56 100644 --- a/modules/nf-core/picard/collectinsertsizemetrics/environment.yml +++ b/modules/nf-core/picard/collectinsertsizemetrics/environment.yml @@ -2,4 +2,4 @@ channels: - conda-forge - bioconda dependencies: - - bioconda::picard=3.2.0 + - bioconda::picard=3.3.0 diff --git a/modules/nf-core/picard/collectinsertsizemetrics/main.nf b/modules/nf-core/picard/collectinsertsizemetrics/main.nf index 1a49a7f0..c3014d80 100644 --- a/modules/nf-core/picard/collectinsertsizemetrics/main.nf +++ b/modules/nf-core/picard/collectinsertsizemetrics/main.nf @@ -4,8 +4,8 @@ process PICARD_COLLECTINSERTSIZEMETRICS { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/picard:3.2.0--hdfd78af_0' : - 'biocontainers/picard:3.2.0--hdfd78af_0' }" + 'https://depot.galaxyproject.org/singularity/picard:3.3.0--hdfd78af_0' : + 'biocontainers/picard:3.3.0--hdfd78af_0' }" input: tuple val(meta), path(bam) diff --git a/modules/nf-core/picard/collectinsertsizemetrics/tests/main.nf.test.snap b/modules/nf-core/picard/collectinsertsizemetrics/tests/main.nf.test.snap index bcb5b455..cbe9329d 100644 --- a/modules/nf-core/picard/collectinsertsizemetrics/tests/main.nf.test.snap +++ b/modules/nf-core/picard/collectinsertsizemetrics/tests/main.nf.test.snap @@ -9,14 +9,14 @@ ], "test.pdf", [ - "versions.yml:md5,4423bfe2194f61d919c382d2225b0835" + "versions.yml:md5,38d39e9882afe7ac015213c286745056" ] ], "meta": { - "nf-test": "0.8.4", + "nf-test": "0.9.0", "nextflow": "24.04.4" }, - "timestamp": "2024-08-30T12:23:29.392944" + "timestamp": "2024-10-18T10:55:45.769771444" }, "test-picard-collectinsertsizemetrics-stub": { "content": [ @@ -40,7 +40,7 @@ ] ], "2": [ - "versions.yml:md5,4423bfe2194f61d919c382d2225b0835" + "versions.yml:md5,38d39e9882afe7ac015213c286745056" ], "histogram": [ [ @@ -61,14 +61,14 @@ ] ], "versions": [ - "versions.yml:md5,4423bfe2194f61d919c382d2225b0835" + "versions.yml:md5,38d39e9882afe7ac015213c286745056" ] } ], "meta": { - "nf-test": "0.8.4", + "nf-test": "0.9.0", "nextflow": "24.04.4" }, - "timestamp": "2024-08-30T12:20:03.841884" + "timestamp": "2024-10-18T10:56:09.914953495" } } \ No newline at end of file diff --git a/modules/nf-core/picard/collectwgsmetrics/environment.yml b/modules/nf-core/picard/collectwgsmetrics/environment.yml index 58d52581..13265842 100644 --- a/modules/nf-core/picard/collectwgsmetrics/environment.yml +++ b/modules/nf-core/picard/collectwgsmetrics/environment.yml @@ -2,5 +2,5 @@ channels: - conda-forge - bioconda dependencies: - - bioconda::picard=3.2.0 - - r::r-base + - bioconda::picard=3.3.0 + - conda-forge::r-base=4.4.1 diff --git a/modules/nf-core/picard/collectwgsmetrics/main.nf b/modules/nf-core/picard/collectwgsmetrics/main.nf index 6002a7ca..39cf7d2b 100644 --- a/modules/nf-core/picard/collectwgsmetrics/main.nf +++ b/modules/nf-core/picard/collectwgsmetrics/main.nf @@ -4,8 +4,8 @@ process PICARD_COLLECTWGSMETRICS { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/picard:3.2.0--hdfd78af_0' : - 'biocontainers/picard:3.2.0--hdfd78af_0' }" + 'https://depot.galaxyproject.org/singularity/picard:3.3.0--hdfd78af_0' : + 'biocontainers/picard:3.3.0--hdfd78af_0' }" input: tuple val(meta), path(bam), path(bai) diff --git a/modules/nf-core/picard/collectwgsmetrics/tests/main.nf.test.snap b/modules/nf-core/picard/collectwgsmetrics/tests/main.nf.test.snap index f188382b..1958fcde 100644 --- a/modules/nf-core/picard/collectwgsmetrics/tests/main.nf.test.snap +++ b/modules/nf-core/picard/collectwgsmetrics/tests/main.nf.test.snap @@ -3,26 +3,26 @@ "content": [ true, [ - "versions.yml:md5,06b5898fb06823b736c90e1dcebe75fe" + "versions.yml:md5,9927db69fdd55176be5cdbd427d000c2" ] ], "meta": { - "nf-test": "0.8.4", + "nf-test": "0.9.0", "nextflow": "24.04.4" }, - "timestamp": "2024-08-23T11:02:46.301176" + "timestamp": "2024-10-18T10:15:18.13771243" }, "test-picard-collectwgsmetrics": { "content": [ true, [ - "versions.yml:md5,06b5898fb06823b736c90e1dcebe75fe" + "versions.yml:md5,9927db69fdd55176be5cdbd427d000c2" ] ], "meta": { - "nf-test": "0.8.4", + "nf-test": "0.9.0", "nextflow": "24.04.4" }, - "timestamp": "2024-08-23T11:02:25.132069" + "timestamp": "2024-10-18T10:14:57.786056996" } } \ No newline at end of file diff --git a/modules/nf-core/salmon/index/environment.yml b/modules/nf-core/salmon/index/environment.yml index 471164fa..b3f75777 100644 --- a/modules/nf-core/salmon/index/environment.yml +++ b/modules/nf-core/salmon/index/environment.yml @@ -2,4 +2,4 @@ channels: - conda-forge - bioconda dependencies: - - bioconda::salmon=1.10.1 + - bioconda::salmon=1.10.3 diff --git a/modules/nf-core/salmon/index/main.nf b/modules/nf-core/salmon/index/main.nf index e755d9a3..3d653c0d 100644 --- a/modules/nf-core/salmon/index/main.nf +++ b/modules/nf-core/salmon/index/main.nf @@ -4,8 +4,8 @@ process SALMON_INDEX { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/salmon:1.10.1--h7e5ed60_0' : - 'biocontainers/salmon:1.10.1--h7e5ed60_0' }" + 'https://depot.galaxyproject.org/singularity/salmon:1.10.3--h6dccd9a_2' : + 'biocontainers/salmon:1.10.3--h6dccd9a_2' }" input: path genome_fasta diff --git a/modules/nf-core/salmon/index/tests/main.nf.test.snap b/modules/nf-core/salmon/index/tests/main.nf.test.snap index 703e455c..e5899b51 100644 --- a/modules/nf-core/salmon/index/tests/main.nf.test.snap +++ b/modules/nf-core/salmon/index/tests/main.nf.test.snap @@ -2,25 +2,25 @@ "versions": { "content": [ [ - "versions.yml:md5,563eeafb4577be0b13801d7021c0bf42" + "versions.yml:md5,85337fa0a286ea35073ee5260974e307" ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2023-11-22T14:26:33.32036" + "timestamp": "2024-10-18T10:00:47.087293189" }, "versions stub": { "content": [ [ - "versions.yml:md5,563eeafb4577be0b13801d7021c0bf42" + "versions.yml:md5,85337fa0a286ea35073ee5260974e307" ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-04-23T09:47:58.828124" + "timestamp": "2024-10-18T10:01:03.89824494" } } \ No newline at end of file diff --git a/modules/nf-core/salmon/quant/environment.yml b/modules/nf-core/salmon/quant/environment.yml index 471164fa..b3f75777 100644 --- a/modules/nf-core/salmon/quant/environment.yml +++ b/modules/nf-core/salmon/quant/environment.yml @@ -2,4 +2,4 @@ channels: - conda-forge - bioconda dependencies: - - bioconda::salmon=1.10.1 + - bioconda::salmon=1.10.3 diff --git a/modules/nf-core/salmon/quant/main.nf b/modules/nf-core/salmon/quant/main.nf index 6c528b24..f1e3b5cd 100644 --- a/modules/nf-core/salmon/quant/main.nf +++ b/modules/nf-core/salmon/quant/main.nf @@ -4,8 +4,8 @@ process SALMON_QUANT { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/salmon:1.10.1--h7e5ed60_0' : - 'biocontainers/salmon:1.10.1--h7e5ed60_0' }" + 'https://depot.galaxyproject.org/singularity/salmon:1.10.3--h6dccd9a_2' : + 'biocontainers/salmon:1.10.3--h6dccd9a_2' }" input: tuple val(meta), path(reads) diff --git a/modules/nf-core/salmon/quant/tests/main.nf.test.snap b/modules/nf-core/salmon/quant/tests/main.nf.test.snap index 547ce2de..ea22a80c 100644 --- a/modules/nf-core/salmon/quant/tests/main.nf.test.snap +++ b/modules/nf-core/salmon/quant/tests/main.nf.test.snap @@ -2,7 +2,7 @@ "sarscov2 - single_end": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -15,15 +15,15 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:51:22.424672" + "timestamp": "2024-10-18T10:01:16.989080539" }, "sarscov2 - single_end stub": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -36,15 +36,15 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:51:32.292277" + "timestamp": "2024-10-18T10:01:29.340996235" }, "sarscov2 - single_end lib type A": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -57,15 +57,15 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:51:42.656382" + "timestamp": "2024-10-18T10:01:43.056167576" }, "sarscov2 - pair_end multiple": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -78,15 +78,15 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:52:33.03647" + "timestamp": "2024-10-18T10:03:05.500792631" }, "sarscov2 - pair_end multiple stub": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -99,15 +99,15 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:52:43.388379" + "timestamp": "2024-10-18T10:03:26.428959203" }, "sarscov2 - single_end lib type A stub": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -120,15 +120,15 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:51:52.612664" + "timestamp": "2024-10-18T10:02:03.420850208" }, "sarscov2 - pair_end": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -141,15 +141,15 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:52:05.577881" + "timestamp": "2024-10-18T10:02:16.130074696" }, "sarscov2 - pair_end stub": { "content": [ [ - "versions.yml:md5,80eb3d2ad36960c7e9263f81ede9d263" + "versions.yml:md5,0d510d5db6398e2c8ca9443330740607" ], [ [ @@ -162,9 +162,9 @@ ] ], "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" + "nf-test": "0.9.0", + "nextflow": "24.04.4" }, - "timestamp": "2024-06-14T09:52:15.286461" + "timestamp": "2024-10-18T10:02:39.470004547" } } \ No newline at end of file diff --git a/modules/nf-core/samtools/sort/main.nf b/modules/nf-core/samtools/sort/main.nf index acfd9252..caf3c61a 100644 --- a/modules/nf-core/samtools/sort/main.nf +++ b/modules/nf-core/samtools/sort/main.nf @@ -12,11 +12,11 @@ process SAMTOOLS_SORT { tuple val(meta2), path(fasta) output: - tuple val(meta), path("*.bam"), emit: bam, optional: true - tuple val(meta), path("*.cram"), emit: cram, optional: true - tuple val(meta), path("*.crai"), emit: crai, optional: true - tuple val(meta), path("*.csi"), emit: csi, optional: true - path "versions.yml" , emit: versions + tuple val(meta), path("*.bam"), emit: bam, optional: true + tuple val(meta), path("*.cram"), emit: cram, optional: true + tuple val(meta), path("*.crai"), emit: crai, optional: true + tuple val(meta), path("*.csi"), emit: csi, optional: true + path "versions.yml", emit: versions when: task.ext.when == null || task.ext.when diff --git a/modules/nf-core/samtools/sort/tests/main.nf.test b/modules/nf-core/samtools/sort/tests/main.nf.test index c2ea9c72..b05e6691 100644 --- a/modules/nf-core/samtools/sort/tests/main.nf.test +++ b/modules/nf-core/samtools/sort/tests/main.nf.test @@ -39,6 +39,40 @@ nextflow_process { } } + test("multiple bam") { + + config "./nextflow.config" + + when { + process { + """ + input[0] = Channel.of([ + [ id:'test', single_end:false ], // meta map + [ + file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/bam/test.paired_end.sorted.bam', checkIfExists: true), + file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/bam/test2.paired_end.sorted.bam', checkIfExists: true) + ] + ]) + input[1] = Channel.of([ + [ id:'fasta' ], // meta map + file(params.modules_testdata_base_path + 'genomics/homo_sapiens/genome/genome.fasta', checkIfExists: true) + ]) + """ + } + } + + then { + assertAll ( + { assert process.success }, + { assert snapshot( + process.out.bam, + process.out.csi.collect { it.collect { it instanceof Map ? it : file(it).name } }, + process.out.versions + ).match()} + ) + } + } + test("cram") { config "./nextflow_cram.config" @@ -98,6 +132,36 @@ nextflow_process { } } + test("multiple bam - stub") { + + config "./nextflow.config" + + when { + process { + """ + input[0] = Channel.of([ + [ id:'test', single_end:false ], // meta map + [ + file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/bam/test.paired_end.sorted.bam', checkIfExists: true), + file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/bam/test2.paired_end.sorted.bam', checkIfExists: true) + ] + ]) + input[1] = Channel.of([ + [ id:'fasta' ], // meta map + file(params.modules_testdata_base_path + 'genomics/homo_sapiens/genome/genome.fasta', checkIfExists: true) + ]) + """ + } + } + + then { + assertAll ( + { assert process.success }, + { assert snapshot(process.out).match() } + ) + } + } + test("cram - stub") { options "-stub" diff --git a/modules/nf-core/samtools/sort/tests/main.nf.test.snap b/modules/nf-core/samtools/sort/tests/main.nf.test.snap index 2d6b2900..469891fe 100644 --- a/modules/nf-core/samtools/sort/tests/main.nf.test.snap +++ b/modules/nf-core/samtools/sort/tests/main.nf.test.snap @@ -159,6 +159,101 @@ }, "timestamp": "2024-09-16T08:50:19.061912443" }, + "multiple bam": { + "content": [ + [ + [ + { + "id": "test", + "single_end": false + }, + "test.sorted.bam:md5,8a16ba90c7d294cbb4c33ac0f7127a12" + ] + ], + [ + [ + { + "id": "test", + "single_end": false + }, + "test.sorted.bam.csi" + ] + ], + [ + "versions.yml:md5,2659b187d681241451539d4c53500b9f" + ] + ], + "meta": { + "nf-test": "0.9.0", + "nextflow": "24.09.0" + }, + "timestamp": "2024-10-08T11:59:55.479443" + }, + "multiple bam - stub": { + "content": [ + { + "0": [ + [ + { + "id": "test", + "single_end": false + }, + "test.sorted.bam:md5,8a16ba90c7d294cbb4c33ac0f7127a12" + ] + ], + "1": [ + + ], + "2": [ + + ], + "3": [ + [ + { + "id": "test", + "single_end": false + }, + "test.sorted.bam.csi:md5,d185916eaff9afeb4d0aeab3310371f9" + ] + ], + "4": [ + "versions.yml:md5,2659b187d681241451539d4c53500b9f" + ], + "bam": [ + [ + { + "id": "test", + "single_end": false + }, + "test.sorted.bam:md5,8a16ba90c7d294cbb4c33ac0f7127a12" + ] + ], + "crai": [ + + ], + "cram": [ + + ], + "csi": [ + [ + { + "id": "test", + "single_end": false + }, + "test.sorted.bam.csi:md5,d185916eaff9afeb4d0aeab3310371f9" + ] + ], + "versions": [ + "versions.yml:md5,2659b187d681241451539d4c53500b9f" + ] + } + ], + "meta": { + "nf-test": "0.9.0", + "nextflow": "24.09.0" + }, + "timestamp": "2024-10-08T11:36:13.781404" + }, "bam": { "content": [ [ @@ -185,8 +280,8 @@ ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.4" + "nextflow": "24.09.0" }, - "timestamp": "2024-09-16T08:49:43.971158333" + "timestamp": "2024-10-08T11:59:46.372244" } } \ No newline at end of file diff --git a/modules/nf-core/samtools/view/environment.yml b/modules/nf-core/samtools/view/environment.yml index 62054fc9..02cda6e6 100644 --- a/modules/nf-core/samtools/view/environment.yml +++ b/modules/nf-core/samtools/view/environment.yml @@ -4,5 +4,7 @@ channels: - conda-forge - bioconda dependencies: + # renovate: datasource=conda depName=bioconda/htslib - bioconda::htslib=1.21 + # renovate: datasource=conda depName=bioconda/samtools - bioconda::samtools=1.21 diff --git a/modules/nf-core/samtools/view/main.nf b/modules/nf-core/samtools/view/main.nf index 37e05cec..a6941e63 100644 --- a/modules/nf-core/samtools/view/main.nf +++ b/modules/nf-core/samtools/view/main.nf @@ -4,8 +4,8 @@ process SAMTOOLS_VIEW { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/samtools:1.21--h50ea8bc_0' : - 'biocontainers/samtools:1.21--h50ea8bc_0' }" + 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/9e/9edc2564215d5cd137a8b25ca8a311600987186d406b092022444adf3c4447f7/data' : + 'community.wave.seqera.io/library/htslib_samtools:1.21--6cb89bfd40cbaabf' }" input: tuple val(meta), path(input), path(index) @@ -63,7 +63,7 @@ process SAMTOOLS_VIEW { input.getExtension() if ("$input" == "${prefix}.${file_type}") error "Input and output names are the same, use \"task.ext.prefix\" to disambiguate!" - def index = args.contains("--write-index") ? "touch ${prefix}.${file_type}.csi" : "" + index = args.contains("--write-index") ? "touch ${prefix}.${file_type}.csi" : "" """ touch ${prefix}.${file_type} diff --git a/modules/nf-core/star/align/environment.yml b/modules/nf-core/star/align/environment.yml index 1debc4c9..7c57530a 100644 --- a/modules/nf-core/star/align/environment.yml +++ b/modules/nf-core/star/align/environment.yml @@ -3,7 +3,7 @@ channels: - bioconda dependencies: - - bioconda::htslib=1.18 - - bioconda::samtools=1.18 - - bioconda::star=2.7.10a + - bioconda::htslib=1.20 + - bioconda::samtools=1.20 + - bioconda::star=2.7.11b - conda-forge::gawk=5.1.0 diff --git a/modules/nf-core/star/align/main.nf b/modules/nf-core/star/align/main.nf index b5bc9ddf..417071ba 100644 --- a/modules/nf-core/star/align/main.nf +++ b/modules/nf-core/star/align/main.nf @@ -4,8 +4,8 @@ process STAR_ALIGN { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:ded3841da0194af2701c780e9b3d653a85d27489-0' : - 'biocontainers/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:ded3841da0194af2701c780e9b3d653a85d27489-0' }" + 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/b4/b425bc2a95806d878993f9a66dae3ae80ac2dafff4c208c5ae01b7a90a32fa91/data' : + 'community.wave.seqera.io/library/star_samtools_htslib_gawk:10c6e8c834460019' }" input: tuple val(meta), path(reads, stageAs: "input*/*") diff --git a/modules/nf-core/star/align/meta.yml b/modules/nf-core/star/align/meta.yml index d9cba2aa..5cfe763e 100644 --- a/modules/nf-core/star/align/meta.yml +++ b/modules/nf-core/star/align/meta.yml @@ -56,27 +56,30 @@ input: output: - log_final: - meta: - type: file - description: STAR final log file - pattern: "*Log.final.out" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*Log.final.out": type: file description: STAR final log file pattern: "*Log.final.out" - log_out: - meta: - type: file - description: STAR lot out file - pattern: "*Log.out" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*Log.out": type: file description: STAR lot out file pattern: "*Log.out" - log_progress: - meta: - type: file - description: STAR log progress file - pattern: "*Log.progress.out" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*Log.progress.out": type: file description: STAR log progress file @@ -88,57 +91,70 @@ output: pattern: "versions.yml" - bam: - meta: - type: file - description: Output BAM file containing read alignments - pattern: "*.{bam}" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*d.out.bam": type: file description: Output BAM file containing read alignments pattern: "*.{bam}" - bam_sorted: - meta: - type: file - description: Sorted BAM file of read alignments (optional) - pattern: "*sortedByCoord.out.bam" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - ${prefix}.sortedByCoord.out.bam: type: file description: Sorted BAM file of read alignments (optional) pattern: "*sortedByCoord.out.bam" - bam_sorted_aligned: - - meta: {} - - ${prefix}.Aligned.sortedByCoord.out.bam: {} - - bam_transcript: - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - ${prefix}.Aligned.sortedByCoord.out.bam: type: file - description: Output BAM file of transcriptome alignment (optional) - pattern: "*toTranscriptome.out.bam" + description: Sorted BAM file of read alignments (optional) + pattern: "*.Aligned.sortedByCoord.out.bam" + - bam_transcript: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*toTranscriptome.out.bam": type: file description: Output BAM file of transcriptome alignment (optional) pattern: "*toTranscriptome.out.bam" - bam_unsorted: - meta: - type: file - description: Unsorted BAM file of read alignments (optional) - pattern: "*Aligned.unsort.out.bam" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*Aligned.unsort.out.bam": type: file description: Unsorted BAM file of read alignments (optional) pattern: "*Aligned.unsort.out.bam" - fastq: - meta: - type: file - description: Unmapped FastQ files (optional) - pattern: "*fastq.gz" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*fastq.gz": type: file description: Unmapped FastQ files (optional) pattern: "*fastq.gz" - tab: - meta: - type: file - description: STAR output tab file(s) (optional) - pattern: "*.tab" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*.tab": type: file description: STAR output tab file(s) (optional) @@ -149,12 +165,9 @@ output: description: | Groovy Map containing sample information e.g. [ id:'test', single_end:false ] - pattern: "*.SJ.out.tab" - "*.SJ.out.tab": - type: map - description: | - Groovy Map containing sample information - e.g. [ id:'test', single_end:false ] + type: file + description: STAR output splice junction tab file pattern: "*.SJ.out.tab" - read_per_gene_tab: - meta: @@ -162,18 +175,16 @@ output: description: | Groovy Map containing sample information e.g. [ id:'test', single_end:false ] - pattern: "*.ReadsPerGene.out.tab" - "*.ReadsPerGene.out.tab": + type: file + description: STAR output read per gene tab file + pattern: "*.ReadsPerGene.out.tab" + - junction: + - meta: type: map description: | Groovy Map containing sample information e.g. [ id:'test', single_end:false ] - pattern: "*.ReadsPerGene.out.tab" - - junction: - - meta: - type: file - description: STAR chimeric junction output file (optional) - pattern: "*.out.junction" - "*.out.junction": type: file description: STAR chimeric junction output file (optional) @@ -186,25 +197,25 @@ output: e.g. [ id:'test', single_end:false ] pattern: "*.out.sam" - "*.out.sam": + type: file + description: STAR output SAM file(s) (optional) + pattern: "*.out.sam" + - wig: + - meta: type: map description: | Groovy Map containing sample information e.g. [ id:'test', single_end:false ] - pattern: "*.out.sam" - - wig: - - meta: - type: file - description: STAR output wiggle format file(s) (optional) - pattern: "*.wig" - "*.wig": type: file description: STAR output wiggle format file(s) (optional) pattern: "*.wig" - bedgraph: - meta: - type: file - description: STAR output bedGraph format file(s) (optional) - pattern: "*.bg" + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] - "*.bg": type: file description: STAR output bedGraph format file(s) (optional) diff --git a/modules/nf-core/star/align/tests/main.nf.test b/modules/nf-core/star/align/tests/main.nf.test index 2d9f72dd..a62c17db 100644 --- a/modules/nf-core/star/align/tests/main.nf.test +++ b/modules/nf-core/star/align/tests/main.nf.test @@ -56,13 +56,10 @@ nextflow_process { file(process.out.log_final[0][1]).name, file(process.out.log_out[0][1]).name, file(process.out.log_progress[0][1]).name, - process.out.bam, - process.out.bam_sorted, - process.out.bam_transcript, - process.out.bam_unsorted, + bam(process.out.bam[0][1]).getReadsMD5(), + bam(process.out.bam_sorted_aligned[0][1]).getReadsMD5(), process.out.bedgraph, process.out.fastq, - process.out.junction, process.out.read_per_gene_tab, process.out.sam, process.out.spl_junc_tab, @@ -124,13 +121,10 @@ nextflow_process { file(process.out.log_final[0][1]).name, file(process.out.log_out[0][1]).name, file(process.out.log_progress[0][1]).name, - process.out.bam, - process.out.bam_sorted, - process.out.bam_transcript, - process.out.bam_unsorted, + bam(process.out.bam[0][1]).getReadsMD5(), + bam(process.out.bam_sorted_aligned[0][1]).getReadsMD5(), process.out.bedgraph, process.out.fastq, - process.out.junction, process.out.read_per_gene_tab, process.out.sam, process.out.spl_junc_tab, @@ -192,13 +186,9 @@ nextflow_process { file(process.out.log_final[0][1]).name, file(process.out.log_out[0][1]).name, file(process.out.log_progress[0][1]).name, - process.out.bam, - process.out.bam_sorted, - process.out.bam_transcript, - process.out.bam_unsorted, + bam(process.out.bam[0][1]).getReadsMD5(), process.out.bedgraph, process.out.fastq, - process.out.junction, process.out.read_per_gene_tab, process.out.sam, process.out.spl_junc_tab, @@ -260,13 +250,10 @@ nextflow_process { file(process.out.log_final[0][1]).name, file(process.out.log_out[0][1]).name, file(process.out.log_progress[0][1]).name, - process.out.bam, - process.out.bam_sorted, - process.out.bam_transcript, - process.out.bam_unsorted, + file(process.out.junction[0][1]).name, + bam(process.out.bam[0][1]).getReadsMD5(), process.out.bedgraph, process.out.fastq, - process.out.junction, process.out.read_per_gene_tab, process.out.sam, process.out.spl_junc_tab, @@ -330,13 +317,10 @@ nextflow_process { file(process.out.log_final[0][1]).name, file(process.out.log_out[0][1]).name, file(process.out.log_progress[0][1]).name, - process.out.bam, - process.out.bam_sorted, - process.out.bam_transcript, - process.out.bam_unsorted, + bam(process.out.bam[0][1]).getReadsMD5(), + bam(process.out.bam_sorted_aligned[0][1]).getReadsMD5(), process.out.bedgraph, process.out.fastq, - process.out.junction, process.out.read_per_gene_tab, process.out.sam, process.out.spl_junc_tab, @@ -606,4 +590,4 @@ nextflow_process { ) } } -} \ No newline at end of file +} diff --git a/modules/nf-core/star/align/tests/main.nf.test.snap b/modules/nf-core/star/align/tests/main.nf.test.snap index 0da28d37..b533fb8b 100644 --- a/modules/nf-core/star/align/tests/main.nf.test.snap +++ b/modules/nf-core/star/align/tests/main.nf.test.snap @@ -97,7 +97,7 @@ ] ], "3": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "4": [ [ @@ -307,7 +307,7 @@ ] ], "versions": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "wig": [ [ @@ -322,9 +322,9 @@ ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:39:15.440397" + "timestamp": "2024-10-20T17:09:08.738074176" }, "homo_sapiens - paired_end - arriba - stub": { "content": [ @@ -424,7 +424,7 @@ ] ], "3": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "4": [ [ @@ -634,7 +634,7 @@ ] ], "versions": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "wig": [ [ @@ -649,33 +649,17 @@ ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:40:15.472109" + "timestamp": "2024-10-20T17:09:36.122131869" }, "homo_sapiens - single_end": { "content": [ "test.Log.final.out", "test.Log.out", "test.Log.progress.out", - [ - [ - { - "id": "test", - "single_end": true - }, - "test.Aligned.sortedByCoord.out.bam:md5,c6cfaccaf91bc7fdabed3cfe236d4535" - ] - ], - [ - - ], - [ - - ], - [ - - ], + "9f76be49a6607613a64f760101bdddce", + "9f76be49a6607613a64f760101bdddce", [ [ { @@ -696,9 +680,6 @@ ], [ - ], - [ - ], [ [ @@ -722,38 +703,22 @@ ], [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:23:08.001162" + "timestamp": "2024-10-20T17:01:22.197991909" }, "homo_sapiens - paired_end": { "content": [ "test.Log.final.out", "test.Log.out", "test.Log.progress.out", - [ - [ - { - "id": "test", - "single_end": false - }, - "test.Aligned.sortedByCoord.out.bam:md5,b9ee1c607e07323bc1652ef3babb543f" - ] - ], - [ - - ], - [ - - ], - [ - - ], + "db9a8324b5163b025bcc0c33e848486", + "db9a8324b5163b025bcc0c33e848486", [ [ { @@ -774,9 +739,6 @@ ], [ - ], - [ - ], [ [ @@ -800,14 +762,14 @@ ], [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:24:46.295219" + "timestamp": "2024-10-20T17:02:06.988663857" }, "homo_sapiens - paired_end - multiple - stub": { "content": [ @@ -907,7 +869,7 @@ ] ], "3": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "4": [ [ @@ -1117,7 +1079,7 @@ ] ], "versions": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "wig": [ [ @@ -1132,33 +1094,17 @@ ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:41:07.310866" + "timestamp": "2024-10-20T17:10:12.005468781" }, "homo_sapiens - paired_end - multiple": { "content": [ "test.Log.final.out", "test.Log.out", "test.Log.progress.out", - [ - [ - { - "id": "test", - "single_end": false - }, - "test.Aligned.sortedByCoord.out.bam:md5,ab07c21d63ab0a6c07d171d213c81d5a" - ] - ], - [ - - ], - [ - - ], - [ - - ], + "3e54e45f5dc3e9c1f2fc55bc41531a87", + "3e54e45f5dc3e9c1f2fc55bc41531a87", [ [ { @@ -1179,9 +1125,6 @@ ], [ - ], - [ - ], [ [ @@ -1205,14 +1148,14 @@ ], [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:38:46.605044" + "timestamp": "2024-10-20T17:08:54.877286681" }, "homo_sapiens - paired_end - stub": { "content": [ @@ -1312,7 +1255,7 @@ ] ], "3": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "4": [ [ @@ -1522,7 +1465,7 @@ ] ], "versions": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "wig": [ [ @@ -1537,24 +1480,17 @@ ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:39:51.595873" + "timestamp": "2024-10-20T17:09:20.911466345" }, "homo_sapiens - paired_end - starfusion": { "content": [ "test.Log.final.out", "test.Log.out", "test.Log.progress.out", - [ - [ - { - "id": "test", - "single_end": false - }, - "test.Aligned.out.bam:md5,bcad07b838f6762fc01eea52b5cd3f84" - ] - ], + "test.Chimeric.out.junction", + "caee9dcda13882d4913456973c25b57a", [ ], @@ -1566,24 +1502,6 @@ ], [ - ], - [ - - ], - [ - [ - { - "id": "test", - "single_end": false - }, - "test.Chimeric.out.junction:md5,c10ef219f4a30e83711b995bc5e40dba" - ] - ], - [ - - ], - [ - ], [ [ @@ -1607,41 +1525,21 @@ ], [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:35:43.874508" + "timestamp": "2024-10-20T17:07:25.0639914" }, "homo_sapiens - paired_end - arriba": { "content": [ "test.Log.final.out", "test.Log.out", "test.Log.progress.out", - [ - [ - { - "id": "test", - "single_end": false - }, - "test.Aligned.out.bam:md5,c1b1747f5873f2d17762725636e891d5" - ] - ], - [ - - ], - [ - - ], - [ - - ], - [ - - ], + "1a3abe88fb2490589c58497d39921bcc", [ ], @@ -1676,14 +1574,14 @@ ], [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:28:32.599223" + "timestamp": "2024-10-20T17:04:00.685784211" }, "homo_sapiens - paired_end - starfusion - stub": { "content": [ @@ -1783,7 +1681,7 @@ ] ], "3": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "4": [ [ @@ -1993,7 +1891,7 @@ ] ], "versions": [ - "versions.yml:md5,2e6b6d8809f5a17f38f4d27c45dcb22f" + "versions.yml:md5,a149bba1dbb5194560abdd813c7848e3" ], "wig": [ [ @@ -2008,8 +1906,8 @@ ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-10-01T11:40:42.29249" + "timestamp": "2024-10-20T17:09:53.173671551" } } \ No newline at end of file diff --git a/modules/nf-core/star/genomegenerate/environment.yml b/modules/nf-core/star/genomegenerate/environment.yml index 1debc4c9..7c57530a 100644 --- a/modules/nf-core/star/genomegenerate/environment.yml +++ b/modules/nf-core/star/genomegenerate/environment.yml @@ -3,7 +3,7 @@ channels: - bioconda dependencies: - - bioconda::htslib=1.18 - - bioconda::samtools=1.18 - - bioconda::star=2.7.10a + - bioconda::htslib=1.20 + - bioconda::samtools=1.20 + - bioconda::star=2.7.11b - conda-forge::gawk=5.1.0 diff --git a/modules/nf-core/star/genomegenerate/main.nf b/modules/nf-core/star/genomegenerate/main.nf index b8855715..8f0c67e7 100644 --- a/modules/nf-core/star/genomegenerate/main.nf +++ b/modules/nf-core/star/genomegenerate/main.nf @@ -4,8 +4,8 @@ process STAR_GENOMEGENERATE { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:ded3841da0194af2701c780e9b3d653a85d27489-0' : - 'biocontainers/mulled-v2-1fa26d1ce03c295fe2fdcf85831a92fbcbd7e8c2:ded3841da0194af2701c780e9b3d653a85d27489-0' }" + 'https://community-cr-prod.seqera.io/docker/registry/v2/blobs/sha256/b4/b425bc2a95806d878993f9a66dae3ae80ac2dafff4c208c5ae01b7a90a32fa91/data' : + 'community.wave.seqera.io/library/star_samtools_htslib_gawk:10c6e8c834460019' }" input: tuple val(meta), path(fasta) diff --git a/modules/nf-core/star/genomegenerate/tests/main.nf.test.snap b/modules/nf-core/star/genomegenerate/tests/main.nf.test.snap index 207f4b4f..3db25678 100644 --- a/modules/nf-core/star/genomegenerate/tests/main.nf.test.snap +++ b/modules/nf-core/star/genomegenerate/tests/main.nf.test.snap @@ -3,14 +3,14 @@ "content": [ "[Genome, Log.out, SA, SAindex, chrLength.txt, chrName.txt, chrNameLength.txt, chrStart.txt, exonGeTrInfo.tab, exonInfo.tab, geneInfo.tab, genomeParameters.txt, sjdbInfo.txt, sjdbList.fromGTF.out.tab, sjdbList.out.tab, transcriptInfo.tab]", [ - "versions.yml:md5,46b8f1f34bb7f23892cd1eb249ed4d7f" + "versions.yml:md5,14b05d04c9eca568e9ed4888aaf26fa6" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T14:55:35.478401" + "timestamp": "2024-10-19T20:37:47.410432728" }, "fasta_gtf_stub": { "content": [ @@ -41,7 +41,7 @@ ] ], "1": [ - "versions.yml:md5,46b8f1f34bb7f23892cd1eb249ed4d7f" + "versions.yml:md5,14b05d04c9eca568e9ed4888aaf26fa6" ], "index": [ [ @@ -69,15 +69,15 @@ ] ], "versions": [ - "versions.yml:md5,46b8f1f34bb7f23892cd1eb249ed4d7f" + "versions.yml:md5,14b05d04c9eca568e9ed4888aaf26fa6" ] } ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T14:55:57.247585" + "timestamp": "2024-10-19T20:38:09.165234795" }, "fasta_stub": { "content": [ @@ -101,7 +101,7 @@ ] ], "1": [ - "versions.yml:md5,46b8f1f34bb7f23892cd1eb249ed4d7f" + "versions.yml:md5,14b05d04c9eca568e9ed4888aaf26fa6" ], "index": [ [ @@ -122,27 +122,27 @@ ] ], "versions": [ - "versions.yml:md5,46b8f1f34bb7f23892cd1eb249ed4d7f" + "versions.yml:md5,14b05d04c9eca568e9ed4888aaf26fa6" ] } ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T14:56:07.01742" + "timestamp": "2024-10-19T20:38:19.530862664" }, "fasta": { "content": [ "[Genome, Log.out, SA, SAindex, chrLength.txt, chrName.txt, chrNameLength.txt, chrStart.txt, genomeParameters.txt]", [ - "versions.yml:md5,46b8f1f34bb7f23892cd1eb249ed4d7f" + "versions.yml:md5,14b05d04c9eca568e9ed4888aaf26fa6" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T14:55:45.48784" + "timestamp": "2024-10-19T20:37:58.667436398" } } \ No newline at end of file diff --git a/modules/nf-core/stringtie/stringtie/environment.yml b/modules/nf-core/stringtie/stringtie/environment.yml index 0556de41..906b7486 100644 --- a/modules/nf-core/stringtie/stringtie/environment.yml +++ b/modules/nf-core/stringtie/stringtie/environment.yml @@ -2,4 +2,4 @@ channels: - conda-forge - bioconda dependencies: - - bioconda::stringtie=2.2.1 + - bioconda::stringtie=2.2.3 diff --git a/modules/nf-core/stringtie/stringtie/main.nf b/modules/nf-core/stringtie/stringtie/main.nf index 6e25ba27..4635c8c5 100644 --- a/modules/nf-core/stringtie/stringtie/main.nf +++ b/modules/nf-core/stringtie/stringtie/main.nf @@ -4,8 +4,8 @@ process STRINGTIE_STRINGTIE { conda "${moduleDir}/environment.yml" container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/stringtie:2.2.1--hecb563c_2' : - 'biocontainers/stringtie:2.2.1--hecb563c_2' }" + 'https://depot.galaxyproject.org/singularity/stringtie:2.2.3--h43eeafb_0' : + 'biocontainers/stringtie:2.2.3--h43eeafb_0' }" input: tuple val(meta), path(bam) diff --git a/modules/nf-core/stringtie/stringtie/tests/main.nf.test.snap b/modules/nf-core/stringtie/stringtie/tests/main.nf.test.snap index 124dd4cb..d4645de3 100644 --- a/modules/nf-core/stringtie/stringtie/tests/main.nf.test.snap +++ b/modules/nf-core/stringtie/stringtie/tests/main.nf.test.snap @@ -31,18 +31,18 @@ "id": "test", "strandedness": "forward" }, - "test.transcripts.gtf:md5,f56cf8aba2c4a5673bc7963ba5f12d04" + "test.transcripts.gtf:md5,37154e7bda96544f24506ee902bb561d" ] ], [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:33:44.299962" + "timestamp": "2024-10-18T09:56:50.294157199" }, "sarscov2 [bam] - forward strandedness": { "content": [ @@ -61,18 +61,18 @@ "id": "test", "strandedness": "forward" }, - "test.transcripts.gtf:md5,569137af5be452413086b50653a97203" + "test.transcripts.gtf:md5,6087dfc9700a52d9e4a1ae3fcd1d1dfd" ] ], [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:33:35.177738" + "timestamp": "2024-10-18T09:56:39.4249133" }, "sarscov2 [bam] - forward strandedness - stub": { "content": [ @@ -114,7 +114,7 @@ ] ], "4": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ], "abundance": [ [ @@ -153,15 +153,15 @@ ] ], "versions": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] } ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:36:32.885078" + "timestamp": "2024-10-18T09:57:23.008470065" }, "sarscov2 [bam] - forward strandedness + reference annotation - stub": { "content": [ @@ -203,7 +203,7 @@ ] ], "4": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ], "abundance": [ [ @@ -242,15 +242,15 @@ ] ], "versions": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] } ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:36:43.325777" + "timestamp": "2024-10-18T09:57:33.622824981" }, "sarscov2 [bam] - reverse strandedness + reference annotation - stub": { "content": [ @@ -292,7 +292,7 @@ ] ], "4": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ], "abundance": [ [ @@ -331,15 +331,15 @@ ] ], "versions": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] } ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:37:06.085936" + "timestamp": "2024-10-18T09:57:55.803421433" }, "sarscov2 [bam] - reverse strandedness - stub": { "content": [ @@ -381,7 +381,7 @@ ] ], "4": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ], "abundance": [ [ @@ -420,15 +420,15 @@ ] ], "versions": [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] } ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:36:53.837578" + "timestamp": "2024-10-18T09:57:44.825389635" }, "sarscov2 [bam] - reverse strandedness + reference annotation": { "content": [ @@ -462,18 +462,18 @@ "id": "test", "strandedness": "reverse" }, - "test.transcripts.gtf:md5,bb346053a8c156b803b055133376c7fa" + "test.transcripts.gtf:md5,fbabb4e3888bbede67f11f692e484880" ] ], [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:34:03.114695" + "timestamp": "2024-10-18T09:57:11.793664242" }, "sarscov2 [bam] - reverse strandedness": { "content": [ @@ -492,17 +492,17 @@ "id": "test", "strandedness": "reverse" }, - "test.transcripts.gtf:md5,31c34aec2bf36bb0ea3c16c2afeeeb1f" + "test.transcripts.gtf:md5,01d6da00a3c458420841e57427297183" ] ], [ - "versions.yml:md5,3410e8ac349d18c85ddee89337851d38" + "versions.yml:md5,06593ea00cc35bf06f2de2753e0c3913" ] ], "meta": { "nf-test": "0.9.0", - "nextflow": "24.04.3" + "nextflow": "24.04.4" }, - "timestamp": "2024-07-22T12:33:52.874479" + "timestamp": "2024-10-18T09:57:01.166309777" } } \ No newline at end of file diff --git a/nextflow.config b/nextflow.config index c4011d87..e9f2f6c4 100644 --- a/nextflow.config +++ b/nextflow.config @@ -11,7 +11,7 @@ params { // Input options input = 'https://raw.githubusercontent.com/nf-core/test-datasets/rnafusion/testdata/human/samplesheet_valid.csv' - build_references = false + references_only = false cosmic_username = null cosmic_passwd = null qiagen = false @@ -26,20 +26,12 @@ params { // Genome genome = 'GRCh38' genomes_base = "${params.outdir}/references" - ensembl_version = 102 + genome_gencode_version = 46 read_length = 100 starfusion_build = true genomes = [:] fusion_annot_lib = "https://github.com/FusionAnnotator/CTAT_HumanFusionLib/releases/download/v0.3.0/fusion_lib.Mar2021.dat.gz" // path to dat.gz CTAT genome lib // TODO: Update to latest with s3 link when available - - // Genomes options - fasta = "${params.genomes_base}/ensembl/Homo_sapiens.${params.genome}.${params.ensembl_version}.all.fa" - fai = "${params.genomes_base}/ensembl/Homo_sapiens.${params.genome}.${params.ensembl_version}.all.fa.fai" - gtf = "${params.genomes_base}/ensembl/Homo_sapiens.${params.genome}.${params.ensembl_version}.gtf" - chrgtf = "${params.genomes_base}/ensembl/Homo_sapiens.${params.genome}.${params.ensembl_version}.chr.gtf" - transcript = "${params.genomes_base}/ensembl/Homo_sapiens.${params.genome}.${params.ensembl_version}.cdna.all.fa.gz" - refflat = "${params.genomes_base}/ensembl/Homo_sapiens.${params.genome}.${params.ensembl_version}.chr.gtf.refflat" - rrna_intervals = "${params.genomes_base}/ensembl/Homo_sapiens.${params.genome}.${params.ensembl_version}.interval_list" + species = "human" // Filtering tools_cutoff = 1 @@ -76,15 +68,22 @@ params { skip_vcf = false skip_salmon_index = false + // Download references option + download_refs = false + // Path to references + fasta = "${params.genomes_base}/gencode/Homo_sapiens_${params.genome}_${params.genome_gencode_version}_dna_primary_assembly.fa" + fai = "${params.genomes_base}/gencode/Homo_sapiens_${params.genome}_${params.genome_gencode_version}_dna_primary_assembly.fa.fai" + gtf = "${params.genomes_base}/gencode/Homo_sapiens_${params.genome}_${params.genome_gencode_version}.gtf" + refflat = "${params.genomes_base}/gencode/Homo_sapiens_${params.genome}_${params.genome_gencode_version}.gtf.refflat" + rrna_intervals = "${params.genomes_base}/gencode/Homo_sapiens_${params.genome}_${params.genome_gencode_version}.interval_list" + gencode_ref = "${params.genomes_base}/gencode" no_cosmic = false - ensembl_ref = "${params.genomes_base}/ensembl" - arriba_ref = "${params.genomes_base}/arriba" arriba_ref_blacklist = "${params.genomes_base}/arriba/blacklist_hg38_GRCh38_v2.4.0.tsv.gz" arriba_ref_cytobands = "${params.genomes_base}/arriba/cytobands_hg38_GRCh38_v2.4.0.tsv" arriba_ref_known_fusions = "${params.genomes_base}/arriba/known_fusions_hg38_GRCh38_v2.4.0.tsv.gz" arriba_ref_protein_domains = "${params.genomes_base}/arriba/protein_domains_hg38_GRCh38_v2.4.0.gff3" - fusioncatcher_ref = "${params.genomes_base}/fusioncatcher/human_v102" + fusioncatcher_ref = "${params.genomes_base}/fusioncatcher/human_v${params.genome_gencode_version}" hgnc_ref = "${params.genomes_base}/hgnc/hgnc_complete_set.txt" hgnc_date = "${params.genomes_base}/hgnc/HGNC-DB-timestamp.txt" salmon_index = "${params.genomes_base}/salmon/salmon" @@ -93,6 +92,13 @@ params { fusionreport_ref = "${params.genomes_base}/fusion_report_db" + // Internal file presence checks + salmon_index_stub_check = "${params.genomes_base}/salmon/salmon/complete_ref_lens.bin" + starindex_ref_stub_check = "${params.genomes_base}/star/star/Genome" + fusionreport_ref_stub_check = "${params.genomes_base}/fusion_report_db/mitelman.db" + fusioncatcher_ref_stub_check = "${params.genomes_base}/fusioncatcher/human_v${params.genome_gencode_version}/ensembl_fully_overlapping_genes.txt" + starfusion_ref_stub_check = "${params.genomes_base}/starfusion/Pfam-A.hmm" + // Path to fusion outputs arriba_fusions = null starfusion_fusions = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 03b2e149..3b54697c 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -15,13 +15,13 @@ "type": "boolean", "description": "Skip QC steps" }, - "skip_vis": { + "skip_vcf": { "type": "boolean", - "description": "Skip visualisation steps" + "description": "Skip vcf creation step" }, - "skip_vcf": { + "skip_vis": { "type": "boolean", - "description": "Skip vcf generation step" + "description": "Skip visualisation steps" }, "skip_salmon_index": { "type": "boolean", @@ -66,11 +66,6 @@ "description": "MultiQC report title. Printed as page header, used for filename if not otherwise specified.", "fa_icon": "fas fa-file-signature" }, - "build_references": { - "type": "boolean", - "fa_icon": "far fa-file-code", - "description": "Specifies which analysis type for the pipeline - either build references or analyse data" - }, "cosmic_username": { "type": "string", "fa_icon": "far fa-file-code", @@ -86,11 +81,10 @@ "fa_icon": "far fa-file-code", "description": "Path to reference folder" }, - "ensembl_version": { + "genome_gencode_version": { "type": "integer", "fa_icon": "far fa-file-code", - "description": "ensembl version", - "default": 102 + "description": "gencode version" }, "starfusion_build": { "type": "boolean", @@ -113,11 +107,6 @@ "fa_icon": "far fa-file-code", "description": "Build or run arriba references/analyses" }, - "arriba_ref": { - "type": "string", - "fa_icon": "far fa-file-code", - "description": "Path to arriba references" - }, "arriba_ref_blacklist": { "type": "string", "fa_icon": "far fa-file-code", @@ -143,15 +132,20 @@ "fa_icon": "far fa-file-code", "description": "Path to arriba output" }, + "download_refs": { + "type": "boolean", + "fa_icon": "far fa-file-code", + "description": "Download references instead of building them (for fusioncatcher and starfusion)" + }, "ctatsplicing": { "type": "boolean", "fa_icon": "far fa-file-code", "description": "Run CTAT-splicing to detect abberant cancer splicing introns. Needs --arriba and/or --starfusion to run." }, - "ensembl_ref": { + "gencode_ref": { "type": "string", "fa_icon": "far fa-file-code", - "description": "Path to ensembl references" + "description": "Path to gencode references" }, "fusioncatcher": { "type": "boolean", @@ -173,6 +167,11 @@ "fa_icon": "far fa-file-code", "description": "Path to fusioncatcher references" }, + "fusioncatcher_ref_stub_check": { + "type": "string", + "fa_icon": "far fa-file-code", + "description": "Path to file in fusioncatcher references" + }, "fusioninspector_limitSjdbInsertNsj": { "type": "integer", "fa_icon": "far fa-file-code", @@ -198,6 +197,11 @@ "fa_icon": "far fa-file-code", "description": "Path to fusionreport references" }, + "fusionreport_ref_stub_check": { + "type": "string", + "fa_icon": "far fa-file-code", + "description": "Path to file in fusionreport references" + }, "hgnc_ref": { "type": "string", "fa_icon": "far fa-file-code", @@ -218,6 +222,11 @@ "fa_icon": "far fa-file-code", "description": "Path to salmon index" }, + "salmon_index_stub_check": { + "type": "string", + "fa_icon": "far fa-file-code", + "description": "Path to file in salmon index" + }, "starfusion": { "type": "boolean", "fa_icon": "far fa-file-code", @@ -233,6 +242,11 @@ "fa_icon": "far fa-file-code", "description": "Path to starfusion references" }, + "starfusion_ref_stub_check": { + "type": "string", + "fa_icon": "far fa-file-code", + "description": "Path to file in starfusion references" + }, "starindex": { "type": "boolean", "fa_icon": "far fa-file-code", @@ -243,6 +257,11 @@ "fa_icon": "far fa-file-code", "description": "Path to starindex references" }, + "starindex_ref_stub_check": { + "type": "string", + "fa_icon": "far fa-file-code", + "description": "Path to file in starindex references" + }, "stringtie": { "type": "boolean", "fa_icon": "far fa-file-code", @@ -302,9 +321,9 @@ "fa_icon": "fas fa-dna", "description": "Reference genome related files and options required for the workflow.", "properties": { - "genome": { - "type": "string", - "description": "Name of iGenomes reference.", + "references_only": { + "type": "boolean", + "description": "Skip running the analysis, only builds the references", "fa_icon": "fas fa-book" }, "fasta": { @@ -323,15 +342,12 @@ "description": "Path to FASTA genome index file.", "fa_icon": "far fa-file-code" }, - "gtf": { + "genome": { "type": "string", - "format": "file-path", - "mimetype": "text/plain", - "pattern": "^\\S+\\.gtf?(\\.gz)?$", - "description": "Path to GTF genome file.", - "fa_icon": "far fa-file-code" + "description": "Name of iGenomes reference.", + "fa_icon": "fas fa-book" }, - "chrgtf": { + "gtf": { "type": "string", "format": "file-path", "mimetype": "text/plain", @@ -339,14 +355,6 @@ "description": "Path to GTF genome file.", "fa_icon": "far fa-file-code" }, - "transcript": { - "type": "string", - "format": "file-path", - "mimetype": "text/plain", - "pattern": "^\\S+\\.fn?a(sta)?(\\.gz)?$", - "description": "Path to GTF genome file.", - "fa_icon": "far fa-file-code" - }, "refflat": { "type": "string", "format": "file-path", @@ -372,6 +380,11 @@ "type": "string", "description": "Path to Fusion Annotation Library to be used in STARFUSION_BUILD.", "fa_icon": "far fa-file-code" + }, + "species": { + "type": "string", + "description": "Which species dfam should automatically download, default: human.", + "fa_icon": "far fa-file-code" } } }, diff --git a/subworkflows/local/arriba_workflow/main.nf b/subworkflows/local/arriba_workflow/main.nf index c7089e85..84ba3604 100644 --- a/subworkflows/local/arriba_workflow/main.nf +++ b/subworkflows/local/arriba_workflow/main.nf @@ -8,14 +8,14 @@ include { CTATSPLICING_WORKFLOW } from '../ctatsplicing_workflow' workflow ARRIBA_WORKFLOW { take: - reads // channel [ meta, [ fastqs ] ] - ch_gtf // channel [ meta, path_gtf ] - ch_fasta // channel [ meta, path_fasta ] - ch_starindex_ref // channel [ meta, path_index ] - ch_arriba_ref_blacklist // channel [ meta, path_blacklist ] - ch_arriba_ref_known_fusions // channel [ meta, path_known_fusions ] - ch_arriba_ref_cytobands // channel [ meta, path_cytobands ] - ch_arriba_ref_protein_domains // channel [ meta, path_proteins ] + reads // channel [ meta, [ fastqs ] ] + ch_gtf // channel [ meta, path_gtf ] + ch_fasta // channel [ meta, path_fasta ] + ch_starindex_ref // channel [ meta, path_index ] + ch_arriba_ref_blacklist // channel [ meta, path_blacklist ] + ch_arriba_ref_cytobands // channel [ meta, path_cytobands ] + ch_arriba_ref_known_fusions // channel [ meta, path_known_fusions ] + ch_arriba_ref_protein_domains // channel [ meta, path_proteins ] ch_starfusion_ref // channel [ meta, path_starfusion_ref ] arriba // boolean all // boolean @@ -27,6 +27,7 @@ workflow ARRIBA_WORKFLOW { cram // array main: + def ch_versions = Channel.empty() def ch_cram_index = Channel.empty() def ch_dummy_file = file("$projectDir/assets/dummy_file_arriba.txt", checkIfExists: true) @@ -56,7 +57,7 @@ workflow ARRIBA_WORKFLOW { if ( arriba_fusions ) { ch_arriba_fusions = reads.combine( Channel.value( file( arriba_fusions, checkIfExists: true ) ) ) - .map { meta, reads, fusions -> [ meta, fusions ] } + .map { it -> [ it[0], it[2] ] } ch_arriba_fusion_fail = ch_dummy_file } else { @@ -65,16 +66,16 @@ workflow ARRIBA_WORKFLOW { STAR_FOR_ARRIBA.out.bam, ch_fasta, ch_gtf, - ch_arriba_ref_blacklist.map{ it[1] }, - ch_arriba_ref_known_fusions.map{ it[1] }, - ch_arriba_ref_cytobands.map{ it[1] }, - ch_arriba_ref_protein_domains.map{ it[1] } + ch_arriba_ref_blacklist, + ch_arriba_ref_known_fusions, + ch_arriba_ref_cytobands, + ch_arriba_ref_protein_domains ) ch_versions = ch_versions.mix(ARRIBA_ARRIBA.out.versions) ch_arriba_fusions = ARRIBA_ARRIBA.out.fusions - ch_arriba_fusion_fail = ARRIBA_ARRIBA.out.fusions_fail.map{ meta, file -> return file } + ch_arriba_fusion_fail = ARRIBA_ARRIBA.out.fusions_fail.map{ it -> return it[1] } } if ( cram.contains('arriba') ) { @@ -96,7 +97,7 @@ workflow ARRIBA_WORKFLOW { ch_arriba_fusions = reads .combine(Channel.value( file(ch_dummy_file, checkIfExists: true ) ) ) - .map { meta, reads, fusions -> [ meta, fusions ] } + .map { it -> [ it[0], it[2] ] } ch_arriba_fusion_fail = ch_dummy_file } diff --git a/subworkflows/local/build_references.nf b/subworkflows/local/build_references.nf new file mode 100644 index 00000000..56fd8eb2 --- /dev/null +++ b/subworkflows/local/build_references.nf @@ -0,0 +1,187 @@ +/* +======================================================================================== + IMPORT LOCAL MODULES/SUBWORKFLOWS +======================================================================================== +*/ + +include { GENCODE_DOWNLOAD } from '../../modules/local/gencode_download/main' +include { FUSIONCATCHER_BUILD } from '../../modules/local/fusioncatcher/build/main' +include { FUSIONREPORT_DOWNLOAD } from '../../modules/local/fusionreport/download/main' +include { HGNC_DOWNLOAD } from '../../modules/local/hgnc/main' +include { STARFUSION_BUILD } from '../../modules/local/starfusion/build/main' +include { GTF_TO_REFFLAT } from '../../modules/local/uscs/custom_gtftogenepred/main' +include { GET_RRNA_TRANSCRIPTS } from '../../modules/local/get_rrna_transcript/main' + +/* +======================================================================================== + IMPORT NF-CORE MODULES/SUBWORKFLOWS +======================================================================================== +*/ +include { ARRIBA_DOWNLOAD } from '../../modules/nf-core/arriba/download/main' +include { SAMTOOLS_FAIDX } from '../../modules/nf-core/samtools/faidx/main' +include { STAR_GENOMEGENERATE } from '../../modules/nf-core/star/genomegenerate/main' +include { GATK4_CREATESEQUENCEDICTIONARY } from '../../modules/nf-core/gatk4/createsequencedictionary/main' +include { GATK4_BEDTOINTERVALLIST } from '../../modules/nf-core/gatk4/bedtointervallist/main' +include { SALMON_INDEX } from '../../modules/nf-core/salmon/index/main' +include { GFFREAD } from '../../modules/nf-core/gffread/main' + +/* +======================================================================================== + RUN MAIN WORKFLOW +======================================================================================== +*/ + +workflow BUILD_REFERENCES { + + main: + ch_versions = Channel.empty() + + if (!file(params.fasta).exists() || file(params.fasta).isEmpty() || + !file(params.gtf).exists() || file(params.gtf).isEmpty()){ + GENCODE_DOWNLOAD(params.genome_gencode_version, params.genome) + ch_versions = ch_versions.mix(GENCODE_DOWNLOAD.out.versions) + ch_fasta = GENCODE_DOWNLOAD.out.fasta.map { that -> [[id:that.Name], that] } + ch_gtf = GENCODE_DOWNLOAD.out.gtf.map { that -> [[id:that.Name], that] } + } else { + ch_fasta = Channel.fromPath(params.fasta).map { that -> [[id:that.Name], that] } + ch_gtf = Channel.fromPath(params.gtf).map { that -> [[id:that.Name], that] } + } + + if (!file(params.fai).exists() || file(params.fai).isEmpty()){ + SAMTOOLS_FAIDX(ch_fasta, [[],[]]) + ch_versions = ch_versions.mix(SAMTOOLS_FAIDX.out.versions) + ch_fai = SAMTOOLS_FAIDX.out.fai + } else { + ch_fai = Channel.fromPath(params.fai).map { that -> [[id:that.Name], that] } + } + + if ((!file(params.hgnc_ref).exists() || file(params.hgnc_ref).isEmpty() || + !file(params.hgnc_date).exists() || file(params.hgnc_date).isEmpty()) && !params.skip_vcf){ + HGNC_DOWNLOAD( ) + ch_versions = ch_versions.mix(HGNC_DOWNLOAD.out.versions) + ch_hgnc_ref = HGNC_DOWNLOAD.out.hgnc_ref + ch_hgnc_date = HGNC_DOWNLOAD.out.hgnc_date + } else { + ch_hgnc_ref = Channel.fromPath(params.hgnc_ref).map { that -> [[id:that.Name], that] } + ch_hgnc_date = Channel.fromPath(params.hgnc_date).map { that -> [[id:that.Name], that] } + } + + if (!file(params.rrna_intervals).exists() || file(params.rrna_intervals).isEmpty()){ + GATK4_CREATESEQUENCEDICTIONARY(ch_fasta) + ch_versions = ch_versions.mix(GATK4_CREATESEQUENCEDICTIONARY.out.versions) + GET_RRNA_TRANSCRIPTS(ch_gtf) + ch_versions = ch_versions.mix(GET_RRNA_TRANSCRIPTS.out.versions) + GATK4_BEDTOINTERVALLIST(GET_RRNA_TRANSCRIPTS.out.bed, GATK4_CREATESEQUENCEDICTIONARY.out.dict ) + ch_versions = ch_versions.mix(GATK4_BEDTOINTERVALLIST.out.versions) + ch_rrna_interval = GATK4_BEDTOINTERVALLIST.out.interval_list + } else { + ch_rrna_interval = Channel.fromPath(params.rrna_intervals).map { that -> [[id:that.Name], that] } + } + + if (!file(params.refflat).exists() || file(params.refflat).isEmpty()){ + GTF_TO_REFFLAT(ch_gtf) + ch_versions = ch_versions.mix(GTF_TO_REFFLAT.out.versions) + ch_refflat = GTF_TO_REFFLAT.out.refflat.map { that -> [[id:that.Name], that] } + } else { + ch_refflat = Channel.fromPath(params.refflat).map { that -> [[id:that.Name], that] } + } + + if (!file(params.salmon_index).exists() || file(params.salmon_index).isEmpty() || + !file(params.salmon_index_stub_check).exists() || file(params.salmon_index_stub_check).isEmpty()){ // add condition for qc + GFFREAD(ch_gtf, ch_fasta.map{ it -> it[1] }) + ch_versions = ch_versions.mix(GFFREAD.out.versions) + SALMON_INDEX(ch_fasta.map{ it -> it[1] }, GFFREAD.out.gffread_fasta.map{ it -> it[1] }) + ch_versions = ch_versions.mix(SALMON_INDEX.out.versions) + ch_salmon_index = SALMON_INDEX.out.index + } else { + ch_salmon_index = Channel.fromPath({params.salmon_index}) + } + + if ((params.starindex || params.all || params.starfusion || params.arriba) && + (!file(params.starindex_ref).exists() || file(params.starindex_ref).isEmpty() || + !file(params.starindex_ref_stub_check).exists() || file(params.starindex_ref_stub_check).isEmpty() )) { + STAR_GENOMEGENERATE(ch_fasta, ch_gtf) + ch_versions = ch_versions.mix(STAR_GENOMEGENERATE.out.versions) + ch_starindex_ref = STAR_GENOMEGENERATE.out.index + } else { + ch_starindex_ref = Channel.fromPath(params.starindex_ref).map { that -> [[id:that.Name], that] } + } + + if ((params.arriba || params.all) && + (!file(params.arriba_ref_blacklist).exists() || file(params.arriba_ref_blacklist).isEmpty() || + !file(params.arriba_ref_known_fusions).exists() || file(params.arriba_ref_known_fusions).isEmpty() || + !file(params.arriba_ref_protein_domains).exists() || file(params.arriba_ref_protein_domains).isEmpty())) { + ARRIBA_DOWNLOAD(params.genome) + ch_versions = ch_versions.mix(ARRIBA_DOWNLOAD.out.versions) + ch_arriba_ref_blacklist = ARRIBA_DOWNLOAD.out.blacklist + ch_arriba_ref_cytobands = ARRIBA_DOWNLOAD.out.cytobands + ch_arriba_ref_known_fusions = ARRIBA_DOWNLOAD.out.known_fusions + ch_arriba_ref_protein_domains = ARRIBA_DOWNLOAD.out.protein_domains + } else { + ch_arriba_ref_blacklist = Channel.fromPath(params.arriba_ref_blacklist) + ch_arriba_ref_cytobands = Channel.fromPath(params.arriba_ref_cytobands) + ch_arriba_ref_known_fusions = Channel.fromPath(params.arriba_ref_known_fusions) + ch_arriba_ref_protein_domains = Channel.fromPath(params.arriba_ref_protein_domains) + } + + + if ((params.fusioncatcher || params.all) && + (!file(params.fusioncatcher_ref).exists() || file(params.fusioncatcher_ref).isEmpty() || + !file(params.fusioncatcher_ref_stub_check).exists() || file(params.fusioncatcher_ref_stub_check).isEmpty() )) { + FUSIONCATCHER_BUILD(params.genome_gencode_version) + ch_versions = ch_versions.mix(FUSIONCATCHER_BUILD.out.versions) + ch_fusioncatcher_ref = FUSIONCATCHER_BUILD.out.reference + } + else { + ch_fusioncatcher_ref = Channel.fromPath(params.fusioncatcher_ref) + } + + + if ((params.starfusion || params.all) && + (!file(params.starfusion_ref).exists() || file(params.starfusion_ref).isEmpty() || + !file(params.starfusion_ref_stub_check).exists() || file(params.starfusion_ref_stub_check).isEmpty() )) { + STARFUSION_BUILD(ch_fasta, ch_gtf, params.fusion_annot_lib, params.species) + ch_versions = ch_versions.mix(STARFUSION_BUILD.out.versions) + ch_starfusion_ref = STARFUSION_BUILD.out.reference + } + else { + ch_starfusion_ref = Channel.fromPath(params.starfusion_ref) + } + + + if ((params.fusionreport || params.all) && + (!file(params.fusionreport_ref).exists() || file(params.fusionreport_ref).isEmpty() || + !file(params.fusionreport_ref_stub_check).exists() || file(params.fusionreport_ref_stub_check).isEmpty())) { + if (!params.no_cosmic && (!params.cosmic_username || !params.cosmic_passwd)) { exit 1, 'COSMIC username and/or password missing' } + FUSIONREPORT_DOWNLOAD() + ch_versions = ch_versions.mix(FUSIONREPORT_DOWNLOAD.out.versions) + ch_fusionreport_ref = FUSIONREPORT_DOWNLOAD.out.fusionreport_ref + } else { + ch_fusionreport_ref = Channel.fromPath(params.fusionreport_ref).map { that -> [[id:that.Name], that] } + } + + emit: + ch_fasta + ch_gtf + ch_fai + ch_hgnc_ref + ch_hgnc_date + ch_rrna_interval + ch_refflat + ch_salmon_index + ch_starindex_ref + ch_arriba_ref_blacklist + ch_arriba_ref_cytobands + ch_arriba_ref_known_fusions + ch_arriba_ref_protein_domains + ch_fusioncatcher_ref + ch_starfusion_ref + ch_fusionreport_ref + versions = ch_versions +} + +/* +======================================================================================== + THE END +======================================================================================== +*/ diff --git a/subworkflows/local/fusioncatcher_workflow.nf b/subworkflows/local/fusioncatcher_workflow.nf index ebb09e60..97ed55de 100644 --- a/subworkflows/local/fusioncatcher_workflow.nf +++ b/subworkflows/local/fusioncatcher_workflow.nf @@ -12,7 +12,7 @@ workflow FUSIONCATCHER_WORKFLOW { if ((params.fusioncatcher || params.all) && !params.fusioninspector_only) { if (params.fusioncatcher_fusions){ ch_fusioncatcher_fusions = reads.combine(Channel.value(file(params.fusioncatcher_fusions, checkIfExists:true))) - .map { meta, reads, fusions -> [ meta, fusions ] } + .map { it -> [ it[0], it[1] ] } } else { FUSIONCATCHER ( reads, @@ -24,7 +24,7 @@ workflow FUSIONCATCHER_WORKFLOW { } else { ch_fusioncatcher_fusions = reads.combine(Channel.value(file(ch_dummy_file, checkIfExists:true))) - .map { meta, reads, fusions -> [ meta, fusions ] } + .map { it -> [ it[0], it[1] ] } } emit: diff --git a/subworkflows/local/fusionreport_workflow.nf b/subworkflows/local/fusionreport_workflow.nf index 6a87244f..04019e12 100644 --- a/subworkflows/local/fusionreport_workflow.nf +++ b/subworkflows/local/fusionreport_workflow.nf @@ -28,7 +28,7 @@ workflow FUSIONREPORT_WORKFLOW { ch_csv = FUSIONREPORT.out.csv } else { ch_fusion_list = reads.combine(Channel.value(file(params.fusioninspector_fusions, checkIfExists:true))) - .map { meta, reads, fusions -> [ meta, fusions ] } + .map { it -> [ it[0], it[1] ] } ch_fusion_list_filtered = ch_fusion_list } diff --git a/subworkflows/local/qc_workflow/main.nf b/subworkflows/local/qc_workflow/main.nf index a0ad60b6..4b635242 100644 --- a/subworkflows/local/qc_workflow/main.nf +++ b/subworkflows/local/qc_workflow/main.nf @@ -9,7 +9,6 @@ include { PICARD_COLLECTINSERTSIZEMETRICS } from '../../../modules/nf-core/pic workflow QC_WORKFLOW { take: ch_bam_sorted // channel [ meta, bam ] - ch_chrgtf // channel [ meta, gtf ] ch_refflat // channel [ meta, refflat ] ch_fasta // channel [ meta, fasta ] ch_fai // channel [ meta, fai ] diff --git a/subworkflows/local/starfusion_workflow.nf b/subworkflows/local/starfusion_workflow.nf index 82ae6f76..7f12f08a 100644 --- a/subworkflows/local/starfusion_workflow.nf +++ b/subworkflows/local/starfusion_workflow.nf @@ -9,7 +9,7 @@ include { CTATSPLICING_WORKFLOW } from './ctatsplicing_workflow' workflow STARFUSION_WORKFLOW { take: reads - ch_chrgtf + ch_gtf ch_starindex_ref ch_fasta ch_starfusion_ref @@ -25,9 +25,9 @@ workflow STARFUSION_WORKFLOW { if ((params.starfusion || params.all || params.stringtie) && !params.fusioninspector_only) { if (params.starfusion_fusions){ ch_starfusion_fusions = reads.combine(Channel.value(file(params.starfusion_fusions, checkIfExists:true))) - .map { meta, reads, fusions -> [ meta, fusions ] } + .map { it -> [ it[0], it[2] ] } } else { - STAR_FOR_STARFUSION( reads, ch_starindex_ref, ch_chrgtf, params.star_ignore_sjdbgtf, '', params.seq_center ?: '') + STAR_FOR_STARFUSION( reads, ch_starindex_ref, ch_gtf, params.star_ignore_sjdbgtf, '', params.seq_center ?: '') ch_versions = ch_versions.mix(STAR_FOR_STARFUSION.out.versions) ch_align = STAR_FOR_STARFUSION.out.bam_sorted @@ -65,7 +65,7 @@ workflow STARFUSION_WORKFLOW { } else { ch_starfusion_fusions = reads.combine(Channel.value(file(ch_dummy_file, checkIfExists:true))) - .map { meta, reads, fusions -> [ meta, fusions ] } + .map { it -> [ it[0], it[2] ] } ch_star_stats = Channel.empty() ch_star_gene_count = Channel.empty() } diff --git a/subworkflows/local/stringtie_workflow.nf b/subworkflows/local/stringtie_workflow.nf index 60bd4f38..d66ec0ee 100644 --- a/subworkflows/local/stringtie_workflow.nf +++ b/subworkflows/local/stringtie_workflow.nf @@ -5,14 +5,14 @@ include { STRINGTIE_MERGE } from '../../modules/nf-core/stringtie/merge/m workflow STRINGTIE_WORKFLOW { take: bam_sorted - ch_chrgtf + ch_gtf main: ch_versions = Channel.empty() ch_stringtie_gtf = Channel.empty() if ((params.stringtie || params.all) && !params.fusioninspector_only) { - STRINGTIE_STRINGTIE(bam_sorted, ch_chrgtf.map { meta, gtf -> [ gtf ]}) + STRINGTIE_STRINGTIE(bam_sorted, ch_gtf.map { meta, gtf -> [ gtf ]}) ch_versions = ch_versions.mix(STRINGTIE_STRINGTIE.out.versions) STRINGTIE_STRINGTIE @@ -23,7 +23,7 @@ workflow STRINGTIE_WORKFLOW { ch_versions = ch_versions.mix(STRINGTIE_STRINGTIE.out.versions) - STRINGTIE_MERGE (stringtie_gtf, ch_chrgtf.map { meta, gtf -> [ gtf ]}) + STRINGTIE_MERGE (stringtie_gtf, ch_gtf.map { meta, gtf -> [ gtf ]}) ch_versions = ch_versions.mix(STRINGTIE_MERGE.out.versions) ch_stringtie_gtf = STRINGTIE_MERGE.out.gtf } diff --git a/subworkflows/local/trim_workflow/main.nf b/subworkflows/local/trim_workflow/main.nf index 2cbb8380..d548c8ae 100644 --- a/subworkflows/local/trim_workflow/main.nf +++ b/subworkflows/local/trim_workflow/main.nf @@ -6,7 +6,7 @@ include { FASTQC as FASTQC_FOR_FASTP } from '../../../modules/nf-core/fastqc/mai workflow TRIM_WORKFLOW { take: - reads // channel [ meta, [ fastqs ] ] + reads // channel [ meta, [ fastq files ] ] adapter_fasta // channel [ path ] fastp_trim // boolean diff --git a/subworkflows/local/utils_nfcore_rnafusion_pipeline/main.nf b/subworkflows/local/utils_nfcore_rnafusion_pipeline/main.nf index ad97686a..96279699 100644 --- a/subworkflows/local/utils_nfcore_rnafusion_pipeline/main.nf +++ b/subworkflows/local/utils_nfcore_rnafusion_pipeline/main.nf @@ -30,10 +30,8 @@ workflow PIPELINE_INITIALISATION { take: version // boolean: Display version and exit validate_params // boolean: Boolean whether to validate parameters against the schema at runtime - monochrome_logs // boolean: Do not use coloured log outputs nextflow_cli_args // array: List of positional nextflow CLI args outdir // string: The output directory where the results will be saved - input // string: Path to input samplesheet main: @@ -114,6 +112,7 @@ workflow PIPELINE_COMPLETION { outdir // path: Path to output directory where results will be published monochrome_logs // boolean: Disable ANSI colour codes in log output hook_url // string: hook URL for notifications + multiqc_report // string: Path to MultiQC report main: summary_params = paramsSummaryMap(workflow, parameters_schema: "nextflow_schema.json") @@ -157,8 +156,8 @@ workflow PIPELINE_COMPLETION { def validateInputParameters() { genomeExistsError() - if (params.build_references && params.no_cosmic) { - log.warn("No cosmic credentials were provided. Skipping COSMIC DB download from `FUSIONREPORT_DOWNLOAD`") + if (params.no_cosmic) { + log.warn("Skipping COSMIC DB download from `FUSIONREPORT_DOWNLOAD` and skip using it in `FUSIONREPORT`") } if (params.starfusion_build && !params.fusion_annot_lib) { diff --git a/subworkflows/nf-core/utils_nextflow_pipeline/main.nf b/subworkflows/nf-core/utils_nextflow_pipeline/main.nf index 0fcbf7b3..d6e593e8 100644 --- a/subworkflows/nf-core/utils_nextflow_pipeline/main.nf +++ b/subworkflows/nf-core/utils_nextflow_pipeline/main.nf @@ -92,10 +92,12 @@ def checkCondaChannels() { channels = config.channels } catch (NullPointerException e) { + log.debug(e) log.warn("Could not verify conda channel configuration.") return null } catch (IOException e) { + log.debug(e) log.warn("Could not verify conda channel configuration.") return null } diff --git a/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.workflow.nf.test b/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.workflow.nf.test index ca964ce8..02dbf094 100644 --- a/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.workflow.nf.test +++ b/subworkflows/nf-core/utils_nextflow_pipeline/tests/main.workflow.nf.test @@ -52,10 +52,12 @@ nextflow_workflow { } then { - assertAll( - { assert workflow.success }, - { assert workflow.stdout.contains("nextflow_workflow v9.9.9") } - ) + expect { + with(workflow) { + assert success + assert "nextflow_workflow v9.9.9" in stdout + } + } } } diff --git a/subworkflows/nf-core/utils_nfcore_pipeline/main.nf b/subworkflows/nf-core/utils_nfcore_pipeline/main.nf index 5cb7bafe..bfd25876 100644 --- a/subworkflows/nf-core/utils_nfcore_pipeline/main.nf +++ b/subworkflows/nf-core/utils_nfcore_pipeline/main.nf @@ -56,21 +56,6 @@ def checkProfileProvided(nextflow_cli_args) { } } -// -// Citation string for pipeline -// -def workflowCitation() { - def temp_doi_ref = "" - def manifest_doi = workflow.manifest.doi.tokenize(",") - // Handling multiple DOIs - // Removing `https://doi.org/` to handle pipelines using DOIs vs DOI resolvers - // Removing ` ` since the manifest.doi is a string and not a proper list - manifest_doi.each { doi_ref -> - temp_doi_ref += " https://doi.org/${doi_ref.replace('https://doi.org/', '').replace(' ', '')}\n" - } - return "If you use ${workflow.manifest.name} for your analysis please cite:\n\n" + "* The pipeline\n" + temp_doi_ref + "\n" + "* The nf-core framework\n" + " https://doi.org/10.1038/s41587-020-0439-x\n\n" + "* Software dependencies\n" + " https://github.com/${workflow.manifest.name}/blob/master/CITATIONS.md" -} - // // Generate workflow version string // @@ -150,33 +135,6 @@ def paramsSummaryMultiqc(summary_params) { return yaml_file_text } -// -// nf-core logo -// -def nfCoreLogo(monochrome_logs=true) { - def colors = logColours(monochrome_logs) as Map - String.format( - """\n - ${dashedLine(monochrome_logs)} - ${colors.green},--.${colors.black}/${colors.green},-.${colors.reset} - ${colors.blue} ___ __ __ __ ___ ${colors.green}/,-._.--~\'${colors.reset} - ${colors.blue} |\\ | |__ __ / ` / \\ |__) |__ ${colors.yellow}} {${colors.reset} - ${colors.blue} | \\| | \\__, \\__/ | \\ |___ ${colors.green}\\`-._,-`-,${colors.reset} - ${colors.green}`._,._,\'${colors.reset} - ${colors.purple} ${workflow.manifest.name} ${getWorkflowVersion()}${colors.reset} - ${dashedLine(monochrome_logs)} - """.stripIndent() - ) -} - -// -// Return dashed line -// -def dashedLine(monochrome_logs=true) { - def colors = logColours(monochrome_logs) as Map - return "-${colors.dim}----------------------------------------------------${colors.reset}-" -} - // // ANSII colours used for terminal logging // @@ -245,28 +203,24 @@ def logColours(monochrome_logs=true) { return colorcodes } -// -// Attach the multiqc report to email -// -def attachMultiqcReport(multiqc_report) { - def mqc_report = null - try { - if (workflow.success) { - mqc_report = multiqc_report.getVal() - if (mqc_report.getClass() == ArrayList && mqc_report.size() >= 1) { - if (mqc_report.size() > 1) { - log.warn("[${workflow.manifest.name}] Found multiple reports from process 'MULTIQC', will use only one") - } - mqc_report = mqc_report[0] - } +// Return a single report from an object that may be a Path or List +// +def getSingleReport(multiqc_reports) { + if (multiqc_reports instanceof Path) { + return multiqc_reports + } else if (multiqc_reports instanceof List) { + if (multiqc_reports.size() == 0) { + log.warn("[${workflow.manifest.name}] No reports found from process 'MULTIQC'") + return null + } else if (multiqc_reports.size() == 1) { + return multiqc_reports.first() + } else { + log.warn("[${workflow.manifest.name}] Found multiple reports from process 'MULTIQC', will use only one") + return multiqc_reports.first() } + } else { + return null } - catch (Exception all) { - if (multiqc_report) { - log.warn("[${workflow.manifest.name}] Could not attach MultiQC report to summary email") - } - } - return mqc_report } // @@ -320,7 +274,7 @@ def completionEmail(summary_params, email, email_on_fail, plaintext_email, outdi email_fields['summary'] = summary << misc_fields // On success try attach the multiqc report - def mqc_report = attachMultiqcReport(multiqc_report) + def mqc_report = getSingleReport(multiqc_report) // Check if we are only sending emails on failure def email_address = email @@ -340,7 +294,7 @@ def completionEmail(summary_params, email, email_on_fail, plaintext_email, outdi def email_html = html_template.toString() // Render the sendmail template - def max_multiqc_email_size = (params.containsKey('max_multiqc_email_size') ? params.max_multiqc_email_size : 0) as nextflow.util.MemoryUnit + def max_multiqc_email_size = (params.containsKey('max_multiqc_email_size') ? params.max_multiqc_email_size : 0) as MemoryUnit def smail_fields = [email: email_address, subject: subject, email_txt: email_txt, email_html: email_html, projectDir: "${workflow.projectDir}", mqcFile: mqc_report, mqcMaxSize: max_multiqc_email_size.toBytes()] def sf = new File("${workflow.projectDir}/assets/sendmail_template.txt") def sendmail_template = engine.createTemplate(sf).make(smail_fields) @@ -351,14 +305,17 @@ def completionEmail(summary_params, email, email_on_fail, plaintext_email, outdi if (email_address) { try { if (plaintext_email) { -new org.codehaus.groovy.GroovyException('Send plaintext e-mail, not HTML') } + new org.codehaus.groovy.GroovyException('Send plaintext e-mail, not HTML') + } // Try to send HTML e-mail using sendmail def sendmail_tf = new File(workflow.launchDir.toString(), ".sendmail_tmp.html") sendmail_tf.withWriter { w -> w << sendmail_html } ['sendmail', '-t'].execute() << sendmail_html log.info("-${colors.purple}[${workflow.manifest.name}]${colors.green} Sent summary e-mail to ${email_address} (sendmail)-") } - catch (Exception all) { + catch (Exception msg) { + log.debug(msg.toString()) + log.debug("Trying with mail instead of sendmail") // Catch failures and try with plaintext def mail_cmd = ['mail', '-s', subject, '--content-type=text/html', email_address] mail_cmd.execute() << email_html diff --git a/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test b/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test index 1dc317f8..f117040c 100644 --- a/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test +++ b/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test @@ -41,26 +41,14 @@ nextflow_function { } } - test("Test Function workflowCitation") { - - function "workflowCitation" - - then { - assertAll( - { assert function.success }, - { assert snapshot(function.result).match() } - ) - } - } - - test("Test Function nfCoreLogo") { + test("Test Function without logColours") { - function "nfCoreLogo" + function "logColours" when { function { """ - input[0] = false + input[0] = true """ } } @@ -73,9 +61,8 @@ nextflow_function { } } - test("Test Function dashedLine") { - - function "dashedLine" + test("Test Function with logColours") { + function "logColours" when { function { @@ -93,14 +80,13 @@ nextflow_function { } } - test("Test Function without logColours") { - - function "logColours" + test("Test Function getSingleReport with a single file") { + function "getSingleReport" when { function { """ - input[0] = true + input[0] = file(params.modules_testdata_base_path + '/generic/tsv/test.tsv', checkIfExists: true) """ } } @@ -108,18 +94,22 @@ nextflow_function { then { assertAll( { assert function.success }, - { assert snapshot(function.result).match() } + { assert function.result.contains("test.tsv") } ) } } - test("Test Function with logColours") { - function "logColours" + test("Test Function getSingleReport with multiple files") { + function "getSingleReport" when { function { """ - input[0] = false + input[0] = [ + file(params.modules_testdata_base_path + '/generic/tsv/test.tsv', checkIfExists: true), + file(params.modules_testdata_base_path + '/generic/tsv/network.tsv', checkIfExists: true), + file(params.modules_testdata_base_path + '/generic/tsv/expression.tsv', checkIfExists: true) + ] """ } } @@ -127,7 +117,9 @@ nextflow_function { then { assertAll( { assert function.success }, - { assert snapshot(function.result).match() } + { assert function.result.contains("test.tsv") }, + { assert !function.result.contains("network.tsv") }, + { assert !function.result.contains("expression.tsv") } ) } } diff --git a/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test.snap b/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test.snap index 1037232c..02c67014 100644 --- a/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test.snap +++ b/subworkflows/nf-core/utils_nfcore_pipeline/tests/main.function.nf.test.snap @@ -17,26 +17,6 @@ }, "timestamp": "2024-02-28T12:02:59.729647" }, - "Test Function nfCoreLogo": { - "content": [ - "\n\n-\u001b[2m----------------------------------------------------\u001b[0m-\n \u001b[0;32m,--.\u001b[0;30m/\u001b[0;32m,-.\u001b[0m\n\u001b[0;34m ___ __ __ __ ___ \u001b[0;32m/,-._.--~'\u001b[0m\n\u001b[0;34m |\\ | |__ __ / ` / \\ |__) |__ \u001b[0;33m} {\u001b[0m\n\u001b[0;34m | \\| | \\__, \\__/ | \\ |___ \u001b[0;32m\\`-._,-`-,\u001b[0m\n \u001b[0;32m`._,._,'\u001b[0m\n\u001b[0;35m nextflow_workflow v9.9.9\u001b[0m\n-\u001b[2m----------------------------------------------------\u001b[0m-\n" - ], - "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" - }, - "timestamp": "2024-02-28T12:03:10.562934" - }, - "Test Function workflowCitation": { - "content": [ - "If you use nextflow_workflow for your analysis please cite:\n\n* The pipeline\n https://doi.org/10.5281/zenodo.5070524\n\n* The nf-core framework\n https://doi.org/10.1038/s41587-020-0439-x\n\n* Software dependencies\n https://github.com/nextflow_workflow/blob/master/CITATIONS.md" - ], - "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" - }, - "timestamp": "2024-02-28T12:03:07.019761" - }, "Test Function without logColours": { "content": [ { @@ -95,16 +75,6 @@ }, "timestamp": "2024-02-28T12:03:17.969323" }, - "Test Function dashedLine": { - "content": [ - "-\u001b[2m----------------------------------------------------\u001b[0m-" - ], - "meta": { - "nf-test": "0.8.4", - "nextflow": "23.10.1" - }, - "timestamp": "2024-02-28T12:03:14.366181" - }, "Test Function with logColours": { "content": [ { diff --git a/subworkflows/nf-core/utils_nfschema_plugin/tests/main.nf.test b/subworkflows/nf-core/utils_nfschema_plugin/tests/main.nf.test index 842dc432..8fb30164 100644 --- a/subworkflows/nf-core/utils_nfschema_plugin/tests/main.nf.test +++ b/subworkflows/nf-core/utils_nfschema_plugin/tests/main.nf.test @@ -42,7 +42,7 @@ nextflow_workflow { params { test_data = '' - outdir = 1 + outdir = null } workflow { @@ -94,7 +94,7 @@ nextflow_workflow { params { test_data = '' - outdir = 1 + outdir = null } workflow { diff --git a/tests/test_build.nf.test b/tests/test_build.nf.test deleted file mode 100644 index 1999a3b4..00000000 --- a/tests/test_build.nf.test +++ /dev/null @@ -1,36 +0,0 @@ -nextflow_pipeline { - - name "Test pipeline" - script "../main.nf" - profile "test_build" - tag "pipeline" - tag "pipeline_rnafusion" - tag "test_build" - - test("test_build") { - - when { - params { - outdir = "$outputDir" - all = false // Output files when running all are too big for CI - } - } - - then { - // stable_name: All files + folders in ${params.outdir}/ with a stable name - // Ignore files with timestamps in their names - def stable_name = getAllFilesFromDir(params.outdir, relative: true, includeDir: true, ignore: ['pipeline_info/*.{html,json,txt}']) - // stable_path: All files in ${params.outdir}/ with stable content - def stable_path = getAllFilesFromDir(params.outdir, ignoreFile: 'tests/.nftignore') - assertAll( - { assert workflow.success}, - { assert snapshot( - // All stable path name, with a relative path - stable_name, - // All files with stable contents - stable_path - ).match() } - ) - } - } -} diff --git a/tests/test_build.nf.test.snap b/tests/test_build.nf.test.snap deleted file mode 100644 index 28c64818..00000000 --- a/tests/test_build.nf.test.snap +++ /dev/null @@ -1,47 +0,0 @@ -{ - "test_build": { - "content": [ - [ - "bedops", - "bedops/Homo_sapiens.GRCh38.102_rrna_intervals.gtf.bed", - "gatk4", - "gatk4/Homo_sapiens.GRCh38.102.dna.primary_assembly.dict", - "gffread", - "gffread/Homo_sapiens.GRCh38.102.fasta", - "pipeline_info", - "references", - "references/ensembl", - "references/ensembl/Homo_sapiens.GRCh38.102.chr.gtf", - "references/ensembl/Homo_sapiens.GRCh38.102.dna.primary_assembly.fa", - "references/ensembl/Homo_sapiens.GRCh38.102.dna.primary_assembly.fa.fai", - "references/ensembl/Homo_sapiens.GRCh38.102.genepred", - "references/ensembl/Homo_sapiens.GRCh38.102.gtf", - "references/ensembl/Homo_sapiens.GRCh38.102.refflat", - "references/ensembl/Homo_sapiens.GRCh38.102_rrna_intervals.gtf.interval_list", - "references/hgnc", - "references/hgnc/HGNC-DB-timestamp.txt", - "references/hgnc/hgnc_complete_set.txt", - "rrnatranscripts", - "rrnatranscripts/Homo_sapiens.GRCh38.102_rrna_intervals.gtf" - ], - [ - "Homo_sapiens.GRCh38.102_rrna_intervals.gtf.bed:md5,5bc3ccc76735ae46699a75269f0ea65b", - "Homo_sapiens.GRCh38.102.dna.primary_assembly.dict:md5,092f1bf29fce906ff7b5ece02b4b21c8", - "Homo_sapiens.GRCh38.102.fasta:md5,d1f17b045dc60c49f2cc29e30006afc0", - "Homo_sapiens.GRCh38.102.chr.gtf:md5,0069687307852c63596b4d2ebdbbaf0c", - "Homo_sapiens.GRCh38.102.dna.primary_assembly.fa.fai:md5,d527f3eb6b664020cf4d882b5820056f", - "Homo_sapiens.GRCh38.102.genepred:md5,59c577ca4ab033c0ce1feac1e387bcab", - "Homo_sapiens.GRCh38.102.gtf:md5,defac755cd9aa4e82ec33398c27745ef", - "Homo_sapiens.GRCh38.102.refflat:md5,ef095e13743811c31d44752c32e9673e", - "Homo_sapiens.GRCh38.102_rrna_intervals.gtf.interval_list:md5,0abf61877f65247b15c438d605d85599", - "hgnc_complete_set.txt:md5,a563a2f8432ec0ab7d3dc74d769102b8", - "Homo_sapiens.GRCh38.102_rrna_intervals.gtf:md5,744bf505deb50837b15441e808cad345" - ] - ], - "meta": { - "nf-test": "0.9.0", - "nextflow": "24.10.2" - }, - "timestamp": "2024-12-09T18:20:09.914393513" - } -} \ No newline at end of file diff --git a/tests/test_cosmic.nf.test.snap b/tests/test_cosmic.nf.test.snap index e69de29b..b8e6d4a5 100644 --- a/tests/test_cosmic.nf.test.snap +++ b/tests/test_cosmic.nf.test.snap @@ -0,0 +1,58 @@ +{ + "test cosmic no fastp trim build": { + "content": [ + 0, + { + "Workflow": { + "nf-core/rnafusion": "v4.0.0dev" + } + }, + [ + "pipeline_info", + "pipeline_info/nf_core_pipeline_software_mqc_versions.yml" + ], + [ + + ] + ], + "meta": { + "nf-test": "0.9.0", + "nextflow": "24.10.2" + }, + "timestamp": "2024-12-10T12:42:49.558429" + }, + "test cosmic no fastp trim": { + "content": [ + 0, + null, + [ + "pipeline_info" + ], + [ + + ] + ], + "meta": { + "nf-test": "0.9.0", + "nextflow": "24.10.2" + }, + "timestamp": "2024-12-10T15:09:53.130295" + }, + "test cosmic with fastp trim": { + "content": [ + 0, + null, + [ + "pipeline_info" + ], + [ + + ] + ], + "meta": { + "nf-test": "0.9.0", + "nextflow": "24.10.2" + }, + "timestamp": "2024-12-10T15:09:29.277399" + } +} \ No newline at end of file diff --git a/tests/test_stub.nf.test.snap b/tests/test_stub.nf.test.snap index 3b83c240..0ac620e7 100644 --- a/tests/test_stub.nf.test.snap +++ b/tests/test_stub.nf.test.snap @@ -1,22 +1,144 @@ { "stub test no fastp trim": { "content": [ - 4, + 31, { + "ARRIBA_ARRIBA": { + "arriba": "2.4.0" + }, + "ARRIBA_DOWNLOAD": { + "arriba_download": "2.4.0" + }, + "CTATSPLICING_STARTOCANCERINTRONS": { + "ctat-splicing": "0.0.2" + }, "FASTQC": { "fastqc": "0.12.1" }, + "FUSIONCATCHER": { + "fusioncatcher": 1.35 + }, + "FUSIONCATCHER_BUILD": { + "fusioncatcher": "fusioncatcher.py 1.35" + }, "FUSIONREPORT": { "fusion_report": "2.1.5" }, + "FUSIONREPORT_DOWNLOAD": { + "fusion_report": "2.1.5" + }, + "GATK4_BEDTOINTERVALLIST": { + "gatk4": "4.6.1.0" + }, + "GATK4_CREATESEQUENCEDICTIONARY": { + "gatk4": "4.6.1.0" + }, + "GATK4_MARKDUPLICATES": { + "gatk4": "4.5.0.0", + "samtools": "1.19.2" + }, + "GENCODE_DOWNLOAD": { + "wget": null + }, + "GET_RRNA_TRANSCRIPTS": { + "get_rrna_transcripts": "v1.0" + }, + "GFFREAD": { + "gffread": "0.12.7" + }, + "GTF_TO_REFFLAT": { + "gtfToGenePred": 377 + }, + "HGNC_DOWNLOAD": { + "wget": null + }, + "PICARD_COLLECTINSERTSIZEMETRICS": { + "picard": "3.3.0" + }, + "PICARD_COLLECTRNASEQMETRICS": { + "picard": "3.3.0" + }, + "SALMON_INDEX": { + "salmon": "1.10.3" + }, + "SALMON_QUANT": { + "salmon": "1.10.3" + }, + "SAMTOOLS_FAIDX": { + "samtools": 1.21 + }, + "SAMTOOLS_INDEX_FOR_STARFUSION": { + "samtools": 1.21 + }, + "STARFUSION": { + "STAR-Fusion": "1.14.0" + }, + "STARFUSION_BUILD": { + "STAR-Fusion": "1.14.0" + }, + "STAR_FOR_ARRIBA": { + "star": "2.7.11b", + "samtools": 1.2, + "gawk": "5.1.0" + }, + "STAR_FOR_STARFUSION": { + "star": "2.7.11b", + "samtools": 1.2, + "gawk": "5.1.0" + }, + "STAR_GENOMEGENERATE": { + "star": "2.7.11b", + "samtools": 1.2, + "gawk": "5.1.0" + }, + "STRINGTIE_MERGE": { + "stringtie": "2.2.1" + }, + "STRINGTIE_STRINGTIE": { + "stringtie": "2.2.3" + }, "Workflow": { "nf-core/rnafusion": "v4.0.0dev" } }, [ + "arriba", + "arriba/test.arriba.fusions.discarded.tsv", + "arriba/test.arriba.fusions.tsv", + "ctatsplicing", + "ctatsplicing/arriba", + "ctatsplicing/arriba/test.cancer.introns", + "ctatsplicing/arriba/test.cancer.introns.prelim", + "ctatsplicing/arriba/test.cancer_intron_reads.sorted.bam", + "ctatsplicing/arriba/test.cancer_intron_reads.sorted.bam.bai", + "ctatsplicing/arriba/test.chckpts", + "ctatsplicing/arriba/test.ctat-splicing.igv.html", + "ctatsplicing/arriba/test.gene_reads.sorted.sifted.bam", + "ctatsplicing/arriba/test.gene_reads.sorted.sifted.bam.bai", + "ctatsplicing/arriba/test.igv.tracks", + "ctatsplicing/arriba/test.introns", + "ctatsplicing/arriba/test.introns.for_IGV.bed", + "ctatsplicing/starfusion", + "ctatsplicing/starfusion/test.cancer.introns", + "ctatsplicing/starfusion/test.cancer.introns.prelim", + "ctatsplicing/starfusion/test.cancer_intron_reads.sorted.bam", + "ctatsplicing/starfusion/test.cancer_intron_reads.sorted.bam.bai", + "ctatsplicing/starfusion/test.chckpts", + "ctatsplicing/starfusion/test.ctat-splicing.igv.html", + "ctatsplicing/starfusion/test.gene_reads.sorted.sifted.bam", + "ctatsplicing/starfusion/test.gene_reads.sorted.sifted.bam.bai", + "ctatsplicing/starfusion/test.igv.tracks", + "ctatsplicing/starfusion/test.introns", + "ctatsplicing/starfusion/test.introns.for_IGV.bed", "fastqc", "fastqc/test.html", "fastqc/test.zip", + "fusioncatcher", + "fusioncatcher/human_v46", + "fusioncatcher/human_v46/ensembl_fully_overlapping_genes.txt", + "fusioncatcher/test.fusioncatcher.fusion-genes.txt", + "fusioncatcher/test.fusioncatcher.log", + "fusioncatcher/test.fusioncatcher.summary.txt", "fusionreport", "fusionreport/test", "fusionreport/test/AAA_BBB.html", @@ -25,28 +147,231 @@ "fusionreport/test/test.fusions.csv", "fusionreport/test/test.fusions.json", "fusionreport/test/test_fusionreport_index.html", + "gatk4", + "gatk4/Homo_sapiens.GRCh38.46_dna_primary_assembly.dict", + "get", + "get/rrna.bed", + "get/rrna.gtf", "multiqc", "multiqc/multiqc_data", "multiqc/multiqc_plots", "multiqc/multiqc_report.html", + "picard", + "picard/test.bai", + "picard/test.bam", + "picard/test.bam.metrics", + "picard/test.cram", + "picard/test.cram.crai", + "picard/test.rna_metrics", + "picard/test_collectinsertsize.pdf", + "picard/test_collectinsertsize.txt", "pipeline_info", "pipeline_info/nf_core_pipeline_software_mqc_versions.yml", + "references", + "references/arriba", + "references/arriba/blacklist_hg38_GRCh38_v2.4.0.tsv.gz", + "references/arriba/cytobands_hg38_GRCh38_v2.4.0.tsv", + "references/arriba/known_fusions_hg38_GRCh38_v2.4.0.tsv.gz", + "references/arriba/protein_domains_hg38_GRCh38_v2.4.0.gff3", + "references/fusion_report_db", + "references/fusion_report_db/DB-timestamp.txt", + "references/fusion_report_db/cosmic.db", + "references/fusion_report_db/fusion_report.log", + "references/fusion_report_db/fusiongdb2.db", + "references/fusion_report_db/mitelman.db", + "references/gencode", + "references/gencode/Homo_sapiens.GRCh38.46.gtf", + "references/gencode/Homo_sapiens.GRCh38.46.gtf.interval_list", + "references/gencode/Homo_sapiens.GRCh38.46.gtf.refflat", + "references/gencode/Homo_sapiens.GRCh38.46_dna_primary_assembly.fa", + "references/gencode/Homo_sapiens.GRCh38.46_dna_primary_assembly.fa.fai", + "references/gffread", + "references/gffread/Homo_sapiens.GRCh38.46.gtf.fasta", + "references/hgnc", + "references/hgnc/HGNC-DB-timestamp.txt", + "references/hgnc/hgnc_complete_set.txt", + "references/salmon", + "references/salmon/salmon", + "references/salmon/salmon/complete_ref_lens.bin", + "references/salmon/salmon/ctable.bin", + "references/salmon/salmon/ctg_offsets.bin", + "references/salmon/salmon/duplicate_clusters.tsv", + "references/salmon/salmon/info.json", + "references/salmon/salmon/mphf.bin", + "references/salmon/salmon/pos.bin", + "references/salmon/salmon/pre_indexing.log", + "references/salmon/salmon/rank.bin", + "references/salmon/salmon/refAccumLengths.bin", + "references/salmon/salmon/ref_indexing.log", + "references/salmon/salmon/reflengths.bin", + "references/salmon/salmon/refseq.bin", + "references/salmon/salmon/seq.bin", + "references/salmon/salmon/versionInfo.json", + "references/star", + "references/star/Genome", + "references/star/Log.out", + "references/star/SA", + "references/star/SAindex", + "references/star/chrLength.txt", + "references/star/chrName.txt", + "references/star/chrNameLength.txt", + "references/star/chrStart.txt", + "references/star/exonGeTrInfo.tab", + "references/star/exonInfo.tab", + "references/star/geneInfo.tab", + "references/star/genomeParameters.txt", + "references/star/sjdbInfo.txt", + "references/star/sjdbList.fromGTF.out.tab", + "references/star/sjdbList.out.tab", + "references/star/transcriptInfo.tab", "salmon", "salmon/test", "salmon/test_lib_format_counts.json", - "salmon/test_meta_info.json" + "salmon/test_meta_info.json", + "star_for_arriba", + "star_for_arriba/test.Aligned.sortedByCoord.out.bam", + "star_for_arriba/test.Aligned.unsort.out.bam", + "star_for_arriba/test.Chimeric.out.junction", + "star_for_arriba/test.Log.final.out", + "star_for_arriba/test.Log.out", + "star_for_arriba/test.Log.progress.out", + "star_for_arriba/test.ReadsPerGene.out.tab", + "star_for_arriba/test.SJ.out.tab", + "star_for_arriba/test.Signal.UniqueMultiple.str1.out.bg", + "star_for_arriba/test.Signal.UniqueMultiple.str1.out.wig", + "star_for_arriba/test.out.sam", + "star_for_arriba/test.sortedByCoord.out.bam", + "star_for_arriba/test.tab", + "star_for_arriba/test.toTranscriptome.out.bam", + "star_for_arriba/test.unmapped_1.fastq.gz", + "star_for_arriba/test.unmapped_2.fastq.gz", + "star_for_arriba/testXd.out.bam", + "star_for_starfusion", + "star_for_starfusion/test.Aligned.sortedByCoord.out.bam", + "star_for_starfusion/test.Aligned.unsort.out.bam", + "star_for_starfusion/test.Chimeric.out.junction", + "star_for_starfusion/test.Log.final.out", + "star_for_starfusion/test.Log.out", + "star_for_starfusion/test.Log.progress.out", + "star_for_starfusion/test.ReadsPerGene.out.tab", + "star_for_starfusion/test.SJ.out.tab", + "star_for_starfusion/test.Signal.UniqueMultiple.str1.out.bg", + "star_for_starfusion/test.Signal.UniqueMultiple.str1.out.wig", + "star_for_starfusion/test.out.sam", + "star_for_starfusion/test.sortedByCoord.out.bam", + "star_for_starfusion/test.sortedByCoord.out.bam.bai", + "star_for_starfusion/test.tab", + "star_for_starfusion/test.toTranscriptome.out.bam", + "star_for_starfusion/test.unmapped_1.fastq.gz", + "star_for_starfusion/test.unmapped_2.fastq.gz", + "star_for_starfusion/testXd.out.bam", + "starfusion", + "starfusion/ctat_genome_lib_build_dir", + "starfusion/ctat_genome_lib_build_dir/AnnotFilterRule.pm", + "starfusion/ctat_genome_lib_build_dir/PFAM.domtblout.dat.gz", + "starfusion/ctat_genome_lib_build_dir/__chkpts", + "starfusion/ctat_genome_lib_build_dir/__chkpts/_fusion_annot_lib.idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/_prot_info_db.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/annotfiltrule_cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/blast_pairs.idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/cp_gene_blast_pairs.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/cp_pfam_dat.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/cp_ref_annot_cdna.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/fusion_annot_lib.cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/index_pfam_hits.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/index_ref_annot_cdna.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/makeblastdb.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/mm2.splice_bed.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/mm2_genome_idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.cdsplus.dfam_masked.fa.cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.cdsplus.dfam_masked.fa.idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.gtf.gene_spans.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.gtf.mini.sortu.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.gtf.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_genome.fa.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_genome_fai.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/trans.blast.dat.cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/trans.blast.dat.index.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/validate_ctat_genome_lib.ok", + "starfusion/ctat_genome_lib_build_dir/blast_pairs.dat.gz", + "starfusion/ctat_genome_lib_build_dir/blast_pairs.idx", + "starfusion/ctat_genome_lib_build_dir/fusion_annot_lib.gz", + "starfusion/ctat_genome_lib_build_dir/fusion_annot_lib.idx", + "starfusion/ctat_genome_lib_build_dir/pfam_domains.dbm", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdna.fa", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdna.fa.idx", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cds", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdsplus.fa", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdsplus.fa.idx", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf.gene_spans", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf.mini.sortu", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf.mm2.splice.bed", + "starfusion/ctat_genome_lib_build_dir/ref_annot.pep", + "starfusion/ctat_genome_lib_build_dir/ref_annot.prot_info.dbm", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.fai", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.mm2", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.ndb", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nhr", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nin", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.njs", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.not", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nsq", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.ntf", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nto", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/Genome", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/Log.out", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/SA", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/SAindex", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/build.ok", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrLength.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrName.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrNameLength.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrStart.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/exonGeTrInfo.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/exonInfo.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/geneInfo.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/genomeParameters.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/sjdbInfo.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/sjdbList.fromGTF.out.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/sjdbList.out.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/transcriptInfo.tab", + "starfusion/ctat_genome_lib_build_dir/trans.blast.align_coords.align_coords.dat", + "starfusion/ctat_genome_lib_build_dir/trans.blast.align_coords.align_coords.dbm", + "starfusion/ctat_genome_lib_build_dir/trans.blast.dat.gz", + "starfusion/test.starfusion.abridged.coding_effect.tsv", + "starfusion/test.starfusion.abridged.tsv", + "starfusion/test.starfusion.fusion_predictions.tsv", + "stringtie", + "stringtie/[:]", + "stringtie/[:]/stringtie.merged.gtf", + "stringtie/test.ballgown", + "stringtie/test.coverage.gtf", + "stringtie/test.gene.abundance.txt", + "stringtie/test.transcripts.gtf" ] ], "meta": { "nf-test": "0.9.0", "nextflow": "24.10.2" }, - "timestamp": "2024-12-03T19:27:00.717876194" + "timestamp": "2024-12-20T14:00:19.311265" }, "stub test with fastp trim": { "content": [ - 6, + 33, { + "ARRIBA_ARRIBA": { + "arriba": "2.4.0" + }, + "ARRIBA_DOWNLOAD": { + "arriba_download": "2.4.0" + }, + "CTATSPLICING_STARTOCANCERINTRONS": { + "ctat-splicing": "0.0.2" + }, "FASTP": { "fastp": "0.23.4" }, @@ -56,14 +381,121 @@ "FASTQC_FOR_FASTP": { "fastqc": "0.12.1" }, + "FUSIONCATCHER": { + "fusioncatcher": 1.35 + }, + "FUSIONCATCHER_BUILD": { + "fusioncatcher": "fusioncatcher.py 1.35" + }, "FUSIONREPORT": { "fusion_report": "2.1.5" }, + "FUSIONREPORT_DOWNLOAD": { + "fusion_report": "2.1.5" + }, + "GATK4_BEDTOINTERVALLIST": { + "gatk4": "4.6.1.0" + }, + "GATK4_CREATESEQUENCEDICTIONARY": { + "gatk4": "4.6.1.0" + }, + "GATK4_MARKDUPLICATES": { + "gatk4": "4.5.0.0", + "samtools": "1.19.2" + }, + "GENCODE_DOWNLOAD": { + "wget": null + }, + "GET_RRNA_TRANSCRIPTS": { + "get_rrna_transcripts": "v1.0" + }, + "GFFREAD": { + "gffread": "0.12.7" + }, + "GTF_TO_REFFLAT": { + "gtfToGenePred": 377 + }, + "HGNC_DOWNLOAD": { + "wget": null + }, + "PICARD_COLLECTINSERTSIZEMETRICS": { + "picard": "3.3.0" + }, + "PICARD_COLLECTRNASEQMETRICS": { + "picard": "3.3.0" + }, + "SALMON_INDEX": { + "salmon": "1.10.3" + }, + "SALMON_QUANT": { + "salmon": "1.10.3" + }, + "SAMTOOLS_FAIDX": { + "samtools": 1.21 + }, + "SAMTOOLS_INDEX_FOR_STARFUSION": { + "samtools": 1.21 + }, + "STARFUSION": { + "STAR-Fusion": "1.14.0" + }, + "STARFUSION_BUILD": { + "STAR-Fusion": "1.14.0" + }, + "STAR_FOR_ARRIBA": { + "star": "2.7.11b", + "samtools": 1.2, + "gawk": "5.1.0" + }, + "STAR_FOR_STARFUSION": { + "star": "2.7.11b", + "samtools": 1.2, + "gawk": "5.1.0" + }, + "STAR_GENOMEGENERATE": { + "star": "2.7.11b", + "samtools": 1.2, + "gawk": "5.1.0" + }, + "STRINGTIE_MERGE": { + "stringtie": "2.2.1" + }, + "STRINGTIE_STRINGTIE": { + "stringtie": "2.2.3" + }, "Workflow": { "nf-core/rnafusion": "v4.0.0dev" } }, [ + "arriba", + "arriba/test.arriba.fusions.discarded.tsv", + "arriba/test.arriba.fusions.tsv", + "ctatsplicing", + "ctatsplicing/arriba", + "ctatsplicing/arriba/test.cancer.introns", + "ctatsplicing/arriba/test.cancer.introns.prelim", + "ctatsplicing/arriba/test.cancer_intron_reads.sorted.bam", + "ctatsplicing/arriba/test.cancer_intron_reads.sorted.bam.bai", + "ctatsplicing/arriba/test.chckpts", + "ctatsplicing/arriba/test.ctat-splicing.igv.html", + "ctatsplicing/arriba/test.gene_reads.sorted.sifted.bam", + "ctatsplicing/arriba/test.gene_reads.sorted.sifted.bam.bai", + "ctatsplicing/arriba/test.igv.tracks", + "ctatsplicing/arriba/test.introns", + "ctatsplicing/arriba/test.introns.for_IGV.bed", + "ctatsplicing/starfusion", + "ctatsplicing/starfusion/test.cancer.introns", + "ctatsplicing/starfusion/test.cancer.introns.prelim", + "ctatsplicing/starfusion/test.cancer_intron_reads.sorted.bam", + "ctatsplicing/starfusion/test.cancer_intron_reads.sorted.bam.bai", + "ctatsplicing/starfusion/test.chckpts", + "ctatsplicing/starfusion/test.ctat-splicing.igv.html", + "ctatsplicing/starfusion/test.gene_reads.sorted.sifted.bam", + "ctatsplicing/starfusion/test.gene_reads.sorted.sifted.bam.bai", + "ctatsplicing/starfusion/test.igv.tracks", + "ctatsplicing/starfusion/test.introns", + "ctatsplicing/starfusion/test.introns.for_IGV.bed", "fastp", "fastp/test.fastp.html", "fastp/test.fastp.json", @@ -76,6 +508,12 @@ "fastqc_for_fastp", "fastqc_for_fastp/test_trimmed.html", "fastqc_for_fastp/test_trimmed.zip", + "fusioncatcher", + "fusioncatcher/human_v46", + "fusioncatcher/human_v46/ensembl_fully_overlapping_genes.txt", + "fusioncatcher/test.fusioncatcher.fusion-genes.txt", + "fusioncatcher/test.fusioncatcher.log", + "fusioncatcher/test.fusioncatcher.summary.txt", "fusionreport", "fusionreport/test", "fusionreport/test/AAA_BBB.html", @@ -84,22 +522,216 @@ "fusionreport/test/test.fusions.csv", "fusionreport/test/test.fusions.json", "fusionreport/test/test_fusionreport_index.html", + "gatk4", + "gatk4/Homo_sapiens.GRCh38.46_dna_primary_assembly.dict", + "get", + "get/rrna.bed", + "get/rrna.gtf", "multiqc", "multiqc/multiqc_data", "multiqc/multiqc_plots", "multiqc/multiqc_report.html", + "picard", + "picard/test.bai", + "picard/test.bam", + "picard/test.bam.metrics", + "picard/test.cram", + "picard/test.cram.crai", + "picard/test.rna_metrics", + "picard/test_collectinsertsize.pdf", + "picard/test_collectinsertsize.txt", "pipeline_info", "pipeline_info/nf_core_pipeline_software_mqc_versions.yml", + "references", + "references/arriba", + "references/arriba/blacklist_hg38_GRCh38_v2.4.0.tsv.gz", + "references/arriba/cytobands_hg38_GRCh38_v2.4.0.tsv", + "references/arriba/known_fusions_hg38_GRCh38_v2.4.0.tsv.gz", + "references/arriba/protein_domains_hg38_GRCh38_v2.4.0.gff3", + "references/fusion_report_db", + "references/fusion_report_db/DB-timestamp.txt", + "references/fusion_report_db/cosmic.db", + "references/fusion_report_db/fusion_report.log", + "references/fusion_report_db/fusiongdb2.db", + "references/fusion_report_db/mitelman.db", + "references/gencode", + "references/gencode/Homo_sapiens.GRCh38.46.gtf", + "references/gencode/Homo_sapiens.GRCh38.46.gtf.interval_list", + "references/gencode/Homo_sapiens.GRCh38.46.gtf.refflat", + "references/gencode/Homo_sapiens.GRCh38.46_dna_primary_assembly.fa", + "references/gencode/Homo_sapiens.GRCh38.46_dna_primary_assembly.fa.fai", + "references/gffread", + "references/gffread/Homo_sapiens.GRCh38.46.gtf.fasta", + "references/hgnc", + "references/hgnc/HGNC-DB-timestamp.txt", + "references/hgnc/hgnc_complete_set.txt", + "references/salmon", + "references/salmon/salmon", + "references/salmon/salmon/complete_ref_lens.bin", + "references/salmon/salmon/ctable.bin", + "references/salmon/salmon/ctg_offsets.bin", + "references/salmon/salmon/duplicate_clusters.tsv", + "references/salmon/salmon/info.json", + "references/salmon/salmon/mphf.bin", + "references/salmon/salmon/pos.bin", + "references/salmon/salmon/pre_indexing.log", + "references/salmon/salmon/rank.bin", + "references/salmon/salmon/refAccumLengths.bin", + "references/salmon/salmon/ref_indexing.log", + "references/salmon/salmon/reflengths.bin", + "references/salmon/salmon/refseq.bin", + "references/salmon/salmon/seq.bin", + "references/salmon/salmon/versionInfo.json", + "references/star", + "references/star/Genome", + "references/star/Log.out", + "references/star/SA", + "references/star/SAindex", + "references/star/chrLength.txt", + "references/star/chrName.txt", + "references/star/chrNameLength.txt", + "references/star/chrStart.txt", + "references/star/exonGeTrInfo.tab", + "references/star/exonInfo.tab", + "references/star/geneInfo.tab", + "references/star/genomeParameters.txt", + "references/star/sjdbInfo.txt", + "references/star/sjdbList.fromGTF.out.tab", + "references/star/sjdbList.out.tab", + "references/star/transcriptInfo.tab", "salmon", "salmon/test", "salmon/test_lib_format_counts.json", - "salmon/test_meta_info.json" + "salmon/test_meta_info.json", + "star_for_arriba", + "star_for_arriba/test.Aligned.sortedByCoord.out.bam", + "star_for_arriba/test.Aligned.unsort.out.bam", + "star_for_arriba/test.Chimeric.out.junction", + "star_for_arriba/test.Log.final.out", + "star_for_arriba/test.Log.out", + "star_for_arriba/test.Log.progress.out", + "star_for_arriba/test.ReadsPerGene.out.tab", + "star_for_arriba/test.SJ.out.tab", + "star_for_arriba/test.Signal.UniqueMultiple.str1.out.bg", + "star_for_arriba/test.Signal.UniqueMultiple.str1.out.wig", + "star_for_arriba/test.out.sam", + "star_for_arriba/test.sortedByCoord.out.bam", + "star_for_arriba/test.tab", + "star_for_arriba/test.toTranscriptome.out.bam", + "star_for_arriba/test.unmapped_1.fastq.gz", + "star_for_arriba/test.unmapped_2.fastq.gz", + "star_for_arriba/testXd.out.bam", + "star_for_starfusion", + "star_for_starfusion/test.Aligned.sortedByCoord.out.bam", + "star_for_starfusion/test.Aligned.unsort.out.bam", + "star_for_starfusion/test.Chimeric.out.junction", + "star_for_starfusion/test.Log.final.out", + "star_for_starfusion/test.Log.out", + "star_for_starfusion/test.Log.progress.out", + "star_for_starfusion/test.ReadsPerGene.out.tab", + "star_for_starfusion/test.SJ.out.tab", + "star_for_starfusion/test.Signal.UniqueMultiple.str1.out.bg", + "star_for_starfusion/test.Signal.UniqueMultiple.str1.out.wig", + "star_for_starfusion/test.out.sam", + "star_for_starfusion/test.sortedByCoord.out.bam", + "star_for_starfusion/test.sortedByCoord.out.bam.bai", + "star_for_starfusion/test.tab", + "star_for_starfusion/test.toTranscriptome.out.bam", + "star_for_starfusion/test.unmapped_1.fastq.gz", + "star_for_starfusion/test.unmapped_2.fastq.gz", + "star_for_starfusion/testXd.out.bam", + "starfusion", + "starfusion/ctat_genome_lib_build_dir", + "starfusion/ctat_genome_lib_build_dir/AnnotFilterRule.pm", + "starfusion/ctat_genome_lib_build_dir/PFAM.domtblout.dat.gz", + "starfusion/ctat_genome_lib_build_dir/__chkpts", + "starfusion/ctat_genome_lib_build_dir/__chkpts/_fusion_annot_lib.idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/_prot_info_db.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/annotfiltrule_cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/blast_pairs.idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/cp_gene_blast_pairs.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/cp_pfam_dat.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/cp_ref_annot_cdna.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/fusion_annot_lib.cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/index_pfam_hits.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/index_ref_annot_cdna.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/makeblastdb.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/mm2.splice_bed.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/mm2_genome_idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.cdsplus.dfam_masked.fa.cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.cdsplus.dfam_masked.fa.idx.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.gtf.gene_spans.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.gtf.mini.sortu.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_annot.gtf.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_genome.fa.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/ref_genome_fai.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/trans.blast.dat.cp.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/trans.blast.dat.index.ok", + "starfusion/ctat_genome_lib_build_dir/__chkpts/validate_ctat_genome_lib.ok", + "starfusion/ctat_genome_lib_build_dir/blast_pairs.dat.gz", + "starfusion/ctat_genome_lib_build_dir/blast_pairs.idx", + "starfusion/ctat_genome_lib_build_dir/fusion_annot_lib.gz", + "starfusion/ctat_genome_lib_build_dir/fusion_annot_lib.idx", + "starfusion/ctat_genome_lib_build_dir/pfam_domains.dbm", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdna.fa", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdna.fa.idx", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cds", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdsplus.fa", + "starfusion/ctat_genome_lib_build_dir/ref_annot.cdsplus.fa.idx", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf.gene_spans", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf.mini.sortu", + "starfusion/ctat_genome_lib_build_dir/ref_annot.gtf.mm2.splice.bed", + "starfusion/ctat_genome_lib_build_dir/ref_annot.pep", + "starfusion/ctat_genome_lib_build_dir/ref_annot.prot_info.dbm", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.fai", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.mm2", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.ndb", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nhr", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nin", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.njs", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.not", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nsq", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.ntf", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.nto", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/Genome", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/Log.out", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/SA", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/SAindex", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/build.ok", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrLength.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrName.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrNameLength.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/chrStart.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/exonGeTrInfo.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/exonInfo.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/geneInfo.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/genomeParameters.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/sjdbInfo.txt", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/sjdbList.fromGTF.out.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/sjdbList.out.tab", + "starfusion/ctat_genome_lib_build_dir/ref_genome.fa.star.idx/transcriptInfo.tab", + "starfusion/ctat_genome_lib_build_dir/trans.blast.align_coords.align_coords.dat", + "starfusion/ctat_genome_lib_build_dir/trans.blast.align_coords.align_coords.dbm", + "starfusion/ctat_genome_lib_build_dir/trans.blast.dat.gz", + "starfusion/test.starfusion.abridged.coding_effect.tsv", + "starfusion/test.starfusion.abridged.tsv", + "starfusion/test.starfusion.fusion_predictions.tsv", + "stringtie", + "stringtie/[:]", + "stringtie/[:]/stringtie.merged.gtf", + "stringtie/test.ballgown", + "stringtie/test.coverage.gtf", + "stringtie/test.gene.abundance.txt", + "stringtie/test.transcripts.gtf" ] ], "meta": { "nf-test": "0.9.0", "nextflow": "24.10.2" }, - "timestamp": "2024-12-03T19:26:43.375635514" + "timestamp": "2024-12-20T13:57:10.179877" } -} \ No newline at end of file +} diff --git a/workflows/build_references.nf b/workflows/build_references.nf deleted file mode 100644 index a75dfb30..00000000 --- a/workflows/build_references.nf +++ /dev/null @@ -1,94 +0,0 @@ -/* -======================================================================================== - IMPORT LOCAL MODULES/SUBWORKFLOWS -======================================================================================== -*/ - -include { ENSEMBL_DOWNLOAD } from '../modules/local/ensembl/main' -include { FUSIONCATCHER_DOWNLOAD } from '../modules/local/fusioncatcher/download/main' -include { FUSIONREPORT_DOWNLOAD } from '../modules/local/fusionreport/download/main' -include { HGNC_DOWNLOAD } from '../modules/local/hgnc/main' -include { STARFUSION_BUILD } from '../modules/local/starfusion/build/main' -include { STARFUSION_DOWNLOAD } from '../modules/local/starfusion/download/main' - -/* -======================================================================================== - IMPORT NF-CORE MODULES/SUBWORKFLOWS -======================================================================================== -*/ - -include { ARRIBA_DOWNLOAD } from '../modules/nf-core/arriba/download/main' -include { BEDOPS_CONVERT2BED } from '../modules/nf-core/bedops/convert2bed/main' -include { GATK4_BEDTOINTERVALLIST } from '../modules/nf-core/gatk4/bedtointervallist/main' -include { GATK4_CREATESEQUENCEDICTIONARY } from '../modules/nf-core/gatk4/createsequencedictionary/main' -include { RRNATRANSCRIPTS } from '../modules/nf-core/rrnatranscripts/main' -include { SAMTOOLS_FAIDX } from '../modules/nf-core/samtools/faidx/main' -include { STAR_GENOMEGENERATE } from '../modules/nf-core/star/genomegenerate/main' -include { UCSC_GTFTOGENEPRED } from '../modules/nf-core/ucsc/gtftogenepred/main' -include { SALMON_INDEX } from '../modules/nf-core/salmon/index/main' -include { GFFREAD } from '../modules/nf-core/gffread/main' - -/* -======================================================================================== - RUN MAIN WORKFLOW -======================================================================================== -*/ - -workflow BUILD_REFERENCES { - - def fake_meta = [:] - fake_meta.id = "Homo_sapiens.${params.genome}.${params.ensembl_version}" - ENSEMBL_DOWNLOAD( params.ensembl_version, params.genome, fake_meta ) - HGNC_DOWNLOAD() - SAMTOOLS_FAIDX(ENSEMBL_DOWNLOAD.out.primary_assembly, [[],[]]) - GATK4_CREATESEQUENCEDICTIONARY(ENSEMBL_DOWNLOAD.out.primary_assembly) - - - RRNATRANSCRIPTS(ENSEMBL_DOWNLOAD.out.gtf.map{ it -> [ it[1] ] }) - BEDOPS_CONVERT2BED(RRNATRANSCRIPTS.out.rrna_gtf.map{ it -> [[id:it.Name], it] }) - GATK4_BEDTOINTERVALLIST(BEDOPS_CONVERT2BED.out.bed, GATK4_CREATESEQUENCEDICTIONARY.out.dict) - - GFFREAD(ENSEMBL_DOWNLOAD.out.gtf, ENSEMBL_DOWNLOAD.out.primary_assembly.map { it -> [ it[1] ] }) - - if (!params.skip_salmon_index){ - SALMON_INDEX(ENSEMBL_DOWNLOAD.out.primary_assembly.map{ it -> [ it[1] ] }, GFFREAD.out.gffread_fasta.map{ it -> [ it[1] ] }) - } - - if (params.starindex || params.all || params.starfusion || params.arriba) { - STAR_GENOMEGENERATE( ENSEMBL_DOWNLOAD.out.primary_assembly, ENSEMBL_DOWNLOAD.out.gtf ) - } - - if (params.arriba || params.all) { - ARRIBA_DOWNLOAD() - } - - if (params.fusioncatcher || params.all) { - FUSIONCATCHER_DOWNLOAD() - } - - if (params.starfusion || params.all) { - if (params.starfusion_build){ - val_species = Channel.value("human") - ch_fusion_annot_lib = params.fusion_annot_lib - STARFUSION_BUILD( ENSEMBL_DOWNLOAD.out.primary_assembly, ENSEMBL_DOWNLOAD.out.gtf, ch_fusion_annot_lib, val_species) - } else { - STARFUSION_DOWNLOAD() - } - } - - if (params.starfusion_build){ - UCSC_GTFTOGENEPRED(ENSEMBL_DOWNLOAD.out.chrgtf) - } else { - UCSC_GTFTOGENEPRED(STARFUSION_DOWNLOAD.out.chrgtf) - } - if (params.fusionreport || params.all) { - FUSIONREPORT_DOWNLOAD() - } - -} - -/* -======================================================================================== - THE END -======================================================================================== -*/ diff --git a/workflows/rnafusion.nf b/workflows/rnafusion.nf index 74315e84..857827aa 100644 --- a/workflows/rnafusion.nf +++ b/workflows/rnafusion.nf @@ -3,7 +3,10 @@ IMPORT MODULES / SUBWORKFLOWS / FUNCTIONS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ -include { TRIM_WORKFLOW } from '../subworkflows/local/trim_workflow' + +include { BUILD_REFERENCES } from '../subworkflows/local/build_references' +include { CAT_FASTQ } from '../modules/nf-core/cat/fastq/main' +include { TRIM_WORKFLOW } from '../subworkflows/local/trim_workflow/main' include { ARRIBA_WORKFLOW } from '../subworkflows/local/arriba_workflow' include { QC_WORKFLOW } from '../subworkflows/local/qc_workflow' include { STARFUSION_WORKFLOW } from '../subworkflows/local/starfusion_workflow' @@ -11,15 +14,14 @@ include { STRINGTIE_WORKFLOW } from '../subworkflows/local/stringti include { FUSIONCATCHER_WORKFLOW } from '../subworkflows/local/fusioncatcher_workflow' include { FUSIONINSPECTOR_WORKFLOW } from '../subworkflows/local/fusioninspector_workflow' include { FUSIONREPORT_WORKFLOW } from '../subworkflows/local/fusionreport_workflow' +include { FASTQC } from '../modules/nf-core/fastqc/main' +include { MULTIQC } from '../modules/nf-core/multiqc/main' +include { SALMON_QUANT } from '../modules/nf-core/salmon/quant/main' +include { paramsSummaryMap } from 'plugin/nf-schema' +include { paramsSummaryMultiqc } from '../subworkflows/nf-core/utils_nfcore_pipeline' +include { softwareVersionsToYAML } from '../subworkflows/nf-core/utils_nfcore_pipeline' +include { methodsDescriptionText } from '../subworkflows/local/utils_nfcore_rnafusion_pipeline' include { validateInputSamplesheet } from '../subworkflows/local/utils_nfcore_rnafusion_pipeline' -include { CAT_FASTQ } from '../modules/nf-core/cat/fastq/main' -include { FASTQC } from '../modules/nf-core/fastqc/main' -include { MULTIQC } from '../modules/nf-core/multiqc/main' -include { SALMON_QUANT } from '../modules/nf-core/salmon/quant/main' -include { paramsSummaryMap } from 'plugin/nf-schema' -include { paramsSummaryMultiqc } from '../subworkflows/nf-core/utils_nfcore_pipeline' -include { softwareVersionsToYAML } from '../subworkflows/nf-core/utils_nfcore_pipeline' -include { methodsDescriptionText } from '../subworkflows/local/utils_nfcore_rnafusion_pipeline' /* @@ -30,6 +32,7 @@ include { methodsDescriptionText } from '../subworkflows/local/utils_nfcore_rnaf workflow RNAFUSION { + take: ch_samplesheet // channel: samplesheet read in from --input @@ -38,48 +41,38 @@ workflow RNAFUSION { def ch_versions = Channel.empty() def ch_multiqc_files = Channel.empty() - def ch_chrgtf = params.starfusion_build ? Channel.fromPath(params.chrgtf).map { it -> [[id:it.Name], it] }.collect() : Channel.fromPath("${params.starfusion_ref}/ref_annot.gtf").map { it -> [[id:it.Name], it] }.collect() - def ch_starindex_ref = params.starfusion_build ? Channel.fromPath(params.starindex_ref).map { it -> [[id:it.Name], it] }.collect() : Channel.fromPath("${params.starfusion_ref}/ref_genome.fa.star.idx").map { it -> [[id:it.Name], it] }.collect() - def ch_starindex_ensembl_ref = Channel.fromPath(params.starindex_ref).map { it -> [[id:it.Name], it] }.collect() - def ch_refflat = params.starfusion_build ? Channel.fromPath(params.refflat).map { it -> [[id:it.Name], it] }.collect() : Channel.fromPath("${params.ensembl_ref}/ref_annot.gtf.refflat").map { it -> [[id:it.Name], it] }.collect() - def ch_rrna_interval = params.starfusion_build ? Channel.fromPath(params.rrna_intervals).map { it -> [[id:it.Name], it] }.collect() : Channel.fromPath("${params.ensembl_ref}/ref_annot.interval_list").map { it -> [[id:it.Name], it] }.collect() - def ch_adapter_fastp = params.adapter_fasta ? Channel.fromPath(params.adapter_fasta, checkIfExists: true) : Channel.empty() - def ch_fusionreport_ref = Channel.fromPath(params.fusionreport_ref).map { it -> [[id:it.Name], it] }.collect() - def ch_arriba_ref_blacklist = Channel.fromPath(params.arriba_ref_blacklist).map { it -> [[id:it.Name], it] }.collect() - def ch_arriba_ref_known_fusions = Channel.fromPath(params.arriba_ref_known_fusions).map { it -> [[id:it.Name], it] }.collect() - def ch_arriba_ref_protein_domains = Channel.fromPath(params.arriba_ref_protein_domains).map { it -> [[id:it.Name], it] }.collect() - def ch_arriba_ref_cytobands = Channel.fromPath(params.arriba_ref_cytobands).map { it -> [[id:it.Name], it] }.collect() - def ch_hgnc_ref = Channel.fromPath(params.hgnc_ref).map { it -> [[id:it.Name], it] }.collect() - def ch_hgnc_date = Channel.fromPath(params.hgnc_date).map { it -> [[id:it.Name], it] }.collect() - def ch_fasta = Channel.fromPath(params.fasta).map { it -> [[id:it.Name], it] }.collect() - def ch_gtf = Channel.fromPath(params.gtf).map { it -> [[id:it.Name], it] }.collect() - def ch_salmon_index = Channel.fromPath(params.salmon_index).map { it -> [[id:it.Name], it] }.collect() - def ch_transcript = Channel.fromPath(params.transcript).map { it -> [[id:it.Name], it] }.collect() - def ch_fai = Channel.fromPath(params.fai).map { it -> [[id:it.Name], it] }.collect() - def ch_starfusion_ref = Channel.fromPath(params.starfusion_ref).map { it -> [[id:it.name], it]}.collect() + // + // Create references if necessary + // + + BUILD_REFERENCES() + ch_versions = ch_versions.mix(BUILD_REFERENCES.out.versions) + // - // MODULE: Run FastQC + // QC from FASTQ files // FASTQC ( ch_samplesheet ) ch_multiqc_files = ch_multiqc_files.mix(FASTQC.out.zip.collect{it[1]}) - ch_versions = ch_versions.mix(FASTQC.out.versions.first()) - + ch_versions = ch_versions.mix(FASTQC.out.versions) + // + // Trimming + // TRIM_WORKFLOW ( ch_samplesheet, - ch_adapter_fastp, + Channel.value(params.adapter_fasta), params.fastp_trim ) - ch_reads_fusioncatcher = TRIM_WORKFLOW.out.ch_reads_fusioncatcher - ch_reads_all = TRIM_WORKFLOW.out.ch_reads_all - ch_versions = ch_versions.mix(TRIM_WORKFLOW.out.versions) + ch_reads = TRIM_WORKFLOW.out.ch_reads_all + ch_versions = ch_versions.mix(TRIM_WORKFLOW.out.versions) - - SALMON_QUANT( ch_reads_all, ch_salmon_index.map{ meta, index -> index }, ch_gtf.map{ meta, gtf -> gtf }, [], false, 'A') + SALMON_QUANT( ch_reads, BUILD_REFERENCES.out.ch_salmon_index.map{ it -> it[1] }, BUILD_REFERENCES.out.ch_gtf.map{ it -> it[1] }, [], false, 'A') + ch_multiqc_files = ch_multiqc_files.mix(SALMON_QUANT.out.json_info.collect{it[1]}) + ch_versions = ch_versions.mix(SALMON_QUANT.out.versions) // @@ -87,19 +80,19 @@ workflow RNAFUSION { // // TODO: add params.seq_platform and pass it as argument to arriba_workflow - // TODO: improve how params.arriba_fusions would avoid running arriba module. Maybe inputed from samplesheet? + // TODO: improve how params.arriba_fusions would avoid running arriba module. Maybe imputed from samplesheet? // TODO: same as above, but with ch_arriba_fusion_fail. It's currently replaces by a dummy file ARRIBA_WORKFLOW ( - ch_reads_all, - ch_gtf, - ch_fasta, - ch_starindex_ensembl_ref, - ch_arriba_ref_blacklist, - ch_arriba_ref_known_fusions, - ch_arriba_ref_cytobands, - ch_arriba_ref_protein_domains, - ch_starfusion_ref, + ch_reads, + BUILD_REFERENCES.out.ch_gtf, + BUILD_REFERENCES.out.ch_fasta, + BUILD_REFERENCES.out.ch_starindex_ref, + BUILD_REFERENCES.out.ch_arriba_ref_blacklist, + BUILD_REFERENCES.out.ch_arriba_ref_cytobands, + BUILD_REFERENCES.out.ch_arriba_ref_known_fusions, + BUILD_REFERENCES.out.ch_arriba_ref_protein_domains, + BUILD_REFERENCES.out.ch_starfusion_ref, params.arriba, // boolean params.all, // boolean params.fusioninspector_only, // boolean @@ -114,18 +107,18 @@ workflow RNAFUSION { //Run STAR fusion STARFUSION_WORKFLOW ( - ch_reads_all, - ch_chrgtf, - ch_starindex_ref, - ch_fasta, - ch_starfusion_ref + ch_reads, + BUILD_REFERENCES.out.ch_gtf, + BUILD_REFERENCES.out.ch_starindex_ref, + BUILD_REFERENCES.out.ch_fasta, + BUILD_REFERENCES.out.ch_starfusion_ref ) ch_versions = ch_versions.mix(STARFUSION_WORKFLOW.out.versions) //Run fusioncatcher FUSIONCATCHER_WORKFLOW ( - ch_reads_fusioncatcher + ch_reads ) ch_versions = ch_versions.mix(FUSIONCATCHER_WORKFLOW.out.versions) @@ -133,15 +126,15 @@ workflow RNAFUSION { //Run stringtie STRINGTIE_WORKFLOW ( STARFUSION_WORKFLOW.out.ch_bam_sorted, - ch_chrgtf + BUILD_REFERENCES.out.ch_gtf ) ch_versions = ch_versions.mix(STRINGTIE_WORKFLOW.out.versions) //Run fusion-report FUSIONREPORT_WORKFLOW ( - ch_reads_all, - ch_fusionreport_ref, + ch_reads, + BUILD_REFERENCES.out.ch_fusionreport_ref, ARRIBA_WORKFLOW.out.fusions, STARFUSION_WORKFLOW.out.fusions, FUSIONCATCHER_WORKFLOW.out.fusions @@ -150,17 +143,17 @@ workflow RNAFUSION { //Run fusionInpector FUSIONINSPECTOR_WORKFLOW ( - ch_reads_all, + ch_reads, FUSIONREPORT_WORKFLOW.out.fusion_list, FUSIONREPORT_WORKFLOW.out.fusion_list_filtered, FUSIONREPORT_WORKFLOW.out.report, FUSIONREPORT_WORKFLOW.out.csv, STARFUSION_WORKFLOW.out.ch_bam_sorted_indexed, - ch_chrgtf, - ch_arriba_ref_protein_domains, - ch_arriba_ref_cytobands, - ch_hgnc_ref, - ch_hgnc_date + BUILD_REFERENCES.out.ch_gtf, + BUILD_REFERENCES.out.ch_arriba_ref_protein_domains, + BUILD_REFERENCES.out.ch_arriba_ref_cytobands, + BUILD_REFERENCES.out.ch_hgnc_ref, + BUILD_REFERENCES.out.ch_hgnc_date ) ch_versions = ch_versions.mix(FUSIONINSPECTOR_WORKFLOW.out.versions) @@ -168,26 +161,25 @@ workflow RNAFUSION { //QC QC_WORKFLOW ( STARFUSION_WORKFLOW.out.ch_bam_sorted, - ch_chrgtf, - ch_refflat, - ch_fasta, - ch_fai, - ch_rrna_interval + BUILD_REFERENCES.out.ch_refflat, + BUILD_REFERENCES.out.ch_fasta, + BUILD_REFERENCES.out.ch_fai, + BUILD_REFERENCES.out.ch_rrna_interval ) ch_versions = ch_versions.mix(QC_WORKFLOW.out.versions) - // // Collate and save software versions // softwareVersionsToYAML(ch_versions) .collectFile( storeDir: "${params.outdir}/pipeline_info", - name: 'nf_core_' + 'pipeline_software_' + 'mqc_' + 'versions.yml', + name: 'nf_core_pipeline_software_mqc_versions.yml', sort: true, newLine: true ).set { ch_collated_versions } + // // MODULE: MultiQC //