diff --git a/docs/plans/2026-05-08-remove-retro-stage-plan.md b/docs/plans/2026-05-08-remove-retro-stage-plan.md new file mode 100644 index 000000000..bbfd50a9f --- /dev/null +++ b/docs/plans/2026-05-08-remove-retro-stage-plan.md @@ -0,0 +1,34 @@ +# Remove Retro Stage Entirely + +## Summary + +Delete the retro feature as a product/runtime concept, with no compatibility shims. The workflow pipeline becomes `initialize -> execute -> finalize -> pull_request`; there will be no retro agent, retro events, retro projection state, retro config, `--no-retro` flag, API fields, UI feature flag, PR retro section, or active docs/marketing references. + +## Key Changes + +- Runtime pipeline: delete `lib/crates/fabro-workflow/src/pipeline/retro.rs`, remove `RetroOptions`/`Retroed`, and change `finalize` to consume `Executed` directly after `execute`. +- Types and storage: delete `fabro-types::retro`, remove `RunProjection.retro`, `retro_prompt`, and `retro_response`, remove retro event variants/props from `fabro-types` and `fabro-workflow::event`, and remove retro projection handling from `fabro-store`/`fabro-dump`. +- Historical events: remove `retro.started`, `retro.completed`, and `retro.failed` from the `is_known_event_name` strict-deserialization whitelist so old stored retro events fall through to `EventBody::Unknown` instead of failing deserialization after the typed variants are deleted. +- Dependencies: remove the `fabro-retro` crate directory and all `fabro-retro` dependencies from `fabro-workflow`, `fabro-cli`, and `fabro-server`; let `Cargo.lock` be regenerated by Cargo. +- Config: remove `[run.execution].retros` from `fabro-config` defaults, run layer types, resolver output, obsolete-key hints, builders, and tests; remove the matching dense settings field from `fabro-types`. +- CLI/API: remove `--no-retro`, `ManifestArgs.no_retro`, `SystemFeatures.retros`, and `RunExecutionSettings.retros`; update `docs/public/api-reference/fabro-api.yaml`, rebuild `fabro-api`, and regenerate `lib/packages/fabro-api-client`. +- CLI event rendering: remove raw event-name handling for `retro.started`, `retro.completed`, and `retro.failed` from `lib/crates/fabro-cli/src/commands/run/events.rs` so retired retro events render only through the generic unknown-event path. +- PR content: remove `format_retro_section`, stop reading retro state for PR bodies, and update PR body tests so only plan details and Fabro Details remain. +- UI/docs/site/agent guidance: remove current active retro references from `apps/fabro-web`, `README.md`, `AGENTS.md`, `docs/public`, `docs/public/docs.json`, `docs/internal/events*.md`, product docs, marketing content, `evals/`, `test/retro-e2e.fabro`, and CLI test fixtures; delete `docs/public/execution/retros.mdx` and unused retro screenshots. + +## Test Plan + +- Run codegen: `cargo build -p fabro-api` and `cd lib/packages/fabro-api-client && bun run generate`. +- Extend and rename the existing table-driven `retired_sandbox_snapshot_events_deserialize_as_unknown` regression test so it also proves `retro.started`, `retro.completed`, and `retro.failed` deserialize as `EventBody::Unknown` with properties preserved. +- Update `lib/crates/fabro-api/tests/run_projection_round_trip.rs` and related JSON/API parity tests so `RunProjection` no longer requires or serializes `retro`, `retro_prompt`, or `retro_response`. +- Update CLI command, workflow, scenario, and fixture tests that currently pass `--no-retro` or assert `no_retro`/`retros`/retro projection fields; delete the dedicated retro-enabled runner test rather than rewriting it around removed behavior. +- Rust verification: `cargo nextest run --workspace`, `cargo +nightly-2026-04-14 fmt --check --all`, and `cargo +nightly-2026-04-14 clippy --workspace --all-targets -- -D warnings`. +- Frontend/docs verification: run `cd apps/fabro-web && bun run typecheck && bun test` and `cd apps/marketing && bun run build`, in parallel when possible; run `cd apps/fabro-web && bun run build` only if build-script test coverage is skipped or frontend asset output changed. +- Snapshot flow: after test failures from removed CLI flags/help output, run `cargo insta pending-snapshots`, inspect expected changes, then accept only the intended snapshots. +- Final grep check over tracked active files for `retro`, `retros`, `Retro`, and `no_retro`, excluding archival plans/brainstorms/changelogs unless explicitly scrubbed. + +## Assumptions + +- No deprecation path: old config keys, CLI flags, API fields, generated client fields, and typed retro events are removed rather than translated. +- Existing stored retro events are not migrated; they must deserialize as `EventBody::Unknown` with original properties preserved, and no runtime projection or UI will surface them. +- Historical planning docs and changelog entries can remain as archive; active product docs, API docs, internal event references, and marketing copy should be scrubbed.