FA-33591 / Menu interactions / Open access
Changing split-menu default rewrites the owning submenu label · case 01
Changing split-menu default rewrites the owning submenu label.
ROOT CAUSE
The split-button-menu model applies `p['default_label']` at its owner-label operation instead of the stipulated transformation.
VERIFIED REPAIR
Apply `p['owner_label']` at owner-label.
Unsuccessful approach: The attempted repair `p['owner_label']+' '+p['default_label']` still violates the owner-label oracle.
Case contract
Split menu owners have separate primary command and secondary submenu zones. Their default command is explicit, direct and independently available; the owner label is stable.
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 == 'primary':
return {'command':p['default'],'open':False}
if action == 'secondary':
return {'command':None,'open':True}
if action == 'zone':
return 'secondary' if p['x']>=p['divider'] else 'primary'
if action == 'default-availability':
return next((x['available'] for x in p['children'] if x['command']==p['default']),False)
if action == 'owner-label':
return p['default_label']
if action == 'primary-empty-default':
return {'command':p['default'],'open':p['default'] is None}
return {'error': 'unsupported menu operation'}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('primary contract', solve('primary', {'default':'run'+str(N)}), {'command':'run'+str(N),'open':False})
check('secondary contract', solve('secondary', {'default':'run'+str(N)}), {'command':None,'open':True})
check('zone contract', solve('zone', {'x':N+20,'divider':N+20}), 'secondary')
check('default-availability contract', solve('default-availability', {'default':'run','children':[{'command':'run','available':True},{'command':'other'+str(N),'available':False}]}), True)
check('owner-label contract', solve('owner-label', {'owner_label':'Export','default_label':'Format '+str(N)}), 'Export')
check('primary-empty-default contract', solve('primary-empty-default', {'default':None,'fallback':'first'+str(N)}), {'command':None,'open':True})
check('unknown operation', solve('unknown', {}), {'error': 'unsupported menu operation'})
check('other available alternatives do not enable default',solve('default-availability',{'default':'run','children':[{'command':'run','available':False},{'command':'other'+str(N),'available':True}]}),False)
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 |
|---|---|---|---|
| primary contract | {'command': 'run1', 'open': False} | {'command': 'run1', 'open': False} | Passed |
| secondary contract | {'command': None, 'open': True} | {'command': None, 'open': True} | Passed |
| zone contract | secondary | secondary | Passed |
| default-availability contract | True | True | Passed |
| owner-label contract | Format 1 | Export | Failed |
| primary-empty-default contract | {'command': None, 'open': True} | {'command': None, 'open': True} | Passed |
| unknown operation | {'error': 'unsupported menu operation'} | {'error': 'unsupported menu operation'} | Passed |
| other available alternatives do not enable default | False | False | Passed |
SHA-256 / 70ce77ddeae7684615d2be234244e4ace6bbf0214e9341b465f204e6659ee339
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 == 'primary':
return {'command':p['default'],'open':False}
if action == 'secondary':
return {'command':None,'open':True}
if action == 'zone':
return 'secondary' if p['x']>=p['divider'] else 'primary'
if action == 'default-availability':
return next((x['available'] for x in p['children'] if x['command']==p['default']),False)
if action == 'owner-label':
return p['owner_label']+' '+p['default_label']
if action == 'primary-empty-default':
return {'command':p['default'],'open':p['default'] is None}
return {'error': 'unsupported menu operation'}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('primary contract', solve('primary', {'default':'run'+str(N)}), {'command':'run'+str(N),'open':False})
check('secondary contract', solve('secondary', {'default':'run'+str(N)}), {'command':None,'open':True})
check('zone contract', solve('zone', {'x':N+20,'divider':N+20}), 'secondary')
check('default-availability contract', solve('default-availability', {'default':'run','children':[{'command':'run','available':True},{'command':'other'+str(N),'available':False}]}), True)
check('owner-label contract', solve('owner-label', {'owner_label':'Export','default_label':'Format '+str(N)}), 'Export')
check('primary-empty-default contract', solve('primary-empty-default', {'default':None,'fallback':'first'+str(N)}), {'command':None,'open':True})
check('unknown operation', solve('unknown', {}), {'error': 'unsupported menu operation'})
check('other available alternatives do not enable default',solve('default-availability',{'default':'run','children':[{'command':'run','available':False},{'command':'other'+str(N),'available':True}]}),False)
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 |
|---|---|---|---|
| primary contract | {'command': 'run1', 'open': False} | {'command': 'run1', 'open': False} | Passed |
| secondary contract | {'command': None, 'open': True} | {'command': None, 'open': True} | Passed |
| zone contract | secondary | secondary | Passed |
| default-availability contract | True | True | Passed |
| owner-label contract | Export Format 1 | Export | Failed |
| primary-empty-default contract | {'command': None, 'open': True} | {'command': None, 'open': True} | Passed |
| unknown operation | {'error': 'unsupported menu operation'} | {'error': 'unsupported menu operation'} | Passed |
| other available alternatives do not enable default | False | False | Passed |
SHA-256 / fc0c00d788af4c30e60919a49fc1220dc97f5f5af9a540f13d81aa6b3d96f9aa
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 == 'primary':
return {'command':p['default'],'open':False}
if action == 'secondary':
return {'command':None,'open':True}
if action == 'zone':
return 'secondary' if p['x']>=p['divider'] else 'primary'
if action == 'default-availability':
return next((x['available'] for x in p['children'] if x['command']==p['default']),False)
if action == 'owner-label':
return p['owner_label']
if action == 'primary-empty-default':
return {'command':p['default'],'open':p['default'] is None}
return {'error': 'unsupported menu operation'}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('primary contract', solve('primary', {'default':'run'+str(N)}), {'command':'run'+str(N),'open':False})
check('secondary contract', solve('secondary', {'default':'run'+str(N)}), {'command':None,'open':True})
check('zone contract', solve('zone', {'x':N+20,'divider':N+20}), 'secondary')
check('default-availability contract', solve('default-availability', {'default':'run','children':[{'command':'run','available':True},{'command':'other'+str(N),'available':False}]}), True)
check('owner-label contract', solve('owner-label', {'owner_label':'Export','default_label':'Format '+str(N)}), 'Export')
check('primary-empty-default contract', solve('primary-empty-default', {'default':None,'fallback':'first'+str(N)}), {'command':None,'open':True})
check('unknown operation', solve('unknown', {}), {'error': 'unsupported menu operation'})
check('other available alternatives do not enable default',solve('default-availability',{'default':'run','children':[{'command':'run','available':False},{'command':'other'+str(N),'available':True}]}),False)
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 |
|---|---|---|---|
| primary contract | {'command': 'run1', 'open': False} | {'command': 'run1', 'open': False} | Passed |
| secondary contract | {'command': None, 'open': True} | {'command': None, 'open': True} | Passed |
| zone contract | secondary | secondary | Passed |
| default-availability contract | True | True | Passed |
| owner-label contract | Export | Export | Passed |
| primary-empty-default contract | {'command': None, 'open': True} | {'command': None, 'open': True} | Passed |
| unknown operation | {'error': 'unsupported menu operation'} | {'error': 'unsupported menu operation'} | Passed |
| other available alternatives do not enable default | False | False | Passed |
SHA-256 / fb86a3bd6e0891954965545b9bc4605e6ed0d3e9e1fa62ae53591e36d962f4b7
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.828071+00:00.
Case digest / 22a9fbda5bf20b6c4e56481c3634ef16a843982c48de314145f124235773144d