Skip to content

fix(mito): match mitochondrial indels anywhere in their repeat - #277

Open
geiresx wants to merge 6 commits into
mainfrom
pgp/i411-mito-annotate
Open

geiresx wants to merge 6 commits into
mainfrom
pgp/i411-mito-annotate

Conversation

@geiresx

@geiresx geiresx commented Nov 20, 2026

Copy link
Copy Markdown
Owner

…st show in the annotation

The m.315 C>CC call is the m.310 T>TC insertion ClinVar and gnomAD list,
and m.308 CC>C is m.302 AC>A; today neither meets its record. A run whose
NuMT filter had no autosomal depth must say so in the table. Both tests
fail on main.

Bead: lin-35
Bead: lin-32
… a NuMT filter without depth

og mito annotate matched an indel only on its exact trimmed spelling, and
looked for ClinVar's record at most one base away, so m.315 C>CC never met
the m.310 T>TC record of the same poly-C insertion. When the exact spelling
finds nothing, both sides are now moved to the left end of their repeat on
the rCRS (embedded, GRCh38's chrM, MD5 c68f5267...) and matched there. An
exact match still wins, so every table that matched before is unchanged;
an allele whose REF is not the rCRS is not moved. ClinVar's chrM records
are now read whole, since a record can sit anywhere in its repeat.

--numt-default adds a '# numt' header line: the NuMT filter used a default
depth (0) and marked nothing. Without it the table is as before.

Bead: lin-35
Bead: lin-32
…mal depth

Step 20 already warned; it now passes --numt-default to og mito annotate
when neither mosdepth output nor AUTOSOMAL_COVERAGE gives a depth. The
Nextflow MITO_VARIANTS prints its message as a WARNING on stderr, and
MITO_VARIANTS_ANNOTATE passes --numt-default when mosdepth is not in
--tools, the one case where MITO_VARIANTS has no depth files. The
fake-docker case checks both paths and fails on main.

Bead: lin-32
@coderabbitai

coderabbitai Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

…epth

A successful task's stderr stays in its work directory, so the
MITO_VARIANTS WARNING never reached a Nextflow user. The workflow now
says it with log.warn when mito_variants runs without mosdepth.
left_allele trimmed first, so m.314 CG>CCG passed as C>CC on the rCRS
and met m.310's record. The docs now say the table writes the trimmed
spelling, not the moved one.
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