Skip to content

--fastqc is silently ignored on the specialty modes and the interleaved-uBAM paired arm #421

Description

@FelixKrueger

--fastqc is accepted but silently ignored on five dispatch paths: --hardtrim5, --hardtrim3, --clock, --implicon, and paired FASTQ output from a single interleaved uBAM. The run exits 0, writes its normal output, and produces no QC report and no message explaining why. Nothing in the CLI rejects the combination either, so a wrapper that passes --fastqc unconditionally gets no QC and no warning.

Reproduced at dev @ 3008b37:

$ trim_galore --hardtrim5 20 --fastqc a.fastq   # exit 0
a.20bp_5prime.fq                                # no _fastqc.zip, no _fastqc.html
$ ... 2>&1 | grep -ci fastqc
0                                               # not mentioned at all

Same on --clock --paired --fastqc and on --paired --fastqc one_interleaved.bam.

Either wiring FastQC into these arms or refusing the combination at the CLI would be an improvement on silence; refusing is the smaller change and matches how the other unsupported combinations behave.

AI-assisted analysis

Found independently by both plan reviewers while reviewing #414's tripwire plan, then reproduced directly.

fastqc::run is called from main.rs:1459 (run_single_file), :1778/:1784/:1796 (run_paired, including the --passthrough carrier), :2242 (run_ubam_output_single), :2399 (run_ubam_output_paired_two_files), :2522 (run_ubam_output_paired_single_file), plus the cli.fastqc pass-through into the clump_only drivers. src/specialty.rs contains no reference to it, and run_paired_ubam_single_file (main.rs:1810-2003) has none — hence the five arms. A grep over cli.rs finds no conflict rejecting the combination.

The gate at each call site is cli.fastqc || cli.fastqc_args.is_some(), so --fastqc_args alone also triggers FastQC on the supported arms — worth preserving in whichever direction this is fixed.

This surfaced as a plan defect first: #414's tripwire asserted that a --fastqc run must produce FastQC output, which is false on these five arms, so the assertion is now scoped to the arms where fastqc::run is reachable. That scoping is a workaround for the behaviour, not a fix for it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions