Skip to content

BUG: different annotation status for the same junction while collapsing junctions (STARlong, deterministic) #2695

Description

@alexdobin

Summary

STARlong (--runMode alignReads) aborts with a fatal EXIT_CODE_BUG during splice-junction collapsing:

EXITING because  of BUG: different annotation status for the same junction while collapsing junctions:1287415241 2508 0 1
...... FATAL ERROR, exiting

The crash is deterministic and data-triggered — re-running on the same input aborts on the same junction(s).

Version

STAR 2.7.11b (built from source at tag/commit b1edc12 "2.7.11b").

Where

source/OutSJ.cpp, Junction::collapseOneSJ() — the annot branch. The companion motif branch immediately above does not fire.

What's happening

The assertion fires when two junction entries with identical coordinates (same *start, same *gap) are collapsed but carry different annot values (0 = de-novo, 1 = annotated / sjdb). In my runs every crash was annot 0 vs 1, on a small set of distinct junctions, e.g.:

*start *gap annot1 annot2
1287415241 2508 0 1
346775474 6054 0 1
1907313072 2917 0 1

i.e. the same junction was detected both de-novo (annot=0) and via the annotated-junction (sjdb) path (annot=1), so by the time the global SJ table is sorted and collapsed the two entries disagree on annotation status, and collapseOneSJ exits instead of merging them.

Reproduction context

  • STARlong alignment of 10x Genomics 5′ single-cell RNA-seq reads (--soloType CB_UMI_Simple, --soloFeatures Gene GeneFull, --soloStrand Reverse).
  • GRCh38 (refdata-gex-GRCh38-2020-A) genome with a few custom transgene contigs appended; sjdb generated from the GENCODE GTF at genomeGenerate time.
  • Permissive long-read params: --seedSearchStartLmax 50 --seedPerReadNmax 100000 --seedPerWindowNmax 200 --alignTranscriptsPerReadNmax 100000 --alignTranscriptsPerWindowNmax 10000 --winAnchorMultimapNmax 200 --outFilterMismatchNmax 1000 --outFilterMismatchNoverReadLmax 0.1 --alignIntronMax 1000000, --outSAMtype None.
  • Affects a subset of samples; others run through the same genome/params/pipeline fine. (Full command available on request.)

Note

collapseOneSJ's own doc comment says it should "choose max overhangs, motif, annot", and the lenient reconciliation (*(isj1P+annotP) = *(isjP+annotP)) is present but commented out, replaced by the fatal exit. Reconciling annot to the max (annotated wins) would let these runs complete — flagging in case the assert was instead intended to catch a different upstream inconsistency in how annot is assigned along the de-novo vs sjdb detection paths.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions