fix(missions): supersede stale generated fix features#1928
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
🚧 Files skipped from review as they are similar to previous changes (4)
📝 WalkthroughWalkthroughThis PR adds reconciliation for superseded generated fix features after validator passes and during active mission recovery. It updates mission-store, engine recovery flow, tests, and adds a patch changeset. ChangesSuperseded Generated Fix Reconciliation
Estimated code review effort: 3 (Moderate) | ~25 minutes Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Greptile SummaryThis PR cleans up stale generated mission fix work after the source work passes validation. The main changes are:
Confidence Score: 5/5This looks safe to merge.
Important Files Changed
Reviews (2): Last reviewed commit: "fix(missions): address generated fix rev..." | Re-trigger Greptile |
There was a problem hiding this comment.
Pull request overview
This PR prevents stale generated mission Fix Features from remaining active once an ancestor/source feature has passed validation, by reconciling (superseding) obsolete generated-fix chains both at validator-pass time (core) and during active-mission recovery (engine).
Changes:
- Add
MissionStore.reconcileSupersededGeneratedFixFeatures(sliceId)and invoke it when a validator run completes withpassed. - Invoke supersession reconciliation during
MissionExecutionLoop.recoverActiveMissions()for active slices to clean up stale fix chains during recovery. - Add core mission-store tests for supersession behavior, plus a changeset for
@runfusion/fusion.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/engine/src/mission-execution-loop.ts | Runs superseded-fix reconciliation during active mission recovery. |
| packages/engine/src/tests/mission-execution-loop.test.ts | Extends the mock mission store to include the new reconciliation method. |
| packages/core/src/mission-store.ts | Implements reconciliation of superseded generated-fix features and triggers it on validator pass. |
| packages/core/src/tests/mission-store.test.ts | Adds tests covering supersession of generated-fix descendants and pass-triggered reconciliation. |
| .changeset/fuzzy-missions-heal.md | Publishes a patch changeset describing the behavior change. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/core/src/mission-store.ts`:
- Around line 3214-3220: The superseded-fix handling in updateFeature is leaving
the linked task active even after the feature is marked done/passed. In the
supersededFeatureIds loop inside mission-store.ts, extend the cleanup performed
by updateFeature so it also clears task ownership by removing taskId, or
otherwise reuses the same unlink/archive behavior used by unlinkFeatureFromTask
and deleteFeature. Make sure the feature no longer keeps a live board task
attached once it is superseded.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: f94ff74f-db8e-4164-8dbf-f396f507248a
📒 Files selected for processing (5)
.changeset/fuzzy-missions-heal.mdpackages/core/src/__tests__/mission-store.test.tspackages/core/src/mission-store.tspackages/engine/src/__tests__/mission-execution-loop.test.tspackages/engine/src/mission-execution-loop.ts
Summary
Test Plan
Summary by CodeRabbit