Skip to content

Fix some bugs in LeftAlignAndTrimVariants#9305

Open
kachulis wants to merge 6 commits intomasterfrom
ck_fix_left_align_and_trim_bug
Open

Fix some bugs in LeftAlignAndTrimVariants#9305
kachulis wants to merge 6 commits intomasterfrom
ck_fix_left_align_and_trim_bug

Conversation

@kachulis
Copy link
Contributor

A few different bugs in LeftAlignAndTrimVariants.

First, only indels will have their alleles trimmed. This PR changes this so that alleles trimming will happen for MNPs if possible as well.

Additionally, when multiple variants occur at the same location (either due to splitting multiallelics before running LeftAlignAndTrimVariants, or running with --split-multi-allelics), the tool will not currently behave correctly. Only the first variant processed at a location will be correctly left aligned and trimmed, other variants can only currently be left aligned up to the base following the left aligned start of the first processed variant in the set.

This PR fixes both issues, so that:

  1. MNPs will be trimmed when possible
  2. variants at the same location can be left aligned to different locations, and resorted as necessary.

Also adds tests of these types of edge cases.

@kachulis kachulis requested a review from jsotobroad December 19, 2025 19:39
@gatk-bot
Copy link

gatk-bot commented Jan 5, 2026

Github actions tests reported job failures from actions build 20723309215
Failures in the following jobs:

Test Type JDK Job ID Logs
conda 17.0.6+10 20723309215.3 logs

@gatk-bot
Copy link

gatk-bot commented Jan 5, 2026

Github actions tests reported job failures from actions build 20723608771
Failures in the following jobs:

Test Type JDK Job ID Logs
conda 17.0.6+10 20723608771.3 logs

@gatk-bot
Copy link

gatk-bot commented Jan 5, 2026

Github actions tests reported job failures from actions build 20724995214
Failures in the following jobs:

Test Type JDK Job ID Logs
conda 17.0.6+10 20724995214.3 logs

@gatk-bot
Copy link

gatk-bot commented Jan 7, 2026

Github actions tests reported job failures from actions build 20784893281
Failures in the following jobs:

Test Type JDK Job ID Logs
conda 17.0.6+10 20784893281.3 logs

@kachulis kachulis force-pushed the ck_fix_left_align_and_trim_bug branch from b3a96a8 to ca6a6c7 Compare February 12, 2026 20:48
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