FAILURE MAP
← Case archive

FA-20551 / Assistive announcements / Open access

Old producer updates the replacement context · case 01

The announcement trace violates the stated context-lease contract.

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

ROOT CAUSE

Fault site: if e[2]!=leases[e[1]][0]: continue is implemented as if e[2]>leases[e[1]][0]: continue

THE FAILURE

Fault site: if e[2]!=leases[e[1]][0]: continue is implemented as if e[2]>leases[e[1]][0]: continue

Unsuccessful approach: The attempted repair substitutes if e[2]<leases[e[1]][0]-1: continue and still violates a regression oracle.

Case contract

Announcement context leases map source to [epoch,text]. Register increments the source epoch and clears its text; publish requires a live source and matching epoch. Queue snapshots text plus source epoch. Drain speaks only still-live matching leases. Remove revokes source. Rename transfers a source lease and invalidates queued old-source messages. Report spoken and queue depth.

Why this case matters

Deterministic controlled model of assistive announcement delivery.

1 / The failure

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

N = 1
observations = []
def solve(events):
    leases={}; epochs={}; queue=[]; spoken=[]
    for e in events:
        if e[0]=='register':
            epochs[e[1]]=epochs.get(e[1],0)+1
            leases[e[1]]=[epochs[e[1]],'']
        elif e[0]=='publish':
            if e[1] not in leases: continue
            if e[2]>leases[e[1]][0]: continue
            leases[e[1]][1]=e[3]
        elif e[0]=='queue' and e[1] in leases:
            queue.append([e[1],leases[e[1]][0],leases[e[1]][1]])
        elif e[0]=='remove': leases.pop(e[1],None)
        elif e[0]=='rename' and e[1] in leases:
            leases[e[2]]=leases.pop(e[1])
        elif e[0]=='drain':
            for source,epoch,text in queue:
                if source not in leases: continue
                if leases[source][0]!=epoch: continue
                if text: spoken.append(text)
            queue.clear()
    return [spoken,len(queue),sorted((k,v) for k,v in leases.items())]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['register','a'],['publish','a',1,'old'*N],['queue','a'],['publish','a',1,'new'],['drain'],['drain']]", "[['register','a'],['publish','a',1,'old'],['queue','a'],['register','a'],['publish','a',1,'stale'*N],['queue','a'],['drain']]", "[['register','a'],['register','b'],['publish','b',1,'keep'*N],['remove','a'],['queue','b'],['drain']]", "[['register','a'],['publish','a',1,'hello'*N],['queue','a'],['rename','a','b'],['queue','b'],['drain']]", "[['register','a'],['queue','a'],['drain'],['publish','a',1,'  x  '*N],['queue','a'],['drain']]", "[['publish','missing',1,'x'*N],['remove','missing'],['drain']]", "[['register','a'],['publish','a',1,'x'*N],['queue','a'],['remove','a'],['drain']]"]
