FAILURE MAP
← Case archive

FA-8466 / Assistive semantics / Open access

Accessible relationship resolution: One missing relationship erases all resolved targets · case 01

One missing relationship erases all resolved targets.

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

ROOT CAUSE

The missing operation uses `if ident not in registry: return []` where the contract requires `if ident not in registry: continue`.

THE FAILURE

The missing operation uses `if ident not in registry: return []` where the contract requires `if ident not in registry: continue`.

Unsuccessful approach: Stopping on a missing ID discards later valid targets.

Case contract

Resolve target IDs in caller order, deduplicate, and exclude self references, missing nodes, incompatible roles and hidden targets.

Why this case matters

A deterministic model of accessible relationship resolution; this isolates one interface invariant without requiring a browser.

1 / The failure

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

N = 1
observations = []
def solve(ids, registry, role, required_role, self_id):
    seen = set()
    result = []
    for ident in ids:
        if ident == self_id: continue
        if ident in seen: continue
        if ident not in registry: return []
        if registry[ident]['role'] != required_role: continue
        if registry[ident]['hidden']: continue
        seen.add(ident)
        result.append(ident)
    return result
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('self', solve(['self','a'], {'self':{'role':'panel','hidden':False},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
check('dedup', solve(['a','a','b'], {'a':{'role':'panel','hidden':False},'b':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a', 'b'])
check('missing', solve(['a','gone','b'], {'a':{'role':'panel','hidden':False},'b':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a', 'b'])
check('role', solve(['bad','a'], {'bad':{'role':'button','hidden':False},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
check('hidden', solve(['bad','a'], {'bad':{'role':'panel','hidden':True},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
check('parameterized relationship identity', solve([str(N)], {str(N):dict(role='panel',hidden=False)}, 'tab', 'panel', 'self'), [str(N)])
for repetition in range(N):
    check('repeat hidden', solve(['bad','a'], {'bad':{'role':'panel','hidden':True},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
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
self['a']['a']Passed
dedup['a', 'b']['a', 'b']Passed
missing[]['a', 'b']Failed
role['a']['a']Passed
hidden['a']['a']Passed
parameterized relationship identity['1']['1']Passed
repeat hidden['a']['a']Passed

SHA-256 / a64dfa7679dc9634cba8ab482c1c8b276da468799c42220eadba8d9ff15cddca

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(ids, registry, role, required_role, self_id):
    seen = set()
    result = []
    for ident in ids:
        if ident == self_id: continue
        if ident in seen: continue
        if ident not in registry: break
        if registry[ident]['role'] != required_role: continue
        if registry[ident]['hidden']: continue
        seen.add(ident)
        result.append(ident)
    return result
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('self', solve(['self','a'], {'self':{'role':'panel','hidden':False},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
check('dedup', solve(['a','a','b'], {'a':{'role':'panel','hidden':False},'b':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a', 'b'])
check('missing', solve(['a','gone','b'], {'a':{'role':'panel','hidden':False},'b':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a', 'b'])
check('role', solve(['bad','a'], {'bad':{'role':'button','hidden':False},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
check('hidden', solve(['bad','a'], {'bad':{'role':'panel','hidden':True},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
check('parameterized relationship identity', solve([str(N)], {str(N):dict(role='panel',hidden=False)}, 'tab', 'panel', 'self'), [str(N)])
for repetition in range(N):
    check('repeat hidden', solve(['bad','a'], {'bad':{'role':'panel','hidden':True},'a':{'role':'panel','hidden':False}}, 'tab', 'panel', 'self'), ['a'])
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
self['a']['a']Passed
dedup['a', 'b']['a', 'b']Passed
missing['a']['a', 'b']Failed
role['a']['a']Passed
hidden['a']['a']Passed
parameterized relationship identity['1']['1']Passed
repeat hidden['a']['a']Passed

SHA-256 / 6a4c24914ba3bd4a45395b6f0a968444127fed59671c7dc4f15fa7cf6a7dcec9

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

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

Case digest / 0770ba5df8d459458bce3807e8f2ab8899da66132d05cafffc2f8ed2a2f5fb43