FAILURE MAP
← Case archive

FA-12576 / Genomic coordinate mapping / Open access

Lifted coordinates discard ambiguous chain mappings · case 01

Lifted coordinates discard ambiguous chain mappings.

Verified by executionVariant 1 · 6 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

First chain hit is returned even when alternative mappings disagree.

VERIFIED REPAIR

Return a coordinate only when the set of destination reference/base pairs has cardinality one.

Unsuccessful approach: Rejecting multiple hits discards redundant chains that agree exactly.

Case contract

Synthetic chain hits are [contig,base] mappings for one source base; return the unique destination pair or None.

Why this case matters

An abstract offline coordinate model isolates this software mapping defect; it does not model biological interpretation.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(hits):
    return hits[0] if hits else None
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('conflicting positions',solve([['a',N],['a',N+1]]),None)
check('redundant chains',solve([['a',N],['a',N]]),['a',N])
check('different contigs',solve([['a',N],['b',N]]),None)
check('single hit',solve([['b',N]]),['b',N])
check('no hit',solve([]),None)
check('three agreeing',solve([['a',N]]*3),['a',N])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
conflicting positions['a', 1]NoneFailed
redundant chains['a', 1]['a', 1]Passed
different contigs['a', 1]NoneFailed
single hit['b', 1]['b', 1]Passed
no hitNoneNonePassed
three agreeing['a', 1]['a', 1]Passed

SHA-256 / 2b99121db99ff4b2aa7fc5187133dadb476352eeb162e909fb109a2af63fde31

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(hits):
    return hits[0] if len(hits)==1 else None
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('conflicting positions',solve([['a',N],['a',N+1]]),None)
check('redundant chains',solve([['a',N],['a',N]]),['a',N])
check('different contigs',solve([['a',N],['b',N]]),None)
check('single hit',solve([['b',N]]),['b',N])
check('no hit',solve([]),None)
check('three agreeing',solve([['a',N]]*3),['a',N])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
conflicting positionsNoneNonePassed
redundant chainsNone['a', 1]Failed
different contigsNoneNonePassed
single hit['b', 1]['b', 1]Passed
no hitNoneNonePassed
three agreeingNone['a', 1]Failed

SHA-256 / 6825a196308eac056d771402d4bec673cca05124e7a0f58724b9ab7cbba8a562

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(hits):
    unique=set(tuple(x) for x in hits)
    return list(next(iter(unique))) if len(unique)==1 else None
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('conflicting positions',solve([['a',N],['a',N+1]]),None)
check('redundant chains',solve([['a',N],['a',N]]),['a',N])
check('different contigs',solve([['a',N],['b',N]]),None)
check('single hit',solve([['b',N]]),['b',N])
check('no hit',solve([]),None)
check('three agreeing',solve([['a',N]]*3),['a',N])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
conflicting positionsNoneNonePassed
redundant chains['a', 1]['a', 1]Passed
different contigsNoneNonePassed
single hit['b', 1]['b', 1]Passed
no hitNoneNonePassed
three agreeing['a', 1]['a', 1]Passed

SHA-256 / 78f0b3a143617a4c1b9015f266a0b81c8e07233ba0b5d37f0a32898deab3c315

Verification & scope

Synthetic coordinate fixtures only; not a production annotation or alignment implementation. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.

Observations recorded using Python 3.12.14 at 2026-09-29T14:38:58.144713+00:00.

Case digest / 4a96ee3dc8df796aa12865f63e7165e275162527126c6d3e308a471619c8230b