{"abstract":"A structured table violates the declared record or column contract.","category":"Delimited text","checks":7,"contract":"Parse bounded valid CSV text using Python csv.reader and report each logical row with inclusive one-based physical start/end line numbers. Quoted embedded newlines count as physical lines. Empty input gives no rows; blank physical lines are zero-cell rows. Return [start,end,cells].","evaluation_group":"s3-delimited-text-csv-line-provenance","failed_approach":"The alternate implementation still violates the same declared invariant: blank physical csv records disappear from the provenance stream.","family":"s3-delimited-text-csv-line-provenance-blank-provenance","id":"FA-48811","implementations":{"attempt":{"sha256":"4edb9a9b5d4d24307f6447be8f60633e04166b17e3b29e7fac8fc28c23967497","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    import csv,io\n    reader=csv.reader(io.StringIO(data,newline=''))\n    out=[]; start=1\n    for cells in reader:\n        end=reader.line_num\n        if any(cells): out.append([start,end,cells])\n        start=end+1\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('multiline', solve(_vary('a,\"x\\ny\"\\nz,@\\n')), _vary([[1, 2, ['a', 'x\\ny']], [3, 3, ['z', '@']]]))\ncheck('blank middle', solve(_vary('a\\n\\nz\\n')), _vary([[1, 1, ['a']], [2, 2, []], [3, 3, ['z']]]))\ncheck('plain', solve(_vary('@,x\\n')), _vary([[1, 1, ['@', 'x']]]))\ncheck('CRLF', solve(_vary('\"a\\r\\nb\",z\\r\\n')), _vary([[1, 2, ['a\\r\\nb', 'z']]]))\ncheck('empty', solve(_vary('')), _vary([]))\ncheck('unterminated final', solve(_vary('@')), _vary([[1, 1, ['@']]]))\ncheck('two multiline', solve(_vary('\"a\\nb\"\\n\"c\\nd\"')), _vary([[1, 2, ['a\\nb']], [3, 4, ['c\\nd']]]))\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":"5e0bc289e73009907cc83627d5a0e11f86b903649f156835c773a0dd02abc986","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    import csv,io\n    reader=csv.reader(io.StringIO(data,newline=''))\n    out=[]; start=1\n    for cells in reader:\n        end=reader.line_num\n        if cells: out.append([start,end,cells])\n        start=end+1\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('multiline', solve(_vary('a,\"x\\ny\"\\nz,@\\n')), _vary([[1, 2, ['a', 'x\\ny']], [3, 3, ['z', '@']]]))\ncheck('blank middle', solve(_vary('a\\n\\nz\\n')), _vary([[1, 1, ['a']], [2, 2, []], [3, 3, ['z']]]))\ncheck('plain', solve(_vary('@,x\\n')), _vary([[1, 1, ['@', 'x']]]))\ncheck('CRLF', solve(_vary('\"a\\r\\nb\",z\\r\\n')), _vary([[1, 2, ['a\\r\\nb', 'z']]]))\ncheck('empty', solve(_vary('')), _vary([]))\ncheck('unterminated final', solve(_vary('@')), _vary([[1, 1, ['@']]]))\ncheck('two multiline', solve(_vary('\"a\\nb\"\\n\"c\\nd\"')), _vary([[1, 2, ['a\\nb']], [3, 4, ['c\\nd']]]))\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":"c0dcd833e59189ee8c02f058ae4196f72cb98eb308059eff0a5c0abb27b2d4b0","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    import csv,io\n    reader=csv.reader(io.StringIO(data,newline=''))\n    out=[]; start=1\n    for cells in reader:\n        end=reader.line_num\n        out.append([start,end,cells])\n        start=end+1\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('multiline', solve(_vary('a,\"x\\ny\"\\nz,@\\n')), _vary([[1, 2, ['a', 'x\\ny']], [3, 3, ['z', '@']]]))\ncheck('blank middle', solve(_vary('a\\n\\nz\\n')), _vary([[1, 1, ['a']], [2, 2, []], [3, 3, ['z']]]))\ncheck('plain', solve(_vary('@,x\\n')), _vary([[1, 1, ['@', 'x']]]))\ncheck('CRLF', solve(_vary('\"a\\r\\nb\",z\\r\\n')), _vary([[1, 2, ['a\\r\\nb', 'z']]]))\ncheck('empty', solve(_vary('')), _vary([]))\ncheck('unterminated final', solve(_vary('@')), _vary([[1, 1, ['@']]]))\ncheck('two multiline', solve(_vary('\"a\\nb\"\\n\"c\\nd\"')), _vary([[1, 2, ['a\\nb']], [3, 4, ['c\\nd']]]))\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-csv-line-provenance-blank-provenance","generated_at":"2026-09-29T14:44:54.069098+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.","repair":"Preserve the named invariant at the faulty decision: out.append([start,end,cells])","root_cause":"Blank physical CSV records disappear from the provenance stream.","sha256":"132afe097a6dd92ec0f588fad71c94f137248c5cbbcdff4bec21fd719f66c639","title":"Blank physical CSV records disappear from the provenance stream · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":38.492,"exit_code":1,"observations":[{"actual":[[1,2,["a","x\ny"]],[3,3,["z","cell"]]],"check":"multiline","expected":[[1,2,["a","x\ny"]],[3,3,["z","cell"]]],"passed":true},{"actual":[[1,1,["a"]],[3,3,["z"]]],"check":"blank middle","expected":[[1,1,["a"]],[2,2,[]],[3,3,["z"]]],"passed":false},{"actual":[[1,1,["cell","x"]]],"check":"plain","expected":[[1,1,["cell","x"]]],"passed":true},{"actual":[[1,2,["a\r\nb","z"]]],"check":"CRLF","expected":[[1,2,["a\r\nb","z"]]],"passed":true},{"actual":[],"check":"empty","expected":[],"passed":true},{"actual":[[1,1,["cell"]]],"check":"unterminated final","expected":[[1,1,["cell"]]],"passed":true},{"actual":[[1,2,["a\nb"]],[3,4,["c\nd"]]],"check":"two multiline","expected":[[1,2,["a\nb"]],[3,4,["c\nd"]]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"multiline\", \"actual\": [[1, 2, [\"a\", \"x\\ny\"]], [3, 3, [\"z\", \"cell\"]]], \"expected\": [[1, 2, [\"a\", \"x\\ny\"]], [3, 3, [\"z\", \"cell\"]]], \"passed\": true}, {\"check\": \"blank middle\", \"actual\": [[1, 1, [\"a\"]], [3, 3, [\"z\"]]], \"expected\": [[1, 1, [\"a\"]], [2, 2, []], [3, 3, [\"z\"]]], \"passed\": false}, {\"check\": \"plain\", \"actual\": [[1, 1, [\"cell\", \"x\"]]], \"expected\": [[1, 1, [\"cell\", \"x\"]]], \"passed\": true}, {\"check\": \"CRLF\", \"actual\": [[1, 2, [\"a\\r\\nb\", \"z\"]]], \"expected\": [[1, 2, [\"a\\r\\nb\", \"z\"]]], \"passed\": true}, {\"check\": \"empty\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"unterminated final\", \"actual\": [[1, 1, [\"cell\"]]], \"expected\": [[1, 1, [\"cell\"]]], \"passed\": true}, {\"check\": \"two multiline\", \"actual\": [[1, 2, [\"a\\nb\"]], [3, 4, [\"c\\nd\"]]], \"expected\": [[1, 2, [\"a\\nb\"]], [3, 4, [\"c\\nd\"]]], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":40.32,"exit_code":1,"observations":[{"actual":[[1,2,["a","x\ny"]],[3,3,["z","cell"]]],"check":"multiline","expected":[[1,2,["a","x\ny"]],[3,3,["z","cell"]]],"passed":true},{"actual":[[1,1,["a"]],[3,3,["z"]]],"check":"blank middle","expected":[[1,1,["a"]],[2,2,[]],[3,3,["z"]]],"passed":false},{"actual":[[1,1,["cell","x"]]],"check":"plain","expected":[[1,1,["cell","x"]]],"passed":true},{"actual":[[1,2,["a\r\nb","z"]]],"check":"CRLF","expected":[[1,2,["a\r\nb","z"]]],"passed":true},{"actual":[],"check":"empty","expected":[],"passed":true},{"actual":[[1,1,["cell"]]],"check":"unterminated final","expected":[[1,1,["cell"]]],"passed":true},{"actual":[[1,2,["a\nb"]],[3,4,["c\nd"]]],"check":"two multiline","expected":[[1,2,["a\nb"]],[3,4,["c\nd"]]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"multiline\", \"actual\": [[1, 2, [\"a\", \"x\\ny\"]], [3, 3, [\"z\", \"cell\"]]], \"expected\": [[1, 2, [\"a\", \"x\\ny\"]], [3, 3, [\"z\", \"cell\"]]], \"passed\": true}, {\"check\": \"blank middle\", \"actual\": [[1, 1, [\"a\"]], [3, 3, [\"z\"]]], \"expected\": [[1, 1, [\"a\"]], [2, 2, []], [3, 3, [\"z\"]]], \"passed\": false}, {\"check\": \"plain\", \"actual\": [[1, 1, [\"cell\", \"x\"]]], \"expected\": [[1, 1, [\"cell\", \"x\"]]], \"passed\": true}, {\"check\": \"CRLF\", \"actual\": [[1, 2, [\"a\\r\\nb\", \"z\"]]], \"expected\": [[1, 2, [\"a\\r\\nb\", \"z\"]]], \"passed\": true}, {\"check\": \"empty\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"unterminated final\", \"actual\": [[1, 1, [\"cell\"]]], \"expected\": [[1, 1, [\"cell\"]]], \"passed\": true}, {\"check\": \"two multiline\", \"actual\": [[1, 2, [\"a\\nb\"]], [3, 4, [\"c\\nd\"]]], \"expected\": [[1, 2, [\"a\\nb\"]], [3, 4, [\"c\\nd\"]]], \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":41.587,"exit_code":0,"observations":[{"actual":[[1,2,["a","x\ny"]],[3,3,["z","cell"]]],"check":"multiline","expected":[[1,2,["a","x\ny"]],[3,3,["z","cell"]]],"passed":true},{"actual":[[1,1,["a"]],[2,2,[]],[3,3,["z"]]],"check":"blank middle","expected":[[1,1,["a"]],[2,2,[]],[3,3,["z"]]],"passed":true},{"actual":[[1,1,["cell","x"]]],"check":"plain","expected":[[1,1,["cell","x"]]],"passed":true},{"actual":[[1,2,["a\r\nb","z"]]],"check":"CRLF","expected":[[1,2,["a\r\nb","z"]]],"passed":true},{"actual":[],"check":"empty","expected":[],"passed":true},{"actual":[[1,1,["cell"]]],"check":"unterminated final","expected":[[1,1,["cell"]]],"passed":true},{"actual":[[1,2,["a\nb"]],[3,4,["c\nd"]]],"check":"two multiline","expected":[[1,2,["a\nb"]],[3,4,["c\nd"]]],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"multiline\", \"actual\": [[1, 2, [\"a\", \"x\\ny\"]], [3, 3, [\"z\", \"cell\"]]], \"expected\": [[1, 2, [\"a\", \"x\\ny\"]], [3, 3, [\"z\", \"cell\"]]], \"passed\": true}, {\"check\": \"blank middle\", \"actual\": [[1, 1, [\"a\"]], [2, 2, []], [3, 3, [\"z\"]]], \"expected\": [[1, 1, [\"a\"]], [2, 2, []], [3, 3, [\"z\"]]], \"passed\": true}, {\"check\": \"plain\", \"actual\": [[1, 1, [\"cell\", \"x\"]]], \"expected\": [[1, 1, [\"cell\", \"x\"]]], \"passed\": true}, {\"check\": \"CRLF\", \"actual\": [[1, 2, [\"a\\r\\nb\", \"z\"]]], \"expected\": [[1, 2, [\"a\\r\\nb\", \"z\"]]], \"passed\": true}, {\"check\": \"empty\", \"actual\": [], \"expected\": [], \"passed\": true}, {\"check\": \"unterminated final\", \"actual\": [[1, 1, [\"cell\"]]], \"expected\": [[1, 1, [\"cell\"]]], \"passed\": true}, {\"check\": \"two multiline\", \"actual\": [[1, 2, [\"a\\nb\"]], [3, 4, [\"c\\nd\"]]], \"expected\": [[1, 2, [\"a\\nb\"]], [3, 4, [\"c\\nd\"]]], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}