Skip to content

Commit

Permalink
Merge branch 'dev' into jfy133-review-fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jfy133 authored Sep 25, 2024
2 parents b9e3c38 + 0f5651f commit 0c647d1
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 18 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- [#523](https://github.com/nf-core/taxprofiler/pull/523) Removed hardcoded `-m lca` from GANON_CLASSIFY due to more options in new version of ganon (fixed by @LilyAnderssonLee & @jfy133)
- [#531](https://github.com/nf-core/taxprofiler/pull/531) Fix FASTA input validation in schema allowing FASTQ extension, expand allowed FASTA extensions (fixed by @jfy133)
- [#512](https://github.com/nf-core/taxprofiler/pull/532) Minor formatting and ordering improvements in MultiQC report (by @jfy133)
- [#532](https://github.com/nf-core/taxprofiler/pull/532) - Added missing documentation behind the 'ignore' BRACKEN_BRACKEN error strategy (❤️ to @Mavti for reporting, fixed by @jfy133)

### `Dependencies`

Expand Down
28 changes: 25 additions & 3 deletions docs/usage/faq-troubleshooting.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,31 @@
# Troubleshooting and FAQs

## I get a warning during centrifuge_kreport process with exit status 255
## I get a warning during CENTRIFUGE_KREPORT or KRAKENTOOLS_COMBINEKREPORTS_CENTRIFUGE process with exit status 255

When a sample has insufficient hits for abundance estimation, the resulting `report.txt` file will be empty.

When trying to convert this to a kraken-style report, the conversion tool will exit with a status code `255`, and provide a `WARN`.
When trying to convert this to a kraken-style report or merging together, the tools will exit with a status code `255`, and provide a `WARN`.

This is _not_ an error nor a failure of the pipeline, just your sample has no hits to the provided database when using centrifuge.
This is _not_ an error nor a failure of the pipeline, just your sample has no hits to the provided database when using Centrifuge.

## Why does any error or failed process from BRACKEN_BRACKEN get ignored?

If Kraken2 doesn't classify any reads (100% unclassified) Bracken will fail on that input.
Having no reads taxonomically classified can be a reasonable outcome for some samples, and we don't want to treat this as an error.

Therefore to allow the remainder of a given run to complete if a single Bracken task fails, [we set the Nextflow `errorStrategy` to `ignore`](https://github.com/nf-core/taxprofiler/blob/5d3ee5513a84f92773c8376c55b5f4da39835307/conf/base.config#L61-L63).
You will still get a warning in the Nextflow console output and log that a Bracken task failed.

If you want to change this behaviour, you can override the `errorStrategy` in your own Nextflow configuration file.

For example:

```nextflow
process {
withName: BRACKEN_BRACKEN {
errorStrategy = 'retry'
}
}
```

Other `errorStrategy` options can be found on the [Nextflow documentation](https://www.nextflow.io/docs/latest/process.html#errorstrategy).
25 changes: 12 additions & 13 deletions nextflow.config
Original file line number Diff line number Diff line change
Expand Up @@ -314,20 +314,19 @@ profiles {
executor.cpus = 4
executor.memory = 8.GB
}
test { includeConfig 'conf/test.config' }
test_full { includeConfig 'conf/test_full.config' }
test_noprofiling { includeConfig 'conf/test_noprofiling.config' }
test_nopreprocessing { includeConfig 'conf/test_nopreprocessing.config' }
test_nothing { includeConfig 'conf/test_nothing.config' }
test_motus { includeConfig 'conf/test_motus.config' }
test_krakenuniq { includeConfig 'conf/test_krakenuniq.config' }
test_malt { includeConfig 'conf/test_malt.config' }
test_falco { includeConfig 'conf/test_falco.config' }
test_fastp { includeConfig 'conf/test_fastp.config' }
test { includeConfig 'conf/test.config' }
test_full { includeConfig 'conf/test_full.config' }
test_noprofiling { includeConfig 'conf/test_noprofiling.config' }
test_nopreprocessing { includeConfig 'conf/test_nopreprocessing.config' }
test_nothing { includeConfig 'conf/test_nothing.config' }
test_motus { includeConfig 'conf/test_motus.config' }
test_krakenuniq { includeConfig 'conf/test_krakenuniq.config' }
test_malt { includeConfig 'conf/test_malt.config' }
test_falco { includeConfig 'conf/test_falco.config' }
test_fastp { includeConfig 'conf/test_fastp.config' }
test_alternativepreprocessing { includeConfig 'conf/test_alternativepreprocessing.config' }
test_bbduk { includeConfig 'conf/test_bbduk.config' }
test_prinseqplusplus { includeConfig 'conf/test_prinseqplusplus.config' }

test_bbduk { includeConfig 'conf/test_bbduk.config' }
test_prinseqplusplus { includeConfig 'conf/test_prinseqplusplus.config' }
}

// Set default registry for Apptainer, Docker, Podman and Singularity independent of -profile
Expand Down
1 change: 0 additions & 1 deletion subworkflows/local/longread_preprocessing.nf
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ workflow LONGREAD_PREPROCESSING {
FASTQC_PROCESSED ( ch_processed_reads )
ch_versions = ch_versions.mix( FASTQC_PROCESSED.out.versions )
ch_multiqc_files = ch_multiqc_files.mix( FASTQC_PROCESSED.out.zip )

} else if (params.preprocessing_qc_tool == 'falco') {
FALCO_PROCESSED ( ch_processed_reads )
ch_versions = ch_versions.mix( FALCO_PROCESSED.out.versions )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ def toolCitationText() {
"Long read preprocessing was performed with:",
params.longread_adapterremoval_tool == "porechop_abi" ? "Porechop_ABI (Bonenfant et al. 2023)," : "",
params.longread_adapterremoval_tool == "porechop" ? "Porechop (Wick et al. 2017)," : "",
params.longread_filter_tool == "filtlong" ? "Filtlong (Wick 2021)," : "",
params.longread_filter_tool == "filtlong" ? "Filtlong (Wick 2021)." : "",
params.longread_filter_tool == "nanoq" ? "Nanoq (Steinig and Coin 2022)." : "",
].join(' ').trim()

Expand Down

0 comments on commit 0c647d1

Please sign in to comment.