Closed SPPearce closed 3 months ago
nf-core lint
overall result: Passed :white_check_mark: :warning:Posted for pipeline commit 916a1bf
+| ✅ 169 tests passed |+
#| ❔ 8 tests were ignored |#
!| ❗ 4 tests had warnings |!
@znorgaard can you verify that the bwa index
process is skipped when (1) run a second time, and (2) manually copied and run for a first time?
@nh13, This seems to be working as expected.
The goal of this PR seems to be to skip generation of the files if they're explicitly provided as parameters. I don't think we're expecting it to skip generation of the files if the files are found to exist in the same directory as the reference.
I'm using Nextflow version 24.04.2, with this branch (prepare_genome_when).
OUTDIR="/full/path/to/output"
nextflow run main.nf \
-profile test,docker \
--outdir ${OUTDIR} \
--save_reference
Completes successfully and includes the reference index files and dict.
nextflow run main.nf \
-profile test,docker \
-resume \
--outdir ${OUTDIR} \
--save_reference
Completes successfully and everything except MULTIQC is pulled from cache.
nextflow run main.nf \
-profile test,docker \
--outdir ${OUTDIR} \
--bwa ${OUTDIR}/genome/bwa/ \
--dict ${OUTDIR}/genome/chr17.fa.dict \
--fasta_fai ${OUTDIR}/genome/chr17.fa.fai
Skips creation of the reference index files and dict using the provided paths instead.
If you move the files and provide updated paths it also behaves as expected, still skipping the creation of those resources.
mv ${OUTDIR}/genome ${OUTDIR}/my-custom-genome
nextflow run main.nf \
-profile test,docker \
--outdir ${OUTDIR} \
--bwa ${OUTDIR}/my-custom-genome/bwa/ \
--dict ${OUTDIR}/my-custom-genome/chr17.fa.dict \
--fasta_fai ${OUTDIR}/my-custom-genome/chr17.fa.fai
If this doesn't cover the specific test case you're thinking of, I'm happy to run more.
Yes, this will only check if the command line arguments are given, and seems to be working at that.
As noted in #56 , the BWA index generation happens every time (and doesn't seem to cache, which makes it even more annoying). This PR adds when conditions to the prepare genome steps so they don't run if the appropriate parameters are passed.