FAILURE MAP
← Case archive

FA-21161 / Assistive announcements / Open access

Released summaries survive into next quiet session · case 01

The announcement trace violates the stated quiet-session contract.

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

ROOT CAUSE

Fault site: pending.clear() elif e[0]=='reset': is implemented as pass elif e[0]=='reset':

VERIFIED REPAIR

Restore the stated transition: pending.clear() elif e[0]=='reset':

Unsuccessful approach: The attempted repair substitutes pending.pop(next(iter(pending)),None) if pending else None elif e[0]=='reset': and still violates a regression oracle.

Case contract

Quiet nesting is a counter. Enter increments; leave decrements without going negative. Ordinary messages during quiet replace a per-topic summary [latest,count], emergency speech always emits immediately. Final leave emits summaries in topic first-seen order as [topic,latest,count]. Remove-topic discards only that summary. Reset quiet silently discards backlog. Ordinary speech outside quiet emits directly with count1. Report output, nesting and pending summaries.

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):
    depth=0; pending={}; out=[]
    for e in events:
        if e[0]=='enter': depth+=1
        elif e[0]=='leave':
            was=depth; depth=max(0,depth-1)
            if was>0 and depth==0:
                out.extend([[k,v[0],v[1]] for k,v in pending.items()])
                pass
        elif e[0]=='reset': depth=0; pending.clear()
        elif e[0]=='remove': pending.pop(e[1],None)
        elif e[0]=='message':
            if e[3]=='emergency': out.append([e[1],e[2],1])
            elif depth:
                old=pending.get(e[1],['',0])
                pending[e[1]]=[e[2],old[1]+1]
            else: out.append([e[1],e[2],1])
    return [out,depth,[[k]+v for k,v in pending.items()]]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['enter'],['enter'],['message','a','first'*N,'normal'],['leave']]", "[['enter'],['message','z','old','normal'],['message','a','a'*N,'normal'],['message','z','new','normal'],['leave'],['enter'],['leave']]", "[['enter'],['message','a','urgent'*N,'emergency']]", "[['enter'],['message','a','urgent'*N,'emergency'],['message','b','deferred','normal'],['leave']]", "[['enter'],['message','a','a'*N,'normal'],['message','b','b','normal'],['remove','a']]", "[['enter'],['message','a','x'*N,'normal'],['reset']]", "[['message','a','direct'*N,'normal'],['leave'],['leave']]", "[['enter'],['message','a','x'*N,'normal'],['leave'],['leave']]"]
