Conversation
…item cancel action, handoff defaults to inbox
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe handoff command now defaults to ChangesHandoff command defaults
Item workflows
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant MCPCaller
participant item_inner
participant ItemStateData
MCPCaller->>item_inner: request item.list with filters and pagination
item_inner->>ItemStateData: resolve states and retrieve items
ItemStateData-->>item_inner: item rows and state definitions
item_inner-->>MCPCaller: sorted paginated ItemSummary results
Possibly related PRs
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 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 `@src/mcp_server.rs`:
- Around line 2626-2643: Update the valid-action lists in the `item_inner`
unknown-action error and the `item()` tool description to include `cancel`,
matching the actions already enumerated by `ItemRequest.action`. Keep the
existing ordering and wording consistent across both locations.
- Around line 2626-2643: The cancel branch must release any active claim in
addition to updating the item state. Within the `with_backend_db` closure for
`"cancel"`, clear the item’s claim after `update_state` succeeds, using the
existing claim-management API, and preserve the current validation and response
behavior.
- Around line 2449-2454: Update the pagination handling around the offset and
limit calculations to reject negative req.offset and req.limit values with the
existing invalid_params error path instead of clamping them to zero. Preserve
zero and positive values and the current skip/take behavior for valid requests.
🪄 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: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: fbd42f7f-4385-4704-a095-809e7abe1ffc
📒 Files selected for processing (2)
src/mcp_prompts.rssrc/mcp_server.rs
…ve limit/offset, cancel in tool description
What
item(list):assignee_agentwas a dead parameter (onlystate_groupwas applied). Now filters to items assigned to that agent OR unassigned, sorted open+assigned-to-you first — surfaces claimable work alongside your own. Addedlimit/offsetpagination. Response is now a leanItemSummaryprojection (id, name, state name+group resolved fromstate_id, priority, assignee_agent, parent_id, sequence_id, updated_at) instead of the full 19-fieldItemrow —getis unchanged for full detail.itemtool: newcancelaction, mirrorsdone— resolves the project's existing Cancelled state viastate::first_in_groupand moves the item there. Agentflare already seeds a Cancelled state per project (matches Plane'sStateGroupexactly) but nothing could set it./handoff: bare invocation (no argument) now defaults toinboxinstead of printing a usage card.Verification
cargo test --bin agentflare: 417 passed, 0 failed (7 new tests)cargo clippy --all-targets -- -D warnings -A unsafe_code -A clippy::pedantic: cleancargo fmt --check: cleanitem(claim)auto-creates an isolated worktree (.worktrees/task/36) — this change was built and tested entirely inside that worktree.Summary by CodeRabbit
limit/offsetpagination (validated to be non-negative)./handoffnow defaults to the inbox view while retaining agent identity.