RT-171/172/183: mcp tools heal-pair repo lookup, daemon error explain - #297
Conversation
|
Warning Review limit reachedNext included review available in 32 minutes. View limit detailsLimit details: You’ve used the included review currently available. Your 80 included PR review attempts over the past 7 days set your current allowance at 1 review per hour. Your organization has reached its usage spending cap. Adjust your spending cap in the billing tab. Review configuration: ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📥 CommitsReviewing files that changed from the base of the PR and between 3cdd96f86735eb965acf13f9fcba1f52ab0c9c4f and 63ec360. 📒 Files selected for processing (6)
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📥 CommitsReviewing files that changed from the base of the PR and between facced7 and 3cdd96f86735eb965acf13f9fcba1f52ab0c9c4f. 📒 Files selected for processing (6)
Included review availability: 0 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour. 📝 WalkthroughWalkthroughThe change centralizes worktree error explanation, updates MCP repository and gate handling, expands gate end-to-end coverage, and documents ChangesMCP handling and gate coverage
Chat message-link documentation
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Bug fix Sequence Diagram(s)sequenceDiagram
participant MCPServeE2E
participant MCPServer
participant Daemon
MCPServeE2E->>MCPServer: gate_ask for test:mcp-e2e
MCPServer->>Daemon: create gate
Daemon-->>MCPServer: gate ID and subject
MCPServeE2E->>MCPServer: gate_list with open true
MCPServer->>Daemon: list open gates
Daemon-->>MCPServer: created gate
MCPServer-->>MCPServeE2E: gate appears in list
Merge Risk: ⚪ Minimal · up to The updated MCP and documentation paths have no identified actionable merge risk. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 42.86% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 7 functions across 5 files. (1 skipped: 1 unsupported.) ✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Comment |
resolveRepoIdentity now reuses reverseLookupByName (the same heal-pair collapse the CLI's tryResolveRepoArg relies on) instead of a naive label filter, so a legacy-name/identity pair resolves to one match instead of reading ambiguous. fromResponse and mr_map's direct daemon-error returns now run through explainError (moved to lib/explain-error.ts, shared with commands/worktree.ts) so a worktree-domain code comes back as prose instead of bare, decided once for the whole tool roster. RT-171, RT-172
The mcp-serve e2e's tool round trip only exercised gate_list where the wave-2 contract named gate_ask, the epic's centerpiece tool, as the round-trip case. gate_ask had stubbed-client unit coverage only. Extends the same test to call gate_ask (subject resolution, gate:open ceremony) and confirms the opened gate shows up in a follow-up gate_list. RT-183
The post row in the verb table and the viewer-link paragraph were the last two spots in this skill still describing rt chat post as CLI-only, after the rest of the skill was updated to lead with the chat_post/ chat_dm/chat_ack/chat_claim/chat_release tool faces. Names the chat_post tool alongside the CLI form in both spots, and notes the tool returns the message id instead of printing a link (the CLI-only behavior), so the same viewer link can still be built from it. SKILLS-71 (epic review F6)
fromResponse's generic explainError maps "not-found" to a worktree-trash message (RT-172's shared explainer), which is wrong-domain for a gate id that does not exist. gate_answer already special-cases owned-by and gate-closed; not-found joins them. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…fusal RT-177 (merged to main after this branch forked) refuses a human-owned gate:ask with no context. This test's gate_ask call had none. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
3cdd96f to
63ec360
Compare
…#297) * mcp tools: share heal-pair repo lookup, explain daemon errors resolveRepoIdentity now reuses reverseLookupByName (the same heal-pair collapse the CLI's tryResolveRepoArg relies on) instead of a naive label filter, so a legacy-name/identity pair resolves to one match instead of reading ambiguous. fromResponse and mr_map's direct daemon-error returns now run through explainError (moved to lib/explain-error.ts, shared with commands/worktree.ts) so a worktree-domain code comes back as prose instead of bare, decided once for the whole tool roster. RT-171, RT-172 * e2e: round-trip gate_ask against the test daemon The mcp-serve e2e's tool round trip only exercised gate_list where the wave-2 contract named gate_ask, the epic's centerpiece tool, as the round-trip case. gate_ask had stubbed-client unit coverage only. Extends the same test to call gate_ask (subject resolution, gate:open ceremony) and confirms the opened gate shows up in a follow-up gate_list. RT-183 * skills/rt-chat: fix CLI-first residues (verb-table row, viewer note) The post row in the verb table and the viewer-link paragraph were the last two spots in this skill still describing rt chat post as CLI-only, after the rest of the skill was updated to lead with the chat_post/ chat_dm/chat_ack/chat_claim/chat_release tool faces. Names the chat_post tool alongside the CLI form in both spots, and notes the tool returns the message id instead of printing a link (the CLI-only behavior), so the same viewer link can still be built from it. SKILLS-71 (epic review F6) * mcp gate_answer: return a gate-domain message for an unknown gate id fromResponse's generic explainError maps "not-found" to a worktree-trash message (RT-172's shared explainer), which is wrong-domain for a gate id that does not exist. gate_answer already special-cases owned-by and gate-closed; not-found joins them. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * e2e: pass context to gate_ask so the round trip satisfies RT-177's refusal RT-177 (merged to main after this branch forked) refuses a human-owned gate:ask with no context. This test's gate_ask call had none. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> --------- Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
Documentation