{"abstract":"A structured table violates the declared record or column contract.","category":"Delimited text","checks":11,"contract":"Parse comma fields index=value into a fixed-width dense row. Indexes are unsigned decimal integers, zero based, strictly increasing and less than width; equal indexes reject. Missing positions remain null. Values may contain equals; empty values are retained.","contract_signature":"data","evaluation_group":"s3-delimited-text-sparse-indexed-row","failed_approach":"Advancing from the previous index still ignores gaps before the next field.","family":"s3-delimited-text-sparse-indexed-row-placement","id":"FA-47601","implementations":{"attempt":{"sha256":"0a74cc2b875b1cbc2bf888080c7ac4b954055c0b95fe201fe5a569a2b29b9177","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\ndef _vary(value):\n    if value == '@END': return 3 + 4*N\n    if isinstance(value, str): return value.replace('@', 'cell' * N)\n    if isinstance(value, list): return [_vary(x) for x in value]\n    if isinstance(value, dict): return {_vary(k): _vary(v) for k,v in value.items()}\n    return value\nN = 1\nobservations = []\ndef solve(data):\n    out = [None] * data['width']\n    last = -1\n    for cell in data['row'].split(',') if data['row'] else []:\n        parts = cell.split('=', 1)\n        if len(parts) != 2: return None\n        index, value = parts\n        if not index.isascii() or not index.isdecimal(): return None\n        index = int(index)\n        if index <= last or index >= data['width']: return None\n        out[last + 1] = value\n        last = index\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('gaps', solve(_vary({'width': 4, 'row': '0=@,2=z'})), _vary(['@', None, 'z', None]))\ncheck('equals value', solve(_vary({'width': 2, 'row': '1=a=b'})), _vary([None, 'a=b']))\ncheck('empty value', solve(_vary({'width': 2, 'row': '0='})), _vary(['', None]))\ncheck('duplicate', solve(_vary({'width': 2, 'row': '0=x,0=y'})), _vary(None))\ncheck('decreasing', solve(_vary({'width': 3, 'row': '2=x,1=y'})), _vary(None))\ncheck('out of bounds', solve(_vary({'width': 2, 'row': '2=x'})), _vary(None))\ncheck('negative', solve(_vary({'width': 2, 'row': '-1=x'})), _vary(None))\ncheck('Unicode digit', solve(_vary({'width': 2, 'row': '١=x'})), _vary(None))\ncheck('empty row', solve(_vary({'width': 3, 'row': ''})), _vary([None, None, None]))\ncheck('last slot', solve(_vary({'width': 2, 'row': '1=@'})), _vary([None, '@']))\ncheck('malformed', solve(_vary({'width': 2, 'row': '0'})), _vary(None))\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":"45b62503a1e995110212917d2ac0230fb9153b46e597ee5faa3bb13f41a2ae51","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\ndef _vary(value):\n    if value == '@END': return 3 + 4*N\n    if isinstance(value, str): return value.replace('@', 'cell' * N)\n    if isinstance(value, list): return [_vary(x) for x in value]\n    if isinstance(value, dict): return {_vary(k): _vary(v) for k,v in value.items()}\n    return value\nN = 1\nobservations = []\ndef solve(data):\n    out = [None] * data['width']\n    last = -1\n    for cell in data['row'].split(',') if data['row'] else []:\n        parts = cell.split('=', 1)\n        if len(parts) != 2: return None\n        index, value = parts\n        if not index.isascii() or not index.isdecimal(): return None\n        index = int(index)\n        if index <= last or index >= data['width']: return None\n        out[sum(x is not None for x in out)] = value\n        last = index\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('gaps', solve(_vary({'width': 4, 'row': '0=@,2=z'})), _vary(['@', None, 'z', None]))\ncheck('equals value', solve(_vary({'width': 2, 'row': '1=a=b'})), _vary([None, 'a=b']))\ncheck('empty value', solve(_vary({'width': 2, 'row': '0='})), _vary(['', None]))\ncheck('duplicate', solve(_vary({'width': 2, 'row': '0=x,0=y'})), _vary(None))\ncheck('decreasing', solve(_vary({'width': 3, 'row': '2=x,1=y'})), _vary(None))\ncheck('out of bounds', solve(_vary({'width': 2, 'row': '2=x'})), _vary(None))\ncheck('negative', solve(_vary({'width': 2, 'row': '-1=x'})), _vary(None))\ncheck('Unicode digit', solve(_vary({'width': 2, 'row': '١=x'})), _vary(None))\ncheck('empty row', solve(_vary({'width': 3, 'row': ''})), _vary([None, None, None]))\ncheck('last slot', solve(_vary({'width': 2, 'row': '1=@'})), _vary([None, '@']))\ncheck('malformed', solve(_vary({'width': 2, 'row': '0'})), _vary(None))\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":"Deterministic bounded in-memory model. No claim of complete CSV or external format 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-delimited-text-sparse-indexed-row-placement","generated_at":"2026-09-29T14:44:43.139267+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Delimited interchange needs explicit framing, schema and field semantics at ingestion and emission boundaries.","root_cause":"The sparse decoder uses occurrence count as physical column position.","sha256":"6820abea62f6637a3eef5490ba7983376eb7fe5b7135f103c27322eb648e4a02","title":"Sparse fields are packed at the left instead of their indexes · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verified":true,"visibility":"public","verification":{"attempt":{"elapsed_ms":42.646,"exit_code":1,"observations":[{"actual":["cell","z",null,null],"check":"gaps","expected":["cell",null,"z",null],"passed":false},{"actual":["a=b",null],"check":"equals value","expected":[null,"a=b"],"passed":false},{"actual":["",null],"check":"empty value","expected":["",null],"passed":true},{"actual":null,"check":"duplicate","expected":null,"passed":true},{"actual":null,"check":"decreasing","expected":null,"passed":true},{"actual":null,"check":"out of bounds","expected":null,"passed":true},{"actual":null,"check":"negative","expected":null,"passed":true},{"actual":null,"check":"Unicode digit","expected":null,"passed":true},{"actual":[null,null,null],"check":"empty row","expected":[null,null,null],"passed":true},{"actual":["cell",null],"check":"last slot","expected":[null,"cell"],"passed":false},{"actual":null,"check":"malformed","expected":null,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"gaps\", \"actual\": [\"cell\", \"z\", null, null], \"expected\": [\"cell\", null, \"z\", null], \"passed\": false}, {\"check\": \"equals value\", \"actual\": [\"a=b\", null], \"expected\": [null, \"a=b\"], \"passed\": false}, {\"check\": \"empty value\", \"actual\": [\"\", null], \"expected\": [\"\", null], \"passed\": true}, {\"check\": \"duplicate\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"decreasing\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"out of bounds\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"negative\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"Unicode digit\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"empty row\", \"actual\": [null, null, null], \"expected\": [null, null, null], \"passed\": true}, {\"check\": \"last slot\", \"actual\": [\"cell\", null], \"expected\": [null, \"cell\"], \"passed\": false}, {\"check\": \"malformed\", \"actual\": null, \"expected\": null, \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":41.929,"exit_code":1,"observations":[{"actual":["cell","z",null,null],"check":"gaps","expected":["cell",null,"z",null],"passed":false},{"actual":["a=b",null],"check":"equals value","expected":[null,"a=b"],"passed":false},{"actual":["",null],"check":"empty value","expected":["",null],"passed":true},{"actual":null,"check":"duplicate","expected":null,"passed":true},{"actual":null,"check":"decreasing","expected":null,"passed":true},{"actual":null,"check":"out of bounds","expected":null,"passed":true},{"actual":null,"check":"negative","expected":null,"passed":true},{"actual":null,"check":"Unicode digit","expected":null,"passed":true},{"actual":[null,null,null],"check":"empty row","expected":[null,null,null],"passed":true},{"actual":["cell",null],"check":"last slot","expected":[null,"cell"],"passed":false},{"actual":null,"check":"malformed","expected":null,"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"gaps\", \"actual\": [\"cell\", \"z\", null, null], \"expected\": [\"cell\", null, \"z\", null], \"passed\": false}, {\"check\": \"equals value\", \"actual\": [\"a=b\", null], \"expected\": [null, \"a=b\"], \"passed\": false}, {\"check\": \"empty value\", \"actual\": [\"\", null], \"expected\": [\"\", null], \"passed\": true}, {\"check\": \"duplicate\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"decreasing\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"out of bounds\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"negative\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"Unicode digit\", \"actual\": null, \"expected\": null, \"passed\": true}, {\"check\": \"empty row\", \"actual\": [null, null, null], \"expected\": [null, null, null], \"passed\": true}, {\"check\": \"last slot\", \"actual\": [\"cell\", null], \"expected\": [null, \"cell\"], \"passed\": false}, {\"check\": \"malformed\", \"actual\": null, \"expected\": null, \"passed\": true}], \"passed\": false}\n"}},"member_only":{"stages":["fixed"],"fields":["implementations.fixed","verification.fixed","harness","repair"],"note":"The verified repair, its recorded checks, the repair description, and the scoring harness are available to members."}}