FA-33551 / Menu interactions / Open access
Menu restore follows a child that was moved to a different submenu owner · case 01
Menu restore follows a child that was moved to a different submenu owner.
ROOT CAUSE
The menu-cascade-restoration model applies `p['chain']` at its owner-edge operation instead of the stipulated transformation.
VERIFIED REPAIR
Apply `p['chain'][:next((i+1 for i,(a,b) in enumerate(zip(p['chain'],p['chain'][1:])) if p['parents'].get(b)!=a),len(p['chain']))]` at owner-edge.
Unsuccessful approach: The attempted repair `[x for x in p['chain'] if x in p['parents']]` still violates the owner-edge oracle.
Case contract
Restored cascades reopen only a contiguous valid prefix of menu owners. Missing, lazy, reparented or unavailable owners stop restoration; root identity and independent menu windows are retained.
Why this case matters
Cascading and context menus require coherent command and session state as content changes.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
import unicodedata
N = 1
observations = []
def solve(action, p):
if action == 'missing-prefix':
return p['chain'][:next((i for i,x in enumerate(p['chain']) if x not in p['live']),len(p['chain']))]
if action == 'lazy-boundary':
return p['chain'][:next((i+1 for i,x in enumerate(p['chain']) if x in p['lazy']),len(p['chain']))]
if action == 'owner-edge':
return p['chain']
if action == 'availability-prefix':
return p['chain'][:next((i for i,x in enumerate(p['chain']) if not p['available'].get(x,False)),len(p['chain']))]
if action == 'window-paths':
return {x['window']:x['path'] for x in p}
if action == 'owner-remap':
return [p['mapping'].get(x,x) for x in p['chain']]
return {'error': 'unsupported menu operation'}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('missing-prefix contract', solve('missing-prefix', {'chain':['root','gone','child'+str(N)],'live':['root','child'+str(N)]}), ['root'])
check('lazy-boundary contract', solve('lazy-boundary', {'chain':['root','lazy','child'+str(N)],'lazy':['lazy']}), ['root','lazy'])
check('owner-edge contract', solve('owner-edge', {'chain':['root','a','b'+str(N)],'parents':{'a':'root','b'+str(N):'other'}}), ['root','a'])
check('availability-prefix contract', solve('availability-prefix', {'chain':['root','locked','b'+str(N)],'available':{'root':True,'locked':False,'b'+str(N):True}}), ['root'])
check('window-paths contract', solve('window-paths', [{'window':N,'path':['root','a']},{'window':N+1,'path':['root','b']}]), {N:['root','a'],N+1:['root','b']})
check('owner-remap contract', solve('owner-remap', {'chain':['root','old'+str(N)],'mapping':{'old'+str(N):'new'+str(N)}}), ['root','new'+str(N)])
check('unknown operation', solve('unknown', {}), {'error': 'unsupported menu operation'})
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| missing-prefix contract | ['root'] | ['root'] | Passed |
| lazy-boundary contract | ['root', 'lazy'] | ['root', 'lazy'] | Passed |
| owner-edge contract | ['root', 'a', 'b1'] | ['root', 'a'] | Failed |
| availability-prefix contract | ['root'] | ['root'] | Passed |
| window-paths contract | {'1': ['root', 'a'], '2': ['root', 'b']} | {'1': ['root', 'a'], '2': ['root', 'b']} | Passed |
| owner-remap contract | ['root', 'new1'] | ['root', 'new1'] | Passed |
| unknown operation | {'error': 'unsupported menu operation'} | {'error': 'unsupported menu operation'} | Passed |
SHA-256 / 32f66da391ff200dc7d0b32d4c05d50dde5928b93dd025eeb7295b0572407185
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
import unicodedata
N = 1
observations = []
def solve(action, p):
if action == 'missing-prefix':
return p['chain'][:next((i for i,x in enumerate(p['chain']) if x not in p['live']),len(p['chain']))]
if action == 'lazy-boundary':
return p['chain'][:next((i+1 for i,x in enumerate(p['chain']) if x in p['lazy']),len(p['chain']))]
if action == 'owner-edge':
return [x for x in p['chain'] if x in p['parents']]
if action == 'availability-prefix':
return p['chain'][:next((i for i,x in enumerate(p['chain']) if not p['available'].get(x,False)),len(p['chain']))]
if action == 'window-paths':
return {x['window']:x['path'] for x in p}
if action == 'owner-remap':
return [p['mapping'].get(x,x) for x in p['chain']]
return {'error': 'unsupported menu operation'}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('missing-prefix contract', solve('missing-prefix', {'chain':['root','gone','child'+str(N)],'live':['root','child'+str(N)]}), ['root'])
check('lazy-boundary contract', solve('lazy-boundary', {'chain':['root','lazy','child'+str(N)],'lazy':['lazy']}), ['root','lazy'])
check('owner-edge contract', solve('owner-edge', {'chain':['root','a','b'+str(N)],'parents':{'a':'root','b'+str(N):'other'}}), ['root','a'])
check('availability-prefix contract', solve('availability-prefix', {'chain':['root','locked','b'+str(N)],'available':{'root':True,'locked':False,'b'+str(N):True}}), ['root'])
check('window-paths contract', solve('window-paths', [{'window':N,'path':['root','a']},{'window':N+1,'path':['root','b']}]), {N:['root','a'],N+1:['root','b']})
check('owner-remap contract', solve('owner-remap', {'chain':['root','old'+str(N)],'mapping':{'old'+str(N):'new'+str(N)}}), ['root','new'+str(N)])
check('unknown operation', solve('unknown', {}), {'error': 'unsupported menu operation'})
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| missing-prefix contract | ['root'] | ['root'] | Passed |
| lazy-boundary contract | ['root', 'lazy'] | ['root', 'lazy'] | Passed |
| owner-edge contract | ['a', 'b1'] | ['root', 'a'] | Failed |
| availability-prefix contract | ['root'] | ['root'] | Passed |
| window-paths contract | {'1': ['root', 'a'], '2': ['root', 'b']} | {'1': ['root', 'a'], '2': ['root', 'b']} | Passed |
| owner-remap contract | ['root', 'new1'] | ['root', 'new1'] | Passed |
| unknown operation | {'error': 'unsupported menu operation'} | {'error': 'unsupported menu operation'} | Passed |
SHA-256 / 9dc7f220e9efdc0dadfab2a8721e0a2adeae868b6a65c9a284ddab1bf7da0ce8
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
import math
import unicodedata
N = 1
observations = []
def solve(action, p):
if action == 'missing-prefix':
return p['chain'][:next((i for i,x in enumerate(p['chain']) if x not in p['live']),len(p['chain']))]
if action == 'lazy-boundary':
return p['chain'][:next((i+1 for i,x in enumerate(p['chain']) if x in p['lazy']),len(p['chain']))]
if action == 'owner-edge':
return p['chain'][:next((i+1 for i,(a,b) in enumerate(zip(p['chain'],p['chain'][1:])) if p['parents'].get(b)!=a),len(p['chain']))]
if action == 'availability-prefix':
return p['chain'][:next((i for i,x in enumerate(p['chain']) if not p['available'].get(x,False)),len(p['chain']))]
if action == 'window-paths':
return {x['window']:x['path'] for x in p}
if action == 'owner-remap':
return [p['mapping'].get(x,x) for x in p['chain']]
return {'error': 'unsupported menu operation'}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('missing-prefix contract', solve('missing-prefix', {'chain':['root','gone','child'+str(N)],'live':['root','child'+str(N)]}), ['root'])
check('lazy-boundary contract', solve('lazy-boundary', {'chain':['root','lazy','child'+str(N)],'lazy':['lazy']}), ['root','lazy'])
check('owner-edge contract', solve('owner-edge', {'chain':['root','a','b'+str(N)],'parents':{'a':'root','b'+str(N):'other'}}), ['root','a'])
check('availability-prefix contract', solve('availability-prefix', {'chain':['root','locked','b'+str(N)],'available':{'root':True,'locked':False,'b'+str(N):True}}), ['root'])
check('window-paths contract', solve('window-paths', [{'window':N,'path':['root','a']},{'window':N+1,'path':['root','b']}]), {N:['root','a'],N+1:['root','b']})
check('owner-remap contract', solve('owner-remap', {'chain':['root','old'+str(N)],'mapping':{'old'+str(N):'new'+str(N)}}), ['root','new'+str(N)])
check('unknown operation', solve('unknown', {}), {'error': 'unsupported menu operation'})
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| missing-prefix contract | ['root'] | ['root'] | Passed |
| lazy-boundary contract | ['root', 'lazy'] | ['root', 'lazy'] | Passed |
| owner-edge contract | ['root', 'a'] | ['root', 'a'] | Passed |
| availability-prefix contract | ['root'] | ['root'] | Passed |
| window-paths contract | {'1': ['root', 'a'], '2': ['root', 'b']} | {'1': ['root', 'a'], '2': ['root', 'b']} | Passed |
| owner-remap contract | ['root', 'new1'] | ['root', 'new1'] | Passed |
| unknown operation | {'error': 'unsupported menu operation'} | {'error': 'unsupported menu operation'} | Passed |
SHA-256 / 17bbaa67596812e66459ec71125ae4c492c44cf6255dba3a8e36ae05fdbab77e
Verification & scope
Offline supplied-valid-payload model; excludes DOM, keyboard, focus, selection, announcements and browser conformance. 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:42:23.459729+00:00.
Case digest / 8c7c1d14a9084398768f8b4a10080e47a770de25799e6b9a69db50062d5a2137