BOHICA-LABS / BOHICA-LABS/vsdd-factory

process-gap(story-writer): orphan-component pattern recurring — story template lacks mandatory Integration Wiring AC

Open
#289 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
2
Forks
1
Avg merge
6h 43m
Merged PRs (30d)
29

Description

## Class of failure

When a story introduces a new component that subscribes to inputs/signals (autoload, scene-attached controller, dispatcher), the orphan-component pattern keeps surviving the green test suite because tests use direct method-call injection rather than exercising the real wiring (Input → handler → component → signal).

## Pattern observed (3 recurrences in one project's Wave 1)

In an external Godot/GDScript pilot using VSDD methodology:

| Symptom # | Story | Defect class |
|---|---|---|
| 1 | STORY-A.AA.XXX (HUD display) | HUD scene reachable via `load().instantiate()` in tests, but production main_scene never instances it. All 12 unit tests green; production E-press = silent no-op. |
| 2 | STORY-A.AA.YYY (ability dispatcher) | AbilityDispatcher.dispatch_interact() unit-tested via direct synthetic-array injection. Production `interact` input action declared but no `_unhandled_input` handler reads it. Pressing E in production = silent no-op. |
| 3 | STORY-A.AA.YYY Pass-2 follow-up | "Fix" for #2 added `_unhandled_input` handler + AbilityTarget._ready() that walks the "player" group. But in typical scene-load ordering (targets dropped into zone before player enters), target._ready() runs with empty group → no connect → silent no-op AGAIN. Integration test only passed because it added the player before the target. |

Each symptom was caught by adversarial Pass-1 only because the orchestrator instructed the adversary to scrutinize "where production code reads this input action / signal." Without that lens, all 12+8+18 unit tests are GREEN against an orphaned component.

## Root cause (template-level)

The story-writer template doesn't mandate an explicit "Integration Wiring AC" that:
- (a) Production main_scene-reachable wiring loads the component
- (b) Test exercises the real signal/input pipeline (not a direct method call with a synthetic argument)
- (c) Scene-load ordering tested in BOTH directions (component-before-consumer AND consumer-before-component)

Without these, the adversary's "find missing wiring" heuristic is the only line of defense, and that heuristic has a 3-of-3 miss rate when applied to fix attempts without explicit AC anchoring.

## Proposed remediation

**Option A — Story-writer template mandatory AC**: Every story that introduces a new component subscribing to inputs/signals MUST include an "Integration Wiring AC" with the (a)/(b)/(c) requirements. Story-writer agent rejects stories that introduce subscribers without this AC.

**Option B — Adversary heuristic codification**: Adversary template includes a mandatory "orphan-component check" — grep for the new component's class name / signal subscription, verify it appears in a production scene-tree load path or autoload list.

Option A is preventive (catches at story-writing time). Option B is detective (catches at adversarial pass). Both close the gap; A is cheaper.

## Labels

- `process-gap`
- `story-writer`
- `adversary`
- `phase-2`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.