{"abstract":"Cleared text attributes are serialized as null values.","category":"Accessibility interaction semantics","checks":7,"contract":"Input [length,default_attributes,spans] where spans are [start,end,attributes,priority]. Clamp endpoints to [0,length], discard empty/reversed spans. At each character position merge active spans over defaults by increasing priority, preserving input tie order; None attribute removes that attribute. Build maximal equal adjacent runs [start,end,attributes]. Zero length returns empty. Offsets are codepoints. Dictionary values are strings or None.","evaluation_group":"s3-accessibility-text-attribute-runs","failed_approach":"The local repair substitutes if value is None: attrs[key] = '' but still mishandles the regression fixtures.","family":"s3-accessibility-text-attribute-runs-attribute-delete","id":"FA-53776","implementations":{"attempt":{"sha256":"2ed0911ec4b1b60b2da810d8c2943a5ec5a49824857ec9c312ece07347695a7f","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(data):\n    length,defaults,spans = data\n    points = []\n    for pos in range(length):\n        attrs = dict(defaults)\n        active = [(p,i,a) for i,(s,e,a,p) in enumerate(spans) if max(0,s) <= pos < min(length,e)]\n        for priority,idx,updates in sorted(active,key=lambda x:(x[0],x[1])):\n            for key,value in updates.items():\n                if value is None: attrs[key] = ''\n                else: attrs[key] = value\n        points.append(attrs)\n    result = []\n    for pos,attrs in enumerate(points):\n        if result and result[-1][2] == attrs: result[-1][1] = pos+1\n        else: result.append([pos,pos+1,attrs])\n    return result\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('contract fixture 1', solve([N+2,{'lang':'en'},[[0,N,{'weight':'bold'},1],[1,N+1,{'lang':'fr'},2]]],), [[0,1,{'lang':'en','weight':'bold'}]]+([[1,N,{'lang':'fr','weight':'bold'}]] if N>1 else [])+[[N,N+1,{'lang':'fr'}],[N+1,N+2,{'lang':'en'}]])\ncheck('contract fixture 2', solve([3,{'lang':'en','color':'red'},[[0,3,{'lang':None},1],[1,2,{'color':'blue'},2]]],), [[0,1,{'color':'red'}],[1,2,{'color':'blue'}],[2,3,{'color':'red'}]])\ncheck('contract fixture 3', solve([3,{},[[0,3,{'x':'high'},5],[0,3,{'x':'low'},1]]],), [[0,3,{'x':'high'}]])\ncheck('contract fixture 4', solve([3,{},[[0,3,{'x':'first'},1],[0,3,{'x':'last'},1]]],), [[0,3,{'x':'last'}]])\ncheck('contract fixture 5', solve([3,{},[[-3,2,{'x':'a'},0],[2,8,{'x':'a'},0],[2,1,{'x':'bad'},9]]],), [[0,3,{'x':'a'}]])\ncheck('contract fixture 6', solve([0,{'lang':'en'},[]],), [])\ncheck('contract fixture 7', solve([2,{'lang':'en'},[[0,1,{},0]]],), [[0,2,{'lang':'en'}]])\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"c8b80caf3acdf9941d09b5b781ed377918241d635fcdfbe770a7d35bcbe0fe97","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(data):\n    length,defaults,spans = data\n    points = []\n    for pos in range(length):\n        attrs = dict(defaults)\n        active = [(p,i,a) for i,(s,e,a,p) in enumerate(spans) if max(0,s) <= pos < min(length,e)]\n        for priority,idx,updates in sorted(active,key=lambda x:(x[0],x[1])):\n            for key,value in updates.items():\n                if value is None: attrs[key] = None\n                else: attrs[key] = value\n        points.append(attrs)\n    result = []\n    for pos,attrs in enumerate(points):\n        if result and result[-1][2] == attrs: result[-1][1] = pos+1\n        else: result.append([pos,pos+1,attrs])\n    return result\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('contract fixture 1', solve([N+2,{'lang':'en'},[[0,N,{'weight':'bold'},1],[1,N+1,{'lang':'fr'},2]]],), [[0,1,{'lang':'en','weight':'bold'}]]+([[1,N,{'lang':'fr','weight':'bold'}]] if N>1 else [])+[[N,N+1,{'lang':'fr'}],[N+1,N+2,{'lang':'en'}]])\ncheck('contract fixture 2', solve([3,{'lang':'en','color':'red'},[[0,3,{'lang':None},1],[1,2,{'color':'blue'},2]]],), [[0,1,{'color':'red'}],[1,2,{'color':'blue'}],[2,3,{'color':'red'}]])\ncheck('contract fixture 3', solve([3,{},[[0,3,{'x':'high'},5],[0,3,{'x':'low'},1]]],), [[0,3,{'x':'high'}]])\ncheck('contract fixture 4', solve([3,{},[[0,3,{'x':'first'},1],[0,3,{'x':'last'},1]]],), [[0,3,{'x':'last'}]])\ncheck('contract fixture 5', solve([3,{},[[-3,2,{'x':'a'},0],[2,8,{'x':'a'},0],[2,1,{'x':'bad'},9]]],), [[0,3,{'x':'a'}]])\ncheck('contract fixture 6', solve([0,{'lang':'en'},[]],), [])\ncheck('contract fixture 7', solve([2,{'lang':'en'},[[0,1,{},0]]],), [[0,2,{'lang':'en'}]])\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"fixed":{"sha256":"32ebd0cffac1988cd1602c91ab559cbf8a7e675b59a345a2c31984585f7ebbf5","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(data):\n    length,defaults,spans = data\n    points = []\n    for pos in range(length):\n        attrs = dict(defaults)\n        active = [(p,i,a) for i,(s,e,a,p) in enumerate(spans) if max(0,s) <= pos < min(length,e)]\n        for priority,idx,updates in sorted(active,key=lambda x:(x[0],x[1])):\n            for key,value in updates.items():\n                if value is None: attrs.pop(key,None)\n                else: attrs[key] = value\n        points.append(attrs)\n    result = []\n    for pos,attrs in enumerate(points):\n        if result and result[-1][2] == attrs: result[-1][1] = pos+1\n        else: result.append([pos,pos+1,attrs])\n    return result\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('contract fixture 1', solve([N+2,{'lang':'en'},[[0,N,{'weight':'bold'},1],[1,N+1,{'lang':'fr'},2]]],), [[0,1,{'lang':'en','weight':'bold'}]]+([[1,N,{'lang':'fr','weight':'bold'}]] if N>1 else [])+[[N,N+1,{'lang':'fr'}],[N+1,N+2,{'lang':'en'}]])\ncheck('contract fixture 2', solve([3,{'lang':'en','color':'red'},[[0,3,{'lang':None},1],[1,2,{'color':'blue'},2]]],), [[0,1,{'color':'red'}],[1,2,{'color':'blue'}],[2,3,{'color':'red'}]])\ncheck('contract fixture 3', solve([3,{},[[0,3,{'x':'high'},5],[0,3,{'x':'low'},1]]],), [[0,3,{'x':'high'}]])\ncheck('contract fixture 4', solve([3,{},[[0,3,{'x':'first'},1],[0,3,{'x':'last'},1]]],), [[0,3,{'x':'last'}]])\ncheck('contract fixture 5', solve([3,{},[[-3,2,{'x':'a'},0],[2,8,{'x':'a'},0],[2,1,{'x':'bad'},9]]],), [[0,3,{'x':'a'}]])\ncheck('contract fixture 6', solve([0,{'lang':'en'},[]],), [])\ncheck('contract fixture 7', solve([2,{'lang':'en'},[[0,1,{},0]]],), [[0,2,{'lang':'en'}]])\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"Stipulated finite adapter contract, not a claim of platform accessibility or ARIA 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.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"s3-accessibility-text-attribute-runs-attribute-delete","generated_at":"2026-09-29T14:45:42.069258+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Offline accessibility bridge model with explicit policy; useful for testing semantic API adapters independently of browser implementations.","repair":"Apply the exact contract at the attribute delete decision: if value is None: attrs.pop(key,None)","root_cause":"The attribute delete decision in the text attribute runs adapter violates its declared contract.","sha256":"f6a5df4fb6b67126496cbdf1d0b0ef28dee3e5b7a93f1915528253d5cb3045fd","title":"Cleared text attributes are serialized as null values · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":41.867,"exit_code":1,"observations":[{"actual":[[0,1,{"lang":"en","weight":"bold"}],[1,2,{"lang":"fr"}],[2,3,{"lang":"en"}]],"check":"contract fixture 1","expected":[[0,1,{"lang":"en","weight":"bold"}],[1,2,{"lang":"fr"}],[2,3,{"lang":"en"}]],"passed":true},{"actual":[[0,1,{"color":"red","lang":""}],[1,2,{"color":"blue","lang":""}],[2,3,{"color":"red","lang":""}]],"check":"contract fixture 2","expected":[[0,1,{"color":"red"}],[1,2,{"color":"blue"}],[2,3,{"color":"red"}]],"passed":false},{"actual":[[0,3,{"x":"high"}]],"check":"contract fixture 3","expected":[[0,3,{"x":"high"}]],"passed":true},{"actual":[[0,3,{"x":"last"}]],"check":"contract fixture 4","expected":[[0,3,{"x":"last"}]],"passed":true},{"actual":[[0,3,{"x":"a"}]],"check":"contract fixture 5","expected":[[0,3,{"x":"a"}]],"passed":true},{"actual":[],"check":"contract fixture 6","expected":[],"passed":true},{"actual":[[0,2,{"lang":"en"}]],"check":"contract fixture 7","expected":[[0,2,{"lang":"en"}]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"contract fixture 1\", \"actual\": [[0, 1, {\"lang\": \"en\", \"weight\": \"bold\"}], [1, 2, {\"lang\": \"fr\"}], [2, 3, {\"lang\": \"en\"}]], \"expected\": [[0, 1, {\"lang\": \"en\", \"weight\": \"bold\"}], [1, 2, {\"lang\": \"fr\"}], [2, 3, {\"lang\": \"en\"}]], \"passed\": true}, {\"check\": \"contract fixture 2\", \"actual\": [[0, 1, {\"lang\": \"\", \"color\": \"red\"}], [1, 2, {\"lang\": \"\", \"color\": \"blue\"}], [2, 3, {\"lang\": \"\", \"color\": \"red\"}]], \"expected\": [[0, 1, {\"color\": \"red\"}], [1, 2, {\"color\": \"blue\"}], [2, 3, {\"color\": \"red\"}]], \"passed\": false}, {\"check\": \"contract fixture 3\", \"actual\": [[0, 3, {\"x\": \"high\"}]], \"expected\": [[0, 3, {\"x\": \"high\"}]], \"passed\": true}, {\"check\": \"contract fixture 4\", \"actual\": [[0, 3, {\"x\": \"last\"}]], \"expected\": [[0, 3, {\"x\": \"last\"}]], \"passed\": true}, {\"check\": \"contract fixture 5\", \"actual\": [[0, 3, {\"x\": \"a\"}]], \"expected\": [[0, 3, {\"x\": \"a\"}]], \"passed\": true}, {\"check\": \"contract fixture 6\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"contract fixture 7\", \"actual\": [[0, 2, {\"lang\": \"en\"}]], \"expected\": [[0, 2, {\"lang\": \"en\"}]], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":40.585,"exit_code":1,"observations":[{"actual":[[0,1,{"lang":"en","weight":"bold"}],[1,2,{"lang":"fr"}],[2,3,{"lang":"en"}]],"check":"contract fixture 1","expected":[[0,1,{"lang":"en","weight":"bold"}],[1,2,{"lang":"fr"}],[2,3,{"lang":"en"}]],"passed":true},{"actual":[[0,1,{"color":"red","lang":null}],[1,2,{"color":"blue","lang":null}],[2,3,{"color":"red","lang":null}]],"check":"contract fixture 2","expected":[[0,1,{"color":"red"}],[1,2,{"color":"blue"}],[2,3,{"color":"red"}]],"passed":false},{"actual":[[0,3,{"x":"high"}]],"check":"contract fixture 3","expected":[[0,3,{"x":"high"}]],"passed":true},{"actual":[[0,3,{"x":"last"}]],"check":"contract fixture 4","expected":[[0,3,{"x":"last"}]],"passed":true},{"actual":[[0,3,{"x":"a"}]],"check":"contract fixture 5","expected":[[0,3,{"x":"a"}]],"passed":true},{"actual":[],"check":"contract fixture 6","expected":[],"passed":true},{"actual":[[0,2,{"lang":"en"}]],"check":"contract fixture 7","expected":[[0,2,{"lang":"en"}]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"contract fixture 1\", \"actual\": [[0, 1, {\"lang\": \"en\", \"weight\": \"bold\"}], [1, 2, {\"lang\": \"fr\"}], [2, 3, {\"lang\": \"en\"}]], \"expected\": [[0, 1, {\"lang\": \"en\", \"weight\": \"bold\"}], [1, 2, {\"lang\": \"fr\"}], [2, 3, {\"lang\": \"en\"}]], \"passed\": true}, {\"check\": \"contract fixture 2\", \"actual\": [[0, 1, {\"lang\": null, \"color\": \"red\"}], [1, 2, {\"lang\": null, \"color\": \"blue\"}], [2, 3, {\"lang\": null, \"color\": \"red\"}]], \"expected\": [[0, 1, {\"color\": \"red\"}], [1, 2, {\"color\": \"blue\"}], [2, 3, {\"color\": \"red\"}]], \"passed\": false}, {\"check\": \"contract fixture 3\", \"actual\": [[0, 3, {\"x\": \"high\"}]], \"expected\": [[0, 3, {\"x\": \"high\"}]], \"passed\": true}, {\"check\": \"contract fixture 4\", \"actual\": [[0, 3, {\"x\": \"last\"}]], \"expected\": [[0, 3, {\"x\": \"last\"}]], \"passed\": true}, {\"check\": \"contract fixture 5\", \"actual\": [[0, 3, {\"x\": \"a\"}]], \"expected\": [[0, 3, {\"x\": \"a\"}]], \"passed\": true}, {\"check\": \"contract fixture 6\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"contract fixture 7\", \"actual\": [[0, 2, {\"lang\": \"en\"}]], \"expected\": [[0, 2, {\"lang\": \"en\"}]], \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":42.445,"exit_code":0,"observations":[{"actual":[[0,1,{"lang":"en","weight":"bold"}],[1,2,{"lang":"fr"}],[2,3,{"lang":"en"}]],"check":"contract fixture 1","expected":[[0,1,{"lang":"en","weight":"bold"}],[1,2,{"lang":"fr"}],[2,3,{"lang":"en"}]],"passed":true},{"actual":[[0,1,{"color":"red"}],[1,2,{"color":"blue"}],[2,3,{"color":"red"}]],"check":"contract fixture 2","expected":[[0,1,{"color":"red"}],[1,2,{"color":"blue"}],[2,3,{"color":"red"}]],"passed":true},{"actual":[[0,3,{"x":"high"}]],"check":"contract fixture 3","expected":[[0,3,{"x":"high"}]],"passed":true},{"actual":[[0,3,{"x":"last"}]],"check":"contract fixture 4","expected":[[0,3,{"x":"last"}]],"passed":true},{"actual":[[0,3,{"x":"a"}]],"check":"contract fixture 5","expected":[[0,3,{"x":"a"}]],"passed":true},{"actual":[],"check":"contract fixture 6","expected":[],"passed":true},{"actual":[[0,2,{"lang":"en"}]],"check":"contract fixture 7","expected":[[0,2,{"lang":"en"}]],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"contract fixture 1\", \"actual\": [[0, 1, {\"lang\": \"en\", \"weight\": \"bold\"}], [1, 2, {\"lang\": \"fr\"}], [2, 3, {\"lang\": \"en\"}]], \"expected\": [[0, 1, {\"lang\": \"en\", \"weight\": \"bold\"}], [1, 2, {\"lang\": \"fr\"}], [2, 3, {\"lang\": \"en\"}]], \"passed\": true}, {\"check\": \"contract fixture 2\", \"actual\": [[0, 1, {\"color\": \"red\"}], [1, 2, {\"color\": \"blue\"}], [2, 3, {\"color\": \"red\"}]], \"expected\": [[0, 1, {\"color\": \"red\"}], [1, 2, {\"color\": \"blue\"}], [2, 3, {\"color\": \"red\"}]], \"passed\": true}, {\"check\": \"contract fixture 3\", \"actual\": [[0, 3, {\"x\": \"high\"}]], \"expected\": [[0, 3, {\"x\": \"high\"}]], \"passed\": true}, {\"check\": \"contract fixture 4\", \"actual\": [[0, 3, {\"x\": \"last\"}]], \"expected\": [[0, 3, {\"x\": \"last\"}]], \"passed\": true}, {\"check\": \"contract fixture 5\", \"actual\": [[0, 3, {\"x\": \"a\"}]], \"expected\": [[0, 3, {\"x\": \"a\"}]], \"passed\": true}, {\"check\": \"contract fixture 6\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"contract fixture 7\", \"actual\": [[0, 2, {\"lang\": \"en\"}]], \"expected\": [[0, 2, {\"lang\": \"en\"}]], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}