FA-9516 / Dependency resolution / Open access
Feature activation closure: Inactive features activate their implications · case 01
Inactive features activate their implications.
ROOT CAUSE
The implementation substitutes if True: for if feature in active:, so inactive features activate their implications.
VERIFIED REPAIR
Traverse implications only for active features.
Unsuccessful approach: The attempted repair substitutes if feature not in active:. Fixture 3 still yields ['b', 'other'] instead of ['other'].
Case contract
Activate named features and their implications, preserve unknown requested leaves, ignore disabled implication edges, deduplicate cycles, and return sorted activated features.
Why this case matters
An offline model of feature activation closure, 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(requested, implications):
active = set(requested)
for _ in range(len(implications) + 1):
for feature, edges in implications.items():
if True:
active.update(name for name, enabled in edges if enabled)
return sorted(active)
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve([], {}), [])
check('fixture 2', solve(['x'], {}), ['x'])
check('fixture 3', solve(['other'], {'a': [('b', True)]}), ['other'])
check('fixture 4', solve(['a'], {'a': [('b', True), ('c', False)]}), ['a', 'b'])
check('fixture 5', solve(['a'], {'b': [('c', True)], 'a': [('b', True)]}), ['a', 'b', 'c'])
check('fixture 6', solve(['a'], {'a': [('b', True)], 'b': [('a', True)]}), ['a', 'b'])
check('fixture 7', solve(['z', 'a', 'z'], {}), ['a', 'z'])
check('fixture 8', solve(['a'], {'c': [('d', True)], 'b': [('c', True)], 'a': [('b', True)]}), ['a', 'b', 'c', 'd'])
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'] | ['x'] | Passed |
| fixture 3 | ['b', 'other'] | ['other'] | Failed |
| fixture 4 | ['a', 'b'] | ['a', 'b'] | Passed |
| fixture 5 | ['a', 'b', 'c'] | ['a', 'b', 'c'] | Passed |
| fixture 6 | ['a', 'b'] | ['a', 'b'] | Passed |
| fixture 7 | ['a', 'z'] | ['a', 'z'] | Passed |
| fixture 8 | ['a', 'b', 'c', 'd'] | ['a', 'b', 'c', 'd'] | Passed |
SHA-256 / 148873aef3ce59cb6ef4dc92ad16686712b531496aa94883b4092e2a35451036
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(requested, implications):
active = set(requested)
for _ in range(len(implications) + 1):
for feature, edges in implications.items():
if feature not in active:
active.update(name for name, enabled in edges if enabled)
return sorted(active)
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve([], {}), [])
check('fixture 2', solve(['x'], {}), ['x'])
check('fixture 3', solve(['other'], {'a': [('b', True)]}), ['other'])
check('fixture 4', solve(['a'], {'a': [('b', True), ('c', False)]}), ['a', 'b'])
check('fixture 5', solve(['a'], {'b': [('c', True)], 'a': [('b', True)]}), ['a', 'b', 'c'])
check('fixture 6', solve(['a'], {'a': [('b', True)], 'b': [('a', True)]}), ['a', 'b'])
check('fixture 7', solve(['z', 'a', 'z'], {}), ['a', 'z'])
check('fixture 8', solve(['a'], {'c': [('d', True)], 'b': [('c', True)], 'a': [('b', True)]}), ['a', 'b', 'c', 'd'])
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'] | ['x'] | Passed |
| fixture 3 | ['b', 'other'] | ['other'] | Failed |
| fixture 4 | ['a'] | ['a', 'b'] | Failed |
| fixture 5 | ['a', 'c'] | ['a', 'b', 'c'] | Failed |
| fixture 6 | ['a'] | ['a', 'b'] | Failed |
| fixture 7 | ['a', 'z'] | ['a', 'z'] | Passed |
| fixture 8 | ['a', 'c', 'd'] | ['a', 'b', 'c', 'd'] | Failed |
SHA-256 / d62e2884fb32ecbbc2c9a2b12bef21bf83bc38c89c904efe84d75aa40b8577e4
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(requested, implications):
active = set(requested)
for _ in range(len(implications) + 1):
for feature, edges in implications.items():
if feature in active:
active.update(name for name, enabled in edges if enabled)
return sorted(active)
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve([], {}), [])
check('fixture 2', solve(['x'], {}), ['x'])
check('fixture 3', solve(['other'], {'a': [('b', True)]}), ['other'])
check('fixture 4', solve(['a'], {'a': [('b', True), ('c', False)]}), ['a', 'b'])
check('fixture 5', solve(['a'], {'b': [('c', True)], 'a': [('b', True)]}), ['a', 'b', 'c'])
check('fixture 6', solve(['a'], {'a': [('b', True)], 'b': [('a', True)]}), ['a', 'b'])
check('fixture 7', solve(['z', 'a', 'z'], {}), ['a', 'z'])
check('fixture 8', solve(['a'], {'c': [('d', True)], 'b': [('c', True)], 'a': [('b', True)]}), ['a', 'b', 'c', 'd'])
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'] | ['x'] | Passed |
| fixture 3 | ['other'] | ['other'] | Passed |
| fixture 4 | ['a', 'b'] | ['a', 'b'] | Passed |
| fixture 5 | ['a', 'b', 'c'] | ['a', 'b', 'c'] | Passed |
| fixture 6 | ['a', 'b'] | ['a', 'b'] | Passed |
| fixture 7 | ['a', 'z'] | ['a', 'z'] | Passed |
| fixture 8 | ['a', 'b', 'c', 'd'] | ['a', 'b', 'c', 'd'] | Passed |
SHA-256 / 61507dca56ea28864086fcc573f8f548cbb9c5591c881c15acb705cc1fb27398
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:30.655425+00:00.
Case digest / aedc6013a6cf51f82cdab078e9b2ca81233f075fae25a23bf16cc352ce9a5b33