Blast Radius — Impact Analysis
You map everything a change touches, then hand the operator options. No edits. Evidence over guesses: every claim carries a file:line.
Phase 1 — Pin the Target
State precisely what is changing: class, method, column, enum case, event, config key, view partial — and the nature of the change (signature, behavior, rename, deletion).
Phase 2 — Sweep for Dependents
Grep and read; check every category, report "none" when empty:
- Direct callers — imports, static calls, container resolutions, method calls.
- Events — if the target fires or is fired by events: every producer and every listener.
- Jobs & schedulers — dispatch sites,
Bus::chain/Bus::batch membership, scheduler entries.
- Database — migrations, model casts/fillable, factories, seeders touching affected columns.
- UI — views, components, and JS reading the affected data or routes.
- Tests — every test exercising the target; note which will break vs which protect the change.
- Config & env — config keys, env variables, feature flags referencing the target.
- Serialized/stored references — queued payloads, cached values, string-stored class names, static-analysis baselines (renames rot baselines).
Phase 3 — Classify
Sort every hit into three buckets:
- Breaks — will error or misbehave if the change ships as-is.
- Needs update — keeps working but becomes wrong/stale (docs, seeders, tests, views).
- Unaffected — verified safe; say why in a few words.
Orphan Mode
When asked "is X orphaned / safe to delete": prove zero live references across all Phase 2 categories before endorsing deletion. One live reference = not orphaned; show it. Include soft references (views, config, seeders, docs). Verdict is binary: safe to delete (with the reference-free proof) or not orphaned (with the list).
Output Contract
- Target — what changes, one line.
- Impact table — dependent → category → bucket →
file:line.
- Options — 2–3 ways to make the change, each with effort and risk, ranked. Mark one Recommended and say why in one sentence.
- Test plan — which existing tests gate the change; which new tests the winning option needs.
Stop there. Implementation is a separate, explicit request.
1---2name: blast-radius3description: Trace the full impact of a proposed change or deletion before anything is edited. Use whenever the user says "blast radius", "possible impact", "what does this touch", "what breaks if", "is X orphaned", "safe to delete", "find interconnected classes", or asks to change a shared model, service, event, enum, or config value. Read-only: produces an impact table plus ranked solution options with a recommendation. Never applies the change itself. Required before any modification to code used by more than one feature.4---56# Blast Radius — Impact Analysis78You map everything a change touches, then hand the operator options. **No edits.** Evidence over guesses: every claim carries a `file:line`.910## Phase 1 — Pin the Target1112State precisely what is changing: class, method, column, enum case, event, config key, view partial — and the nature of the change (signature, behavior, rename, deletion).1314## Phase 2 — Sweep for Dependents1516Grep and read; check every category, report "none" when empty:17181. **Direct callers** — imports, static calls, container resolutions, method calls.192. **Events** — if the target fires or is fired by events: every producer and every listener.203. **Jobs & schedulers** — dispatch sites, `Bus::chain`/`Bus::batch` membership, scheduler entries.214. **Database** — migrations, model casts/fillable, factories, seeders touching affected columns.225. **UI** — views, components, and JS reading the affected data or routes.236. **Tests** — every test exercising the target; note which will break vs which protect the change.247. **Config & env** — config keys, env variables, feature flags referencing the target.258. **Serialized/stored references** — queued payloads, cached values, string-stored class names, static-analysis baselines (renames rot baselines).2627## Phase 3 — Classify2829Sort every hit into three buckets:3031- **Breaks** — will error or misbehave if the change ships as-is.32- **Needs update** — keeps working but becomes wrong/stale (docs, seeders, tests, views).33- **Unaffected** — verified safe; say why in a few words.3435## Orphan Mode3637When asked "is X orphaned / safe to delete": prove zero live references across all Phase 2 categories before endorsing deletion. One live reference = not orphaned; show it. Include soft references (views, config, seeders, docs). Verdict is binary: **safe to delete** (with the reference-free proof) or **not orphaned** (with the list).3839## Output Contract40411. **Target** — what changes, one line.422. **Impact table** — dependent → category → bucket → `file:line`.433. **Options** — 2–3 ways to make the change, each with effort and risk, ranked. Mark one **Recommended** and say why in one sentence.444. **Test plan** — which existing tests gate the change; which new tests the winning option needs.4546Stop there. Implementation is a separate, explicit request.