FA-8271 / Direct manipulation / Open access
Drop-target acceptance: Dragging a parent into its descendant creates a cycle · case 01
Dragging a parent into its descendant creates a cycle.
ROOT CAUSE
The cycle operation uses `if False: return None` where the contract requires `if target in descendants: return None`.
THE FAILURE
The cycle operation uses `if False: return None` where the contract requires `if target in descendants: return None`.
Unsuccessful approach: Testing source membership does not identify a descendant destination.
Case contract
Accept only enabled, compatible targets outside the source subtree, with a supported move or copy effect.
Why this case matters
A deterministic model of drop-target acceptance; this isolates one interface invariant without requiring a browser.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(drag_type, accepts, disabled, source, target, descendants, effect):
if disabled: return None
if drag_type not in accepts: return None
if source == target: return None
if False: return None
if effect not in ('move', 'copy'): return None
return effect
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('disabled', solve('node', ['node'], True, 'a', 'b', [], 'move'), None)
check('type', solve('file', ['node'], False, 'a', 'b', [], 'move'), None)
check('self', solve('node', ['node'], False, 'a', 'a', [], 'move'), None)
check('cycle', solve('node', ['node'], False, 'a', 'b', ['b'], 'move'), None)
check('unsupported', solve('node', ['node'], False, 'a', 'b', [], 'link'), None)
check('copy', solve('node', ['node'], False, 'a', 'b', [], 'copy'), 'copy')
check('move', solve('node', ['node'], False, 'a', 'b', [], 'move'), 'move')
check('parameterized payload type', solve('type'+str(N), ['type'+str(N)], False, 'a', 'b', [], 'copy'), 'copy')
for repetition in range(N):
check('repeat move', solve('node', ['node'], False, 'a', 'b', [], 'move'), 'move')
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 |
|---|---|---|---|
| disabled | None | None | Passed |
| type | None | None | Passed |
| self | None | None | Passed |
| cycle | move | None | Failed |
| unsupported | None | None | Passed |
| copy | copy | copy | Passed |
| move | move | move | Passed |
| parameterized payload type | copy | copy | Passed |
| repeat move | move | move | Passed |
SHA-256 / e0120fe1288cc024d56a8f5b92a4d29a4a5c4f7b050a5ebba3fffabefc604480
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(drag_type, accepts, disabled, source, target, descendants, effect):
if disabled: return None
if drag_type not in accepts: return None
if source == target: return None
if source in descendants: return None
if effect not in ('move', 'copy'): return None
return effect
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('disabled', solve('node', ['node'], True, 'a', 'b', [], 'move'), None)
check('type', solve('file', ['node'], False, 'a', 'b', [], 'move'), None)
check('self', solve('node', ['node'], False, 'a', 'a', [], 'move'), None)
check('cycle', solve('node', ['node'], False, 'a', 'b', ['b'], 'move'), None)
check('unsupported', solve('node', ['node'], False, 'a', 'b', [], 'link'), None)
check('copy', solve('node', ['node'], False, 'a', 'b', [], 'copy'), 'copy')
check('move', solve('node', ['node'], False, 'a', 'b', [], 'move'), 'move')
check('parameterized payload type', solve('type'+str(N), ['type'+str(N)], False, 'a', 'b', [], 'copy'), 'copy')
for repetition in range(N):
check('repeat move', solve('node', ['node'], False, 'a', 'b', [], 'move'), 'move')
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 |
|---|---|---|---|
| disabled | None | None | Passed |
| type | None | None | Passed |
| self | None | None | Passed |
| cycle | move | None | Failed |
| unsupported | None | None | Passed |
| copy | copy | copy | Passed |
| move | move | move | Passed |
| parameterized payload type | copy | copy | Passed |
| repeat move | move | move | Passed |
SHA-256 / b2f97bb500dac1493148e3ef958d99518f6267b8ba83414213fc91daca1b95e5
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 9 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.
Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.
Member access is invitation-based. Sign in with your invited account to inspect the repair.
Sign in to the archive ↗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:20.012792+00:00.
Case digest / 739d167da58b78242291113857d19a323aee4e4276ef27615851cdeba47305b1