2.0 KiB
2.0 KiB
Plan: Story 919
ACs → implementation locations
- AC 1 (
MergeFailure + Unblock → Merge):server/src/pipeline_state/transition.rs:295— changeOk(Coding)toOk(Merge { feature_branch, commits_ahead }). Also requires addingfeature_branch: BranchNameandcommits_ahead: NonZeroU32toStage::MergeFailureinserver/src/pipeline_state/types.rs:113, and carrying those fields through theMerge → MergeFailuretransition attransition.rs:200. - AC 2 (
Coding (blocked) + Unblock → Codingunchanged):server/src/pipeline_state/transition.rs:289—(Blocked { .. }, Unblock) => Ok(Coding)already correct; no change needed. - AC 3 (regression test):
server/src/pipeline_state/tests.rs— addmerge_failure_unblock_returns_to_mergeCRDT-based test.
Decisions
- Add
feature_branchandcommits_aheadtoMergeFailure(rather than use synthetic defaults in the transition): allows the exact merge state to be restored on Unblock. Rejected: synthetic values at transition time (would require story_id not available in the transition function, or use a placeholder that loses the real branch name). - Update all
Stage::MergeFailure { reason }construction sites to include the new fields with synthetic defaults where real values are unavailable (CRDT read,from_dir, migration).
Current state
Not started — fresh session.
What's left
- Add
feature_branch: BranchNameandcommits_ahead: NonZeroU32toStage::MergeFailureintypes.rs - Update
types.rsfrom_dirconstruction ofMergeFailure - Update
transition.rs: carry fields inMerge → MergeFailure, self-loop, fixMergeFailure + Unblock → Merge - Update
crdt_state/read.rsMergeFailureconstruction - Update
crdt_state/write/migrations.rsMergeFailureconstruction - Update
tests.rs: allStage::MergeFailure { .. }constructions, rename+fix unblock test - Add CRDT-based regression test (AC3)
- Run run_check, fix any clippy/fmt issues
- Run run_tests, commit