FA-45241 / Data systems / Open access
A stale physical column overwrites its partition value · case 01
A stale physical column overwrites its partition value.
ROOT CAUSE
partition-column-injection: A stale physical column overwrites its partition value.
VERIFIED REPAIR
Preserve the stated physical representation and operation order: Read ordered file fragments [partition-values,physical-rows] under a projection of field names. Partition values override stale physical columns of the same name; unprojected fields disappear, missing fields become None, and physically empty fragments do not synthesize rows.
Unsuccessful approach: Filling only absent columns leaves stale physical partition values authoritative.
Case contract
Read ordered file fragments [partition-values,physical-rows] under a projection of field names. Partition values override stale physical columns of the same name; unprojected fields disappear, missing fields become None, and physically empty fragments do not synthesize rows.
Why this case matters
A bounded deterministic data engine model makes representation and changelog faults reproducible.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(d):
try:
fragments,projection=d
out=[]
for partition,rows in fragments:
for row in rows:
merged=dict(row)
merged={**partition,**row}
out.append([merged.get(name) for name in projection])
return out
except (IndexError, KeyError, ValueError, StopIteration) as exc:
return {"representation_error": type(exc).__name__}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
if N == 1:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 1}]]], ['v', 'p']]), [[1, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 1}]], [{'p': 'b'}, [{'v': 2}]]], ['p', 'v']]), [['a', 1], ['b', 2]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 1}]]], ['v', 'x']]), [[1, None]])
check('duplicate rows', solve([[[{}, [{'v': 1}, {'v': 1}]]], ['v']]), [[1], [1]])
check('duplicate projection', solve([[[{}, [{'v': 1}]]], ['v', 'v']]), [[1, 1]])
check('no fragments', solve([[], ['v']]), [])
elif N == 2:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 2}]]], ['v', 'p']]), [[2, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 2}]], [{'p': 'b'}, [{'v': 3}]]], ['p', 'v']]), [['a', 2], ['b', 3]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 2}]]], ['v', 'x']]), [[2, None]])
check('duplicate rows', solve([[[{}, [{'v': 2}, {'v': 2}]]], ['v']]), [[2], [2]])
check('duplicate projection', solve([[[{}, [{'v': 2}]]], ['v', 'v']]), [[2, 2]])
check('no fragments', solve([[], ['v']]), [])
elif N == 3:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 3}]]], ['v', 'p']]), [[3, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 3}]], [{'p': 'b'}, [{'v': 4}]]], ['p', 'v']]), [['a', 3], ['b', 4]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 3}]]], ['v', 'x']]), [[3, None]])
check('duplicate rows', solve([[[{}, [{'v': 3}, {'v': 3}]]], ['v']]), [[3], [3]])
check('duplicate projection', solve([[[{}, [{'v': 3}]]], ['v', 'v']]), [[3, 3]])
check('no fragments', solve([[], ['v']]), [])
elif N == 4:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 4}]]], ['v', 'p']]), [[4, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 4}]], [{'p': 'b'}, [{'v': 5}]]], ['p', 'v']]), [['a', 4], ['b', 5]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 4}]]], ['v', 'x']]), [[4, None]])
check('duplicate rows', solve([[[{}, [{'v': 4}, {'v': 4}]]], ['v']]), [[4], [4]])
check('duplicate projection', solve([[[{}, [{'v': 4}]]], ['v', 'v']]), [[4, 4]])
check('no fragments', solve([[], ['v']]), [])
elif N == 5:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 5}]]], ['v', 'p']]), [[5, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 5}]], [{'p': 'b'}, [{'v': 6}]]], ['p', 'v']]), [['a', 5], ['b', 6]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 5}]]], ['v', 'x']]), [[5, None]])
check('duplicate rows', solve([[[{}, [{'v': 5}, {'v': 5}]]], ['v']]), [[5], [5]])
check('duplicate projection', solve([[[{}, [{'v': 5}]]], ['v', 'v']]), [[5, 5]])
check('no fragments', solve([[], ['v']]), [])
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 |
|---|---|---|---|
| partition overrides | [[1, 'old']] | [[1, 'new']] | Failed |
| multiple fragments | [['a', 1], ['b', 2]] | [['a', 1], ['b', 2]] | Passed |
| empty fragment | [] | [] | Passed |
| missing projected | [[1, None]] | [[1, None]] | Passed |
| duplicate rows | [[1], [1]] | [[1], [1]] | Passed |
| duplicate projection | [[1, 1]] | [[1, 1]] | Passed |
| no fragments | [] | [] | Passed |
SHA-256 / d80ded8e5f3bfd7c1987ce55874126a5b1077a176b9aa3c7ccb5372c11e3306d
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(d):
try:
fragments,projection=d
out=[]
for partition,rows in fragments:
for row in rows:
merged=dict(row)
merged.update({k:v for k,v in partition.items() if k not in merged})
out.append([merged.get(name) for name in projection])
return out
except (IndexError, KeyError, ValueError, StopIteration) as exc:
return {"representation_error": type(exc).__name__}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
if N == 1:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 1}]]], ['v', 'p']]), [[1, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 1}]], [{'p': 'b'}, [{'v': 2}]]], ['p', 'v']]), [['a', 1], ['b', 2]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 1}]]], ['v', 'x']]), [[1, None]])
check('duplicate rows', solve([[[{}, [{'v': 1}, {'v': 1}]]], ['v']]), [[1], [1]])
check('duplicate projection', solve([[[{}, [{'v': 1}]]], ['v', 'v']]), [[1, 1]])
check('no fragments', solve([[], ['v']]), [])
elif N == 2:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 2}]]], ['v', 'p']]), [[2, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 2}]], [{'p': 'b'}, [{'v': 3}]]], ['p', 'v']]), [['a', 2], ['b', 3]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 2}]]], ['v', 'x']]), [[2, None]])
check('duplicate rows', solve([[[{}, [{'v': 2}, {'v': 2}]]], ['v']]), [[2], [2]])
check('duplicate projection', solve([[[{}, [{'v': 2}]]], ['v', 'v']]), [[2, 2]])
check('no fragments', solve([[], ['v']]), [])
elif N == 3:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 3}]]], ['v', 'p']]), [[3, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 3}]], [{'p': 'b'}, [{'v': 4}]]], ['p', 'v']]), [['a', 3], ['b', 4]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 3}]]], ['v', 'x']]), [[3, None]])
check('duplicate rows', solve([[[{}, [{'v': 3}, {'v': 3}]]], ['v']]), [[3], [3]])
check('duplicate projection', solve([[[{}, [{'v': 3}]]], ['v', 'v']]), [[3, 3]])
check('no fragments', solve([[], ['v']]), [])
elif N == 4:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 4}]]], ['v', 'p']]), [[4, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 4}]], [{'p': 'b'}, [{'v': 5}]]], ['p', 'v']]), [['a', 4], ['b', 5]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 4}]]], ['v', 'x']]), [[4, None]])
check('duplicate rows', solve([[[{}, [{'v': 4}, {'v': 4}]]], ['v']]), [[4], [4]])
check('duplicate projection', solve([[[{}, [{'v': 4}]]], ['v', 'v']]), [[4, 4]])
check('no fragments', solve([[], ['v']]), [])
elif N == 5:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 5}]]], ['v', 'p']]), [[5, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 5}]], [{'p': 'b'}, [{'v': 6}]]], ['p', 'v']]), [['a', 5], ['b', 6]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 5}]]], ['v', 'x']]), [[5, None]])
check('duplicate rows', solve([[[{}, [{'v': 5}, {'v': 5}]]], ['v']]), [[5], [5]])
check('duplicate projection', solve([[[{}, [{'v': 5}]]], ['v', 'v']]), [[5, 5]])
check('no fragments', solve([[], ['v']]), [])
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 |
|---|---|---|---|
| partition overrides | [[1, 'old']] | [[1, 'new']] | Failed |
| multiple fragments | [['a', 1], ['b', 2]] | [['a', 1], ['b', 2]] | Passed |
| empty fragment | [] | [] | Passed |
| missing projected | [[1, None]] | [[1, None]] | Passed |
| duplicate rows | [[1], [1]] | [[1], [1]] | Passed |
| duplicate projection | [[1, 1]] | [[1, 1]] | Passed |
| no fragments | [] | [] | Passed |
SHA-256 / c75cd3064de36ac1fde839abea4cb688ee734a3d9504197b923953808cd5cdc4
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(d):
try:
fragments,projection=d
out=[]
for partition,rows in fragments:
for row in rows:
merged=dict(row)
merged.update(partition)
out.append([merged.get(name) for name in projection])
return out
except (IndexError, KeyError, ValueError, StopIteration) as exc:
return {"representation_error": type(exc).__name__}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
if N == 1:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 1}]]], ['v', 'p']]), [[1, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 1}]], [{'p': 'b'}, [{'v': 2}]]], ['p', 'v']]), [['a', 1], ['b', 2]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 1}]]], ['v', 'x']]), [[1, None]])
check('duplicate rows', solve([[[{}, [{'v': 1}, {'v': 1}]]], ['v']]), [[1], [1]])
check('duplicate projection', solve([[[{}, [{'v': 1}]]], ['v', 'v']]), [[1, 1]])
check('no fragments', solve([[], ['v']]), [])
elif N == 2:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 2}]]], ['v', 'p']]), [[2, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 2}]], [{'p': 'b'}, [{'v': 3}]]], ['p', 'v']]), [['a', 2], ['b', 3]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 2}]]], ['v', 'x']]), [[2, None]])
check('duplicate rows', solve([[[{}, [{'v': 2}, {'v': 2}]]], ['v']]), [[2], [2]])
check('duplicate projection', solve([[[{}, [{'v': 2}]]], ['v', 'v']]), [[2, 2]])
check('no fragments', solve([[], ['v']]), [])
elif N == 3:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 3}]]], ['v', 'p']]), [[3, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 3}]], [{'p': 'b'}, [{'v': 4}]]], ['p', 'v']]), [['a', 3], ['b', 4]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 3}]]], ['v', 'x']]), [[3, None]])
check('duplicate rows', solve([[[{}, [{'v': 3}, {'v': 3}]]], ['v']]), [[3], [3]])
check('duplicate projection', solve([[[{}, [{'v': 3}]]], ['v', 'v']]), [[3, 3]])
check('no fragments', solve([[], ['v']]), [])
elif N == 4:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 4}]]], ['v', 'p']]), [[4, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 4}]], [{'p': 'b'}, [{'v': 5}]]], ['p', 'v']]), [['a', 4], ['b', 5]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 4}]]], ['v', 'x']]), [[4, None]])
check('duplicate rows', solve([[[{}, [{'v': 4}, {'v': 4}]]], ['v']]), [[4], [4]])
check('duplicate projection', solve([[[{}, [{'v': 4}]]], ['v', 'v']]), [[4, 4]])
check('no fragments', solve([[], ['v']]), [])
elif N == 5:
check('partition overrides', solve([[[{'p': 'new'}, [{'p': 'old', 'v': 5}]]], ['v', 'p']]), [[5, 'new']])
check('multiple fragments', solve([[[{'p': 'a'}, [{'v': 5}]], [{'p': 'b'}, [{'v': 6}]]], ['p', 'v']]), [['a', 5], ['b', 6]])
check('empty fragment', solve([[[{'p': 'a'}, []]], ['p']]), [])
check('missing projected', solve([[[{}, [{'v': 5}]]], ['v', 'x']]), [[5, None]])
check('duplicate rows', solve([[[{}, [{'v': 5}, {'v': 5}]]], ['v']]), [[5], [5]])
check('duplicate projection', solve([[[{}, [{'v': 5}]]], ['v', 'v']]), [[5, 5]])
check('no fragments', solve([[], ['v']]), [])
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 |
|---|---|---|---|
| partition overrides | [[1, 'new']] | [[1, 'new']] | Passed |
| multiple fragments | [['a', 1], ['b', 2]] | [['a', 1], ['b', 2]] | Passed |
| empty fragment | [] | [] | Passed |
| missing projected | [[1, None]] | [[1, None]] | Passed |
| duplicate rows | [[1], [1]] | [[1], [1]] | Passed |
| duplicate projection | [[1, 1]] | [[1, 1]] | Passed |
| no fragments | [] | [] | Passed |
SHA-256 / 8773b6564c84ebcfbab64e61c1151d56863f1616de9bfd1e4574b43d2afae784
Verification & scope
Offline stipulated semantics over valid small inputs; no performance, concurrency, or production-engine conformance claim. 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:44:20.167150+00:00.
Case digest / 088e6c8566846a42608c1452a0321bc9f49157cdc0f852dd65d51daed77c205a