Skip to content

Fix input_maf validation, publishDir glob, cache, schema, and add MAF input docs#432

Merged
FerriolCalvet merged 3 commits intominor-fixesfrom
copilot/sub-pr-431
Mar 14, 2026
Merged

Fix input_maf validation, publishDir glob, cache, schema, and add MAF input docs#432
FerriolCalvet merged 3 commits intominor-fixesfrom
copilot/sub-pr-431

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 13, 2026

Review feedback on the MAF input feature revealed several correctness issues: invalid publishDir globs silently dropping VCFs, disabled cache false on a non-deterministic process, misleading schema description, and no early validation when --input_maf is used without --use_custom_depths.

Fixes

  • conf/modules.config: "**{vcf}""*.vcf" for MAF2VCF and INPUTMAF2VCF — the original pattern is not a valid glob and published nothing
  • modules/local/downsample/mutations/main.nf: Restore cache false — downsampling is non-deterministic; cached results across reruns are incorrect by definition
  • workflows/deepcsa.nf: Add early guard that calls error when --input_maf is set without --use_custom_depths true, preventing silent fallback to INPUT_CHECK
if ( params.input_maf && !params.use_custom_depths ) {
    error "ERROR: '--input_maf' requires '--use_custom_depths true' and a matching '--custom_depths_table'. ..."
}
  • nextflow_schema.json: Rewrote input_maf description/help_text — removes the misleading "WILL OVERWRITE THE input.csv DATA" wording; accurately states the use_custom_depths dependency and that --input is still required

Tests

  • Added tests/test_data/test_mutations.maf (minimal non-deepCSA MAF)
  • Added nf-test case "Should fail when --input_maf is provided without --use_custom_depths" asserting workflow.failed and the expected error string
  • Added commented-out integration test template for the full input_maf + use_custom_depths path (requires a precomputed depths table as test asset)

Documentation

Added docs/usage.md section "MAF file as input (alternative input mode)" covering: when to use it, required parameter combination, MAF column requirements (deepCSA-origin vs. external), example invocation, and pipeline behaviour.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

…on, schema desc, and docs

Co-authored-by: FerriolCalvet <38539786+FerriolCalvet@users.noreply.github.com>
Copilot AI changed the title [WIP] Update input format and improve plots for deepCSA Fix input_maf validation, publishDir glob, cache, schema, and add MAF input docs Mar 13, 2026
Copilot AI requested a review from FerriolCalvet March 13, 2026 19:28
@FerriolCalvet FerriolCalvet marked this pull request as ready for review March 14, 2026 11:16
@FerriolCalvet FerriolCalvet merged commit d40ec03 into minor-fixes Mar 14, 2026
@FerriolCalvet FerriolCalvet deleted the copilot/sub-pr-431 branch March 14, 2026 11:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants