Skip to content

Merge BAM_SOMATIC_VARIANT_CALLING_GATK subworkflows - #13335

Open
beatrizsavinhas wants to merge 69 commits into
masterfrom
merge-bam-somatic-variant-calling-gatk
Open

beatrizsavinhas wants to merge 69 commits into
masterfrom
merge-bam-somatic-variant-calling-gatk

Conversation

@beatrizsavinhas

@beatrizsavinhas beatrizsavinhas commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

PR checklist

Create BAM_SOMATIC_VARIANT_CALLING_GATK subworkflow merging the logic for BAM_TUMOR_NORMAL_SOMATIC_VARIANT_CALLING_GATK and BAM_TUMOR_ONLY_SOMATIC_VARIANT_CALLING_GATK. A single subworkflow capable of performing both analysis types reduces code duplication in pipelines that can run both tumor only and tumor-normal analyses.

  • This comment contains a description of changes (with reason).
  • If you've fixed a bug or added code that should be tested, add tests!
  • If you've added a new tool - have you followed the module conventions in the contribution docs
  • If necessary, include test data in your PR.
  • Remove all TODO statements.
  • Broadcast software version numbers to topic: versions - See version_topics
  • Follow the naming conventions.
  • Follow the parameters requirements.
  • Follow the input/output options guidelines.
  • Add a resource label
  • Use BioConda and BioContainers if possible to fulfil software requirements.
  • Ensure that the test works with either Docker / Singularity. Conda CI tests can be quite flaky:
    • For modules:
      • nf-core modules test <MODULE> --profile docker
      • nf-core modules test <MODULE> --profile singularity
      • nf-core modules test <MODULE> --profile conda
    • For subworkflows:
      • nf-core subworkflows test <SUBWORKFLOW> --profile docker
      • nf-core subworkflows test <SUBWORKFLOW> --profile singularity
      • nf-core subworkflows test <SUBWORKFLOW> --profile conda

@beatrizsavinhas beatrizsavinhas self-assigned this Oct 19, 2026
@github-actions

Copy link
Copy Markdown

This PR exceeds the recommended size of 1000 lines. Please make sure you are NOT addressing multiple issues with one PR. Note this PR might be rejected due to its size.

@github-actions github-actions Bot removed the size/l label Oct 21, 2026
@beatrizsavinhas
beatrizsavinhas marked this pull request as ready for review October 21, 2026 11:23
@github-actions github-actions Bot added size/l and removed size/xl labels Oct 26, 2026
@github-actions github-actions Bot added size/xl and removed size/l labels Oct 29, 2026
@github-actions

Copy link
Copy Markdown

This PR exceeds the recommended size of 1000 lines. Please make sure you are NOT addressing multiple issues with one PR. Note this PR might be rejected due to its size.

@beatrizsavinhas

beatrizsavinhas commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor Author

As per your suggestion @imsarath, the previous subworkflows have now been deprecated instead of removed.
While doing this, I found that the instructions for deprecating components needed adjustments for subworkflows so I opened this PR to address that: nf-core/website#4511

Comment on lines +95 to +113
ch_calculatecontamination_in = GATK4_GETPILEUPSUMMARIES.out.table
.map { meta, table ->
tuple(
meta.original_meta,
[(meta.id.endsWith('_tumor') ? 'tumor' : 'normal'): table]
)
}
.groupTuple()
// Ensure the correct order of the tables (tumor first, normal second)
.map { meta, table_maps ->

def tables = table_maps.sum([:])

tuple(
meta,
tables.tumor,
tables.normal ? tables.normal : []
)
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this logic could be improved and simplified! Any suggestions?

@FriederikeHanssen

Copy link
Copy Markdown
Contributor

I just had to pull apart the mutect2 subworkflow to move the filtering in into a different subworkflow so it can be shared with other callers, in case this is useful for you : nf-core/sarek#2349

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants