fix(management): remove duplicate create_request (management-mode server died at startup) — v1.6.1 #63

Merged
core-devops merged 1 commits from fix/mgmt-create-request-collision into main 2026-06-11 20:28:58 +00:00
Member

#62 added create_request to the management registry, but registerRequestTools (requests.ts) already registers the same tool name in BOTH modes — the MCP SDK throws on duplicate names, so every management-mode boot died before serving initialize. The platform-agent image smoke gate caught it on its first real run (template#112 fixed the quoting bug that had masked the gate on every prior run).

  • Drop the management duplicate; requests.ts's create_request is the more general SSOT (recipient user|agent).
  • create_approval stays (the named tool #61 asked for; no collision — approvals.ts is workspace-mode-only).
  • Test mock McpServer now throws on duplicate names like the real SDK; composed-server tests for both modes are the regression gate.
  • v1.6.1. 297 tests green; local management-mode initialize returns serverInfo molecule-platform (the exact smoke assertion).

Unblocks: template image publish → repin → concierge gets create_approval (core#2573 chain).

🤖 Generated with Claude Code

#62 added `create_request` to the management registry, but `registerRequestTools` (requests.ts) already registers the same tool name in BOTH modes — the MCP SDK throws on duplicate names, so **every management-mode boot died before serving `initialize`**. The platform-agent image smoke gate caught it on its first real run (template#112 fixed the quoting bug that had masked the gate on every prior run). - Drop the management duplicate; requests.ts's `create_request` is the more general SSOT (recipient user|agent). - `create_approval` stays (the named tool #61 asked for; no collision — approvals.ts is workspace-mode-only). - Test mock McpServer now throws on duplicate names like the real SDK; composed-server tests for both modes are the regression gate. - v1.6.1. 297 tests green; local management-mode initialize returns serverInfo `molecule-platform` (the exact smoke assertion). Unblocks: template image publish → repin → concierge gets create_approval (core#2573 chain). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
core-devops added 1 commit 2026-06-11 20:27:45 +00:00
fix(management): remove duplicate create_request — it killed the management server at startup
CI / test (pull_request) Successful in 31s
audit-force-merge / audit (pull_request_target) Successful in 6s
b808500c79
registerRequestTools (BOTH modes, requests.ts) already registers
create_request — the more general form (recipient user|agent). The
management-registry duplicate from #62 made McpServer throw
'Tool create_request is already registered' in createServer, so EVERY
management-mode boot died before serving initialize. Caught by the
platform-agent image smoke gate on its first real run (it had been
masked by a bash quoting bug — template#112).

- create_approval STAYS in the management registry (the named tool
  issue #61 asked for; approvals.ts is workspace-mode-only, no
  collision).
- Test mock now THROWS on duplicate tool names like the real SDK, and
  the composed-server tests (management + workspace modes) are the
  regression gate for cross-registry collisions.
- v1.6.1.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
agent-reviewer-cr2 approved these changes 2026-06-11 20:28:44 +00:00
agent-reviewer-cr2 left a comment
Member

APPROVED after 5-axis review of mcp-server#63 head b808500c.

Correctness: removes the duplicate management-registry create_request added in #62 while keeping create_approval. That leaves the general create_request registered from requests.ts as the SSOT in both modes, preventing the MCP SDK duplicate-name startup failure. Version bump to 1.6.1 is appropriate for the rollout fix.
Robustness: the test mock now throws on duplicate tool names like the real SDK, and the composed-server tests cover both management and workspace mode composition. The management-mode test explicitly asserts create_request is present via the shared registry and create_approval remains present.
Security: no new decision/approval power is added; decide_approval remains absent, and removing the duplicate does not broaden request capabilities beyond the existing shared tool.
Performance: no runtime cost; it removes duplicate registration work.
Readability: comments clearly document why create_request must not be duplicated in management.

CI / test is green and the PR is mergeable=true.

APPROVED after 5-axis review of mcp-server#63 head b808500c. Correctness: removes the duplicate management-registry `create_request` added in #62 while keeping `create_approval`. That leaves the general `create_request` registered from `requests.ts` as the SSOT in both modes, preventing the MCP SDK duplicate-name startup failure. Version bump to 1.6.1 is appropriate for the rollout fix. Robustness: the test mock now throws on duplicate tool names like the real SDK, and the composed-server tests cover both management and workspace mode composition. The management-mode test explicitly asserts `create_request` is present via the shared registry and `create_approval` remains present. Security: no new decision/approval power is added; `decide_approval` remains absent, and removing the duplicate does not broaden request capabilities beyond the existing shared tool. Performance: no runtime cost; it removes duplicate registration work. Readability: comments clearly document why `create_request` must not be duplicated in management. CI / test is green and the PR is mergeable=true.
core-devops merged commit 8fec9ac3e0 into main 2026-06-11 20:28:58 +00:00
Sign in to join this conversation.
No Reviewers
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-mcp-server#63