Skip to content

Commit

Permalink
Merge pull request #57 from Ferlab-Ste-Justine/fix/CLIN-3414-allow-to…
Browse files Browse the repository at this point in the history
…-pass-exomiser-spring-options

fix: CLIN-2414 allow to pass exomiser spring options in task.ext
  • Loading branch information
LysianeBouchard authored Jan 16, 2025
2 parents 413108a + 01ea33f commit f1e9d44
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 2 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## v2.4.0-dev - [date]

### `Fixed`
- [#57](https://github.com/Ferlab-Ste-Justine/Post-processing-Pipeline/pull/57) Allow to pass exomiser application properties

## v2.3.0-dev

### `Added`
Expand Down
10 changes: 10 additions & 0 deletions docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,16 @@ To have the Exomiser step start from the VEP output instead, set the parameter `

Note that the parameter `exomiser_start_from_vep` will be ignored if vep is not specified via the `tools` parameter.

### Exomiser CLI options

We typically allow passing extra arguments in our process scripts via the process `task.ext` directive (`task.ext.args` key).

When using the exomiser process, it's important to distinguish between regular CLI options and options that correspond to properties normally specified in the application.properties file.

Regular CLI options should be added to `task.ext.args`.

Options that correspond to application properties (e.g., typically `--exomiser.some-property=value`) must be added to `task.ext.application_properties_args`. These options need to be grouped at the end of the exomiser command to ensure that regular exomiser cli options are parsed correctly.

### Customize versions and commands

If needed, it is possible to customize the options passed to the vep command by overriding the ext.args directive for the
Expand Down
6 changes: 4 additions & 2 deletions modules/local/exomiser/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ process EXOMISER {

script:
def args = task.ext.args ?: ''
def applicationPropertiesArgs = task.ext.application_properties_args ?: ''

def localFrequencyFileArgs = ""
if (localFrequencyPath) {
Expand Down Expand Up @@ -67,18 +68,19 @@ process EXOMISER {
#!/bin/bash -eo pipefail
java -Xmx${avail_mem}M -cp \$( cat /app/jib-classpath-file ) \$( cat /app/jib-main-class-file ) \\
${args} \\
--vcf ${vcfFile} \\
--assembly "${params.exomiser_genome}" \\
--analysis "${analysisFile}" \\
--sample ${phenoFile} \\
--output-format=HTML,JSON,TSV_GENE,TSV_VARIANT,VCF \\
${args} \\
--exomiser.data-directory=/`pwd`/${datadir} \\
${localFrequencyFileArgs} \\
${remmArgs} \\
${caddArgs} \\
--exomiser.${exomiserGenome}.data-version="${exomiserDataVersion}" \\
--exomiser.phenotype.data-version="${exomiserDataVersion}"
--exomiser.phenotype.data-version="${exomiserDataVersion}" \\
${applicationPropertiesArgs}
cat <<-END_VERSIONS > versions.yml
"${task.process}":
Expand Down

0 comments on commit f1e9d44

Please sign in to comment.