forked from bai/curriculum-project-hub
fix(hub): ship checklist via cph_hub todo_write MCP tool
Native Claude TodoWrite is not registered in headless agent mode even with --tools default. Add mcp__cph_hub__todo_write (always enabled), mirror the TodoWrite schema, instruct multi-step runs to use it, and keep the Feishu progress panel parsing both native and hub tool names.
This commit is contained in:
@@ -186,7 +186,13 @@ describe("runAgent", () => {
|
||||
expect(queryMock.mock.calls[0]?.[0]).toMatchObject({
|
||||
options: {
|
||||
tools: ["Read", "Bash", "TodoWrite"],
|
||||
allowedTools: ["Read", "Bash", "mcp__cph_hub__send_file", "TodoWrite"],
|
||||
allowedTools: [
|
||||
"Read",
|
||||
"Bash",
|
||||
"mcp__cph_hub__send_file",
|
||||
"TodoWrite",
|
||||
"mcp__cph_hub__todo_write",
|
||||
],
|
||||
settings: expect.objectContaining({ todoFeatureEnabled: true }),
|
||||
},
|
||||
});
|
||||
@@ -209,7 +215,7 @@ describe("runAgent", () => {
|
||||
expect(queryMock.mock.calls[0]?.[0]).toMatchObject({
|
||||
options: {
|
||||
tools: ["TodoWrite"],
|
||||
allowedTools: ["TodoWrite"],
|
||||
allowedTools: ["TodoWrite", "mcp__cph_hub__todo_write"],
|
||||
settings: expect.objectContaining({ todoFeatureEnabled: true }),
|
||||
},
|
||||
});
|
||||
@@ -239,6 +245,7 @@ describe("runAgent", () => {
|
||||
expect(queryMock.mock.calls[0]?.[0]).toMatchObject({
|
||||
options: {
|
||||
tools: ["TodoWrite", "Skill"],
|
||||
allowedTools: expect.arrayContaining(["TodoWrite", "mcp__cph_hub__todo_write", "Skill"]),
|
||||
plugins: [expect.objectContaining({ type: "local", skipMcpDiscovery: true })],
|
||||
skills: ["cph-runtime:typst"],
|
||||
settings: expect.objectContaining({ todoFeatureEnabled: true }),
|
||||
|
||||
Reference in New Issue
Block a user