expected = {1: [[['old'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keep'], 0, [('b', [1, 'keep'])]], [['hello'], 0, [('b', [1, 'hello'])]], [['  x  '], 0, [('a', [1, '  x  '])]], [[], 0, []], [[], 0, []]], 2: [[['oldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeep'], 0, [('b', [1, 'keepkeep'])]], [['hellohello'], 0, [('b', [1, 'hellohello'])]], [['  x    x  '], 0, [('a', [1, '  x    x  '])]], [[], 0, []], [[], 0, []]], 3: [[['oldoldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeepkeep'], 0, [('b', [1, 'keepkeepkeep'])]], [['hellohellohello'], 0, [('b', [1, 'hellohellohello'])]], [['  x    x    x  '], 0, [('a', [1, '  x    x    x  '])]], [[], 0, []], [[], 0, []]], 4: [[['oldoldoldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeepkeepkeep'], 0, [('b', [1, 'keepkeepkeepkeep'])]], [['hellohellohellohello'], 0, [('b', [1, 'hellohellohellohello'])]], [['  x    x    x    x  '], 0, [('a', [1, '  x    x    x    x  '])]], [[], 0, []], [[], 0, []]], 5: [[['oldoldoldoldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeepkeepkeepkeep'], 0, [('b', [1, 'keepkeepkeepkeepkeep'])]], [['hellohellohellohellohello'], 0, [('b', [1, 'hellohellohellohellohello'])]], [['  x    x    x    x    x  '], 0, [('a', [1, '  x    x    x    x    x  '])]], [[], 0, []], [[], 0, []]]}[N]
for i, expression in enumerate(fixtures):
    check("trace-"+str(i+1), solve(eval(expression)), expected[i])
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
trace-1[['old'], 0, [['a', [1, 'new']]]][['old'], 0, [['a', [1, 'new']]]]Passed
trace-2[['stale'], 0, [['a', [2, 'stale']]]][[], 0, [['a', [2, '']]]]Failed
trace-3[['keep'], 0, [['b', [1, 'keep']]]][['keep'], 0, [['b', [1, 'keep']]]]Passed
trace-4[['hello'], 0, [['b', [1, 'hello']]]][['hello'], 0, [['b', [1, 'hello']]]]Passed
trace-5[[' x '], 0, [['a', [1, ' x ']]]][[' x '], 0, [['a', [1, ' x ']]]]Passed
trace-6[[], 0, []][[], 0, []]Passed
trace-7[[], 0, []][[], 0, []]Passed

SHA-256 / 9995d8a774f156e0b3fffbef726b179457202d447768262f5bf5c4c36f18a8cc

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(events):
    leases={}; epochs={}; queue=[]; spoken=[]
    for e in events:
        if e[0]=='register':
            epochs[e[1]]=epochs.get(e[1],0)+1
            leases[e[1]]=[epochs[e[1]],'']
        elif e[0]=='publish':
            if e[1] not in leases: continue
            if e[2]<leases[e[1]][0]-1: continue
            leases[e[1]][1]=e[3]
        elif e[0]=='queue' and e[1] in leases:
            queue.append([e[1],leases[e[1]][0],leases[e[1]][1]])
        elif e[0]=='remove': leases.pop(e[1],None)
        elif e[0]=='rename' and e[1] in leases:
            leases[e[2]]=leases.pop(e[1])
        elif e[0]=='drain':
            for source,epoch,text in queue:
                if source not in leases: continue
                if leases[source][0]!=epoch: continue
                if text: spoken.append(text)
            queue.clear()
    return [spoken,len(queue),sorted((k,v) for k,v in leases.items())]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['register','a'],['publish','a',1,'old'*N],['queue','a'],['publish','a',1,'new'],['drain'],['drain']]", "[['register','a'],['publish','a',1,'old'],['queue','a'],['register','a'],['publish','a',1,'stale'*N],['queue','a'],['drain']]", "[['register','a'],['register','b'],['publish','b',1,'keep'*N],['remove','a'],['queue','b'],['drain']]", "[['register','a'],['publish','a',1,'hello'*N],['queue','a'],['rename','a','b'],['queue','b'],['drain']]", "[['register','a'],['queue','a'],['drain'],['publish','a',1,'  x  '*N],['queue','a'],['drain']]", "[['publish','missing',1,'x'*N],['remove','missing'],['drain']]", "[['register','a'],['publish','a',1,'x'*N],['queue','a'],['remove','a'],['drain']]"]
expected = {1: [[['old'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keep'], 0, [('b', [1, 'keep'])]], [['hello'], 0, [('b', [1, 'hello'])]], [['  x  '], 0, [('a', [1, '  x  '])]], [[], 0, []], [[], 0, []]], 2: [[['oldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeep'], 0, [('b', [1, 'keepkeep'])]], [['hellohello'], 0, [('b', [1, 'hellohello'])]], [['  x    x  '], 0, [('a', [1, '  x    x  '])]], [[], 0, []], [[], 0, []]], 3: [[['oldoldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeepkeep'], 0, [('b', [1, 'keepkeepkeep'])]], [['hellohellohello'], 0, [('b', [1, 'hellohellohello'])]], [['  x    x    x  '], 0, [('a', [1, '  x    x    x  '])]], [[], 0, []], [[], 0, []]], 4: [[['oldoldoldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeepkeepkeep'], 0, [('b', [1, 'keepkeepkeepkeep'])]], [['hellohellohellohello'], 0, [('b', [1, 'hellohellohellohello'])]], [['  x    x    x    x  '], 0, [('a', [1, '  x    x    x    x  '])]], [[], 0, []], [[], 0, []]], 5: [[['oldoldoldoldold'], 0, [('a', [1, 'new'])]], [[], 0, [('a', [2, ''])]], [['keepkeepkeepkeepkeep'], 0, [('b', [1, 'keepkeepkeepkeepkeep'])]], [['hellohellohellohellohello'], 0, [('b', [1, 'hellohellohellohellohello'])]], [['  x    x    x    x    x  '], 0, [('a', [1, '  x    x    x    x    x  '])]], [[], 0, []], [[], 0, []]]}[N]
for i, expression in enumerate(fixtures):
    check("trace-"+str(i+1), solve(eval(expression)), expected[i])
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
trace-1[['old'], 0, [['a', [1, 'new']]]][['old'], 0, [['a', [1, 'new']]]]Passed
trace-2[['stale'], 0, [['a', [2, 'stale']]]][[], 0, [['a', [2, '']]]]Failed
trace-3[['keep'], 0, [['b', [1, 'keep']]]][['keep'], 0, [['b', [1, 'keep']]]]Passed
trace-4[['hello'], 0, [['b', [1, 'hello']]]][['hello'], 0, [['b', [1, 'hello']]]]Passed
trace-5[[' x '], 0, [['a', [1, ' x ']]]][[' x '], 0, [['a', [1, ' x ']]]]Passed
trace-6[[], 0, []][[], 0, []]Passed
trace-7[[], 0, []][[], 0, []]Passed

SHA-256 / dd1e0a5e0fc6aea6fae24471b066e5d50a1ce714e5346bd32d12baedc9b5f036

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 7 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.

Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.

Member access is invitation-based. Sign in with your invited account to inspect the repair.

Sign in to the archive ↗

Verification & scope

Stipulated bounded policy, not a browser, speech engine, platform API, or standards conformance claim. 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:40:20.463005+00:00.

Case digest / 611bda3afae0d056230c0c2e471afb287f2de067e9ab689053e169dff213c042