FA-9311 / Build systems / Open access
Generated file ownership: Only one output of a generator is registered · case 01
Only one output of a generator is registered.
ROOT CAUSE
The implementation substitutes for output in outputs[:1]: for for output in outputs:, so only one output of a generator is registered.
VERIFIED REPAIR
Register every declared output.
Unsuccessful approach: The attempted repair substitutes for output in outputs[1:]:. Fixture 2 still yields [('x', 'a')] instead of [('x', 'a'), ('z', 'a')].
Case contract
Map output names to producing rules. Skip disabled rules, include all declared outputs, reject duplicate owners, retain owner names, and return sorted pairs. Duplicate declaration by the same owner is harmless.
Why this case matters
An offline model of generated file ownership, suitable for testing build and release tooling without external services.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(rules):
owners = {}
for name, enabled, outputs in rules:
if not enabled: continue
for output in outputs[:1]:
if output in owners and owners[output] != name: return 'conflict'
owners[output] = name
return sorted(owners.items())
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve([]), [])
check('fixture 2', solve([('a', True, ['z', 'x'])]), [('x', 'a'), ('z', 'a')])
check('fixture 3', solve([('a', False, ['x']), ('b', True, ['x'])]), [('x', 'b')])
check('fixture 4', solve([('a', True, ['x']), ('b', True, ['x'])]), 'conflict')
check('fixture 5', solve([('a', True, ['x', 'x'])]), [('x', 'a')])
check('fixture 6', solve([('a', True, [])]), [])
check('fixture 7', solve([('a', True, ['y']), ('b', True, ['x'])]), [('x', 'b'), ('y', 'a')])
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 |
|---|---|---|---|
| fixture 1 | [] | [] | Passed |
| fixture 2 | [['z', 'a']] | [['x', 'a'], ['z', 'a']] | Failed |
| fixture 3 | [['x', 'b']] | [['x', 'b']] | Passed |
| fixture 4 | conflict | conflict | Passed |
| fixture 5 | [['x', 'a']] | [['x', 'a']] | Passed |
| fixture 6 | [] | [] | Passed |
| fixture 7 | [['x', 'b'], ['y', 'a']] | [['x', 'b'], ['y', 'a']] | Passed |
SHA-256 / 340b4aa17cf67c0a02d1d104c4caaaf3241fcf4345b0e70d36cee5022110aca0
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(rules):
owners = {}
for name, enabled, outputs in rules:
if not enabled: continue
for output in outputs[1:]:
if output in owners and owners[output] != name: return 'conflict'
owners[output] = name
return sorted(owners.items())
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve([]), [])
check('fixture 2', solve([('a', True, ['z', 'x'])]), [('x', 'a'), ('z', 'a')])
check('fixture 3', solve([('a', False, ['x']), ('b', True, ['x'])]), [('x', 'b')])
check('fixture 4', solve([('a', True, ['x']), ('b', True, ['x'])]), 'conflict')
check('fixture 5', solve([('a', True, ['x', 'x'])]), [('x', 'a')])
check('fixture 6', solve([('a', True, [])]), [])
check('fixture 7', solve([('a', True, ['y']), ('b', True, ['x'])]), [('x', 'b'), ('y', 'a')])
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 |
|---|---|---|---|
| fixture 1 | [] | [] | Passed |
| fixture 2 | [['x', 'a']] | [['x', 'a'], ['z', 'a']] | Failed |
| fixture 3 | [] | [['x', 'b']] | Failed |
| fixture 4 | [] | conflict | Failed |
| fixture 5 | [['x', 'a']] | [['x', 'a']] | Passed |
| fixture 6 | [] | [] | Passed |
| fixture 7 | [] | [['x', 'b'], ['y', 'a']] | Failed |
SHA-256 / e23547d3438267666394025ba9f43a2f741a916bc94e5be7d21da6d10ca0000a
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(rules):
owners = {}
for name, enabled, outputs in rules:
if not enabled: continue
for output in outputs:
if output in owners and owners[output] != name: return 'conflict'
owners[output] = name
return sorted(owners.items())
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve([]), [])
check('fixture 2', solve([('a', True, ['z', 'x'])]), [('x', 'a'), ('z', 'a')])
check('fixture 3', solve([('a', False, ['x']), ('b', True, ['x'])]), [('x', 'b')])
check('fixture 4', solve([('a', True, ['x']), ('b', True, ['x'])]), 'conflict')
check('fixture 5', solve([('a', True, ['x', 'x'])]), [('x', 'a')])
check('fixture 6', solve([('a', True, [])]), [])
check('fixture 7', solve([('a', True, ['y']), ('b', True, ['x'])]), [('x', 'b'), ('y', 'a')])
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 |
|---|---|---|---|
| fixture 1 | [] | [] | Passed |
| fixture 2 | [['x', 'a'], ['z', 'a']] | [['x', 'a'], ['z', 'a']] | Passed |
| fixture 3 | [['x', 'b']] | [['x', 'b']] | Passed |
| fixture 4 | conflict | conflict | Passed |
| fixture 5 | [['x', 'a']] | [['x', 'a']] | Passed |
| fixture 6 | [] | [] | Passed |
| fixture 7 | [['x', 'b'], ['y', 'a']] | [['x', 'b'], ['y', 'a']] | Passed |
SHA-256 / a3ea30a6f36a4b7551deb24c694597368e1288f85cba9721a4ea90e7b18c21f5
Verification & scope
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:38:28.883564+00:00.
Case digest / c755225d345aa1a85f5a4ddd4e2b3cecdb38357e6511830993bb294b5ba17b79