-
Notifications
You must be signed in to change notification settings - Fork 1k
feat: gridss/annotate nf-core module #11117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
add37aa
feat: add gridss/annotate module
emmcauley 118fc14
Apply suggestions from code review
emmcauley cb107a5
fix: reviewer comments (remove echo, use SanitizeOutput for test, upd…
emmcauley 0301bd9
fix: restore 2>&1 to get version outputs
emmcauley 18cb9e2
tests: update somaticfilter test
emmcauley 9b822ba
fix: meta.yml files
emmcauley File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| --- | ||
| # yaml-language-server: $schema=https://raw.githubusercontent.com/nf-core/modules/master/modules/environment-schema.json | ||
| channels: | ||
| - conda-forge | ||
| - bioconda | ||
| dependencies: | ||
| - bioconda::gridss=2.13.2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,42 @@ | ||
| process GRIDSS_ANNOTATE { | ||
| tag "${meta.id}" | ||
| label 'process_medium' | ||
|
|
||
| conda "${moduleDir}/environment.yml" | ||
| container "${workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container | ||
| ? 'https://depot.galaxyproject.org/singularity/gridss:2.13.2--h270b39a_0' | ||
| : 'biocontainers/gridss:2.13.2--h270b39a_0'}" | ||
|
|
||
| input: | ||
| tuple val(meta), path(vcf) | ||
|
|
||
| output: | ||
| tuple val(meta), path("*.vcf.gz"), emit: vcf | ||
| tuple val("${task.process}"), val('gridss'), eval("GeneratePonBedpe --version 2>&1 | sed 's/-gridss//'"), topic: versions, emit: versions_gridss | ||
|
|
||
| when: | ||
| task.ext.when == null || task.ext.when | ||
|
|
||
| script: | ||
| def args = task.ext.args ?: '' | ||
| def prefix = task.ext.prefix ?: "${meta.id}.annotated" | ||
| if ("${vcf}" == "${prefix}.vcf.gz") { | ||
| error("Input and output names are the same, use \"task.ext.prefix\" to disambiguate!") | ||
| } | ||
| """ | ||
| mkdir -p ${prefix}_work | ||
|
|
||
| gridss_annotate_vcf_repeatmasker \\ | ||
| --output ${prefix}.vcf.gz \\ | ||
| --workingdir ${prefix}_work \\ | ||
| --threads ${task.cpus} \\ | ||
| ${args} \\ | ||
| ${vcf} | ||
| """ | ||
|
|
||
| stub: | ||
| def prefix = task.ext.prefix ?: "${meta.id}.annotated" | ||
| """ | ||
| echo "" | gzip > ${prefix}.vcf.gz | ||
| """ | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,69 @@ | ||
| name: "gridss_annotate" | ||
| description: Annotates single breakends in a GRIDSS VCF with RepeatMasker | ||
| annotations using gridss_annotate_vcf_repeatmasker. | ||
| keywords: | ||
| - gridss | ||
| - structural variants | ||
| - annotation | ||
| - repeatmasker | ||
| - vcf | ||
| tools: | ||
| - gridss: | ||
| description: "GRIDSS: the Genomic Rearrangement IDentification Software Suite" | ||
| documentation: "https://github.com/PapenfussLab/gridss/wiki/GRIDSS-Documentation" | ||
| tool_dev_url: "https://github.com/PapenfussLab/gridss" | ||
| doi: "10.1186/s13059-021-02423-x" | ||
| licence: | ||
| - "GPL v3" | ||
| identifier: biotools:gridss | ||
| input: | ||
| - - meta: | ||
| type: map | ||
| description: | | ||
| Groovy Map containing sample information | ||
| e.g. [ id:'test'] | ||
| - vcf: | ||
| type: file | ||
| description: Input VCF file generated with GRIDSS | ||
| pattern: "*.{vcf,vcf.gz}" | ||
| ontologies: | ||
| - edam: "http://edamontology.org/format_3016" | ||
| output: | ||
| vcf: | ||
| - - meta: | ||
| type: map | ||
| description: | | ||
| Groovy Map containing sample information | ||
| e.g. [ id:'test'] | ||
| - "*.vcf.gz": | ||
| type: file | ||
| description: Annotated VCF file compressed with bgzip | ||
| pattern: "*.vcf.gz" | ||
| ontologies: | ||
| - edam: "http://edamontology.org/format_3016" | ||
| - edam: http://edamontology.org/format_3989 | ||
| versions_gridss: | ||
| - - ${task.process}: | ||
| type: string | ||
| description: The process | ||
| - gridss: | ||
| type: string | ||
| description: The tool name | ||
| - GeneratePonBedpe --version 2>&1 | sed 's/-gridss//': | ||
| type: eval | ||
| description: The expression to obtain the version of the tool | ||
| topics: | ||
| versions: | ||
| - - ${task.process}: | ||
| type: string | ||
| description: The process | ||
| - gridss: | ||
| type: string | ||
| description: The tool name | ||
| - GeneratePonBedpe --version 2>&1 | sed 's/-gridss//': | ||
| type: eval | ||
| description: The expression to obtain the version of the tool | ||
| authors: | ||
| - "@emmcauley" | ||
| maintainers: | ||
| - "@emmcauley" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,56 @@ | ||
| nextflow_process { | ||
|
|
||
| name "Test Process GRIDSS_ANNOTATE" | ||
| script "../main.nf" | ||
| process "GRIDSS_ANNOTATE" | ||
|
|
||
| tag "modules" | ||
| tag "modules_nfcore" | ||
| tag "gridss" | ||
| tag "gridss/annotate" | ||
|
|
||
| test("human - vcf") { | ||
|
|
||
| when { | ||
| process { | ||
| """ | ||
| input[0] = [ [ id:'test' ], | ||
| file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/vcf/NA12878_GIAB.chr22.vcf.gz', checkIfExists: true) | ||
| ] | ||
| """ | ||
| } | ||
| } | ||
|
|
||
| then { | ||
| assertAll( | ||
| { assert process.success }, | ||
| { assert snapshot(sanitizeOutput(process.out)).match() } | ||
| ) | ||
| } | ||
|
|
||
| } | ||
|
|
||
| test("human - vcf - stub") { | ||
|
|
||
| options "-stub" | ||
|
|
||
| when { | ||
| process { | ||
| """ | ||
| input[0] = [ [ id:'test' ], | ||
| file(params.modules_testdata_base_path + 'genomics/homo_sapiens/illumina/vcf/NA12878_GIAB.chr22.vcf.gz', checkIfExists: true) | ||
| ] | ||
| """ | ||
| } | ||
| } | ||
|
|
||
| then { | ||
| assertAll( | ||
| { assert process.success }, | ||
| { assert snapshot(sanitizeOutput(process.out)).match() } | ||
| ) | ||
| } | ||
|
|
||
| } | ||
|
|
||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,54 @@ | ||
| { | ||
| "human - vcf": { | ||
| "content": [ | ||
| { | ||
| "vcf": [ | ||
| [ | ||
| { | ||
| "id": "test" | ||
| }, | ||
| "test.annotated.vcf.gz:md5,15ceb389949b96123975b0dfd7059ef3" | ||
| ] | ||
| ], | ||
| "versions_gridss": [ | ||
| [ | ||
| "GRIDSS_ANNOTATE", | ||
| "gridss", | ||
| "2.13.2" | ||
| ] | ||
| ] | ||
| } | ||
| ], | ||
| "meta": { | ||
| "nf-test": "0.9.3", | ||
| "nextflow": "25.10.2" | ||
| }, | ||
| "timestamp": "2026-04-08T11:09:23.605669" | ||
| }, | ||
| "human - vcf - stub": { | ||
| "content": [ | ||
| { | ||
| "vcf": [ | ||
| [ | ||
| { | ||
| "id": "test" | ||
| }, | ||
| "test.annotated.vcf.gz:md5,68b329da9893e34099c7d8ad5cb9c940" | ||
| ] | ||
| ], | ||
| "versions_gridss": [ | ||
| [ | ||
| "GRIDSS_ANNOTATE", | ||
| "gridss", | ||
| "2.13.2" | ||
| ] | ||
| ] | ||
| } | ||
| ], | ||
| "meta": { | ||
| "nf-test": "0.9.3", | ||
| "nextflow": "25.10.2" | ||
| }, | ||
| "timestamp": "2026-04-08T11:09:54.107154" | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.