expected = {1: [[[], 1, [['a', 'first', 1]]], [[['z', 'new', 2], ['a', 'a', 1]], 0, []], [[['a', 'urgent', 1]], 1, []], [[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'direct', 1]], 0, []], [[['a', 'x', 1]], 0, []]], 2: [[[], 1, [['a', 'firstfirst', 1]]], [[['z', 'new', 2], ['a', 'aa', 1]], 0, []], [[['a', 'urgenturgent', 1]], 1, []], [[['a', 'urgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirect', 1]], 0, []], [[['a', 'xx', 1]], 0, []]], 3: [[[], 1, [['a', 'firstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaa', 1]], 0, []], [[['a', 'urgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirect', 1]], 0, []], [[['a', 'xxx', 1]], 0, []]], 4: [[[], 1, [['a', 'firstfirstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaaa', 1]], 0, []], [[['a', 'urgenturgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirectdirect', 1]], 0, []], [[['a', 'xxxx', 1]], 0, []]], 5: [[[], 1, [['a', 'firstfirstfirstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaaaa', 1]], 0, []], [[['a', 'urgenturgenturgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirectdirectdirect', 1]], 0, []], [[['a', 'xxxxx', 1]], 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[[], 1, [['a', 'first', 1]]][[], 1, [['a', 'first', 1]]]Passed
trace-2[[['z', 'new', 2], ['a', 'a', 1], ['z', 'new', 2], ['a', 'a', 1]], 0, [['z', 'new', 2], ['a', 'a', 1]]][[['z', 'new', 2], ['a', 'a', 1]], 0, []]Failed
trace-3[[['a', 'urgent', 1]], 1, []][[['a', 'urgent', 1]], 1, []]Passed
trace-4[[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, [['b', 'deferred', 1]]][[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []]Failed
trace-5[[], 1, [['b', 'b', 1]]][[], 1, [['b', 'b', 1]]]Passed
trace-6[[], 0, []][[], 0, []]Passed
trace-7[[['a', 'direct', 1]], 0, []][[['a', 'direct', 1]], 0, []]Passed
trace-8[[['a', 'x', 1]], 0, [['a', 'x', 1]]][[['a', 'x', 1]], 0, []]Failed

SHA-256 / 3931cf7c5b125702549cc2b48e675026fec5d55e52d8a6977fb29fe54bb55196

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(events):
    depth=0; pending={}; out=[]
    for e in events:
        if e[0]=='enter': depth+=1
        elif e[0]=='leave':
            was=depth; depth=max(0,depth-1)
            if was>0 and depth==0:
                out.extend([[k,v[0],v[1]] for k,v in pending.items()])
                pending.pop(next(iter(pending)),None) if pending else None
        elif e[0]=='reset': depth=0; pending.clear()
        elif e[0]=='remove': pending.pop(e[1],None)
        elif e[0]=='message':
            if e[3]=='emergency': out.append([e[1],e[2],1])
            elif depth:
                old=pending.get(e[1],['',0])
                pending[e[1]]=[e[2],old[1]+1]
            else: out.append([e[1],e[2],1])
    return [out,depth,[[k]+v for k,v in pending.items()]]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['enter'],['enter'],['message','a','first'*N,'normal'],['leave']]", "[['enter'],['message','z','old','normal'],['message','a','a'*N,'normal'],['message','z','new','normal'],['leave'],['enter'],['leave']]", "[['enter'],['message','a','urgent'*N,'emergency']]", "[['enter'],['message','a','urgent'*N,'emergency'],['message','b','deferred','normal'],['leave']]", "[['enter'],['message','a','a'*N,'normal'],['message','b','b','normal'],['remove','a']]", "[['enter'],['message','a','x'*N,'normal'],['reset']]", "[['message','a','direct'*N,'normal'],['leave'],['leave']]", "[['enter'],['message','a','x'*N,'normal'],['leave'],['leave']]"]
expected = {1: [[[], 1, [['a', 'first', 1]]], [[['z', 'new', 2], ['a', 'a', 1]], 0, []], [[['a', 'urgent', 1]], 1, []], [[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'direct', 1]], 0, []], [[['a', 'x', 1]], 0, []]], 2: [[[], 1, [['a', 'firstfirst', 1]]], [[['z', 'new', 2], ['a', 'aa', 1]], 0, []], [[['a', 'urgenturgent', 1]], 1, []], [[['a', 'urgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirect', 1]], 0, []], [[['a', 'xx', 1]], 0, []]], 3: [[[], 1, [['a', 'firstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaa', 1]], 0, []], [[['a', 'urgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirect', 1]], 0, []], [[['a', 'xxx', 1]], 0, []]], 4: [[[], 1, [['a', 'firstfirstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaaa', 1]], 0, []], [[['a', 'urgenturgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirectdirect', 1]], 0, []], [[['a', 'xxxx', 1]], 0, []]], 5: [[[], 1, [['a', 'firstfirstfirstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaaaa', 1]], 0, []], [[['a', 'urgenturgenturgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirectdirectdirect', 1]], 0, []], [[['a', 'xxxxx', 1]], 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[[], 1, [['a', 'first', 1]]][[], 1, [['a', 'first', 1]]]Passed
trace-2[[['z', 'new', 2], ['a', 'a', 1], ['a', 'a', 1]], 0, []][[['z', 'new', 2], ['a', 'a', 1]], 0, []]Failed
trace-3[[['a', 'urgent', 1]], 1, []][[['a', 'urgent', 1]], 1, []]Passed
trace-4[[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []][[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []]Passed
trace-5[[], 1, [['b', 'b', 1]]][[], 1, [['b', 'b', 1]]]Passed
trace-6[[], 0, []][[], 0, []]Passed
trace-7[[['a', 'direct', 1]], 0, []][[['a', 'direct', 1]], 0, []]Passed
trace-8[[['a', 'x', 1]], 0, []][[['a', 'x', 1]], 0, []]Passed

SHA-256 / 3e3e58b31617be30370d0b3cf75868c3c47a6b3ee7d6342c2f6c266bc4adf0c6

3 / The verified repair

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

N = 1
observations = []
def solve(events):
    depth=0; pending={}; out=[]
    for e in events:
        if e[0]=='enter': depth+=1
        elif e[0]=='leave':
            was=depth; depth=max(0,depth-1)
            if was>0 and depth==0:
                out.extend([[k,v[0],v[1]] for k,v in pending.items()])
                pending.clear()
        elif e[0]=='reset': depth=0; pending.clear()
        elif e[0]=='remove': pending.pop(e[1],None)
        elif e[0]=='message':
            if e[3]=='emergency': out.append([e[1],e[2],1])
            elif depth:
                old=pending.get(e[1],['',0])
                pending[e[1]]=[e[2],old[1]+1]
            else: out.append([e[1],e[2],1])
    return [out,depth,[[k]+v for k,v in pending.items()]]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = ["[['enter'],['enter'],['message','a','first'*N,'normal'],['leave']]", "[['enter'],['message','z','old','normal'],['message','a','a'*N,'normal'],['message','z','new','normal'],['leave'],['enter'],['leave']]", "[['enter'],['message','a','urgent'*N,'emergency']]", "[['enter'],['message','a','urgent'*N,'emergency'],['message','b','deferred','normal'],['leave']]", "[['enter'],['message','a','a'*N,'normal'],['message','b','b','normal'],['remove','a']]", "[['enter'],['message','a','x'*N,'normal'],['reset']]", "[['message','a','direct'*N,'normal'],['leave'],['leave']]", "[['enter'],['message','a','x'*N,'normal'],['leave'],['leave']]"]
expected = {1: [[[], 1, [['a', 'first', 1]]], [[['z', 'new', 2], ['a', 'a', 1]], 0, []], [[['a', 'urgent', 1]], 1, []], [[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'direct', 1]], 0, []], [[['a', 'x', 1]], 0, []]], 2: [[[], 1, [['a', 'firstfirst', 1]]], [[['z', 'new', 2], ['a', 'aa', 1]], 0, []], [[['a', 'urgenturgent', 1]], 1, []], [[['a', 'urgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirect', 1]], 0, []], [[['a', 'xx', 1]], 0, []]], 3: [[[], 1, [['a', 'firstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaa', 1]], 0, []], [[['a', 'urgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirect', 1]], 0, []], [[['a', 'xxx', 1]], 0, []]], 4: [[[], 1, [['a', 'firstfirstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaaa', 1]], 0, []], [[['a', 'urgenturgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirectdirect', 1]], 0, []], [[['a', 'xxxx', 1]], 0, []]], 5: [[[], 1, [['a', 'firstfirstfirstfirstfirst', 1]]], [[['z', 'new', 2], ['a', 'aaaaa', 1]], 0, []], [[['a', 'urgenturgenturgenturgenturgent', 1]], 1, []], [[['a', 'urgenturgenturgenturgenturgent', 1], ['b', 'deferred', 1]], 0, []], [[], 1, [['b', 'b', 1]]], [[], 0, []], [[['a', 'directdirectdirectdirectdirect', 1]], 0, []], [[['a', 'xxxxx', 1]], 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[[], 1, [['a', 'first', 1]]][[], 1, [['a', 'first', 1]]]Passed
trace-2[[['z', 'new', 2], ['a', 'a', 1]], 0, []][[['z', 'new', 2], ['a', 'a', 1]], 0, []]Passed
trace-3[[['a', 'urgent', 1]], 1, []][[['a', 'urgent', 1]], 1, []]Passed
trace-4[[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []][[['a', 'urgent', 1], ['b', 'deferred', 1]], 0, []]Passed
trace-5[[], 1, [['b', 'b', 1]]][[], 1, [['b', 'b', 1]]]Passed
trace-6[[], 0, []][[], 0, []]Passed
trace-7[[['a', 'direct', 1]], 0, []][[['a', 'direct', 1]], 0, []]Passed
trace-8[[['a', 'x', 1]], 0, []][[['a', 'x', 1]], 0, []]Passed

SHA-256 / 1031369a1981ec50576770d1159fc7128c41c2f8c089569f3676f2f11a9da2b7

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:25.954156+00:00.

Case digest / 05e6a69225be3cb2178b036be5f366da185d238cfbceff654f9ece80ea1b3c96