claude-task-master icon indicating copy to clipboard operation
claude-task-master copied to clipboard

bug: Claude Code fails to engage with the Task Master

Open igormoochnick opened this issue 6 months ago • 2 comments

Description

There are a couple of problems.

  1. Claude code prefers to use projectplan.md (not PRD)
  2. Claude code doesn't like the current MCP configuration of the Task Master

Steps to Reproduce

  1. Create a simple project with claude code in Cursor
  2. Ask claude code anything about task master

Expected Behavior

Claude Code should be able to answer questions about tasks

Actual Behavior

Claude Code doesn't know and doesn't see configured Task Master MCP in the project

Screenshots or Logs

...

Environment

  • Task Master version: 0.17.0
  • Node.js version: v20.18.0
  • Operating system: Mac Sequoya 15.5
  • IDE (if applicable): Cursor 1.0

Additional Context

My assumption if the project called "claude-task-master" there should be some integration with Claude Code, unless I'm incorrectly interpreting the name?

igormoochnick avatar Jun 15 '25 14:06 igormoochnick

Can I see your mcp.json ?

Crunchyman-ralph avatar Jun 15 '25 17:06 Crunchyman-ralph

sure. Below is the mcp.json that was generated and located in .cursor/mscp.json path:

{
    "mcpServers": {
        "task-master-ai": {
            "command": "npx",
            "args": [
                "-y",
                "--package=task-master-ai",
                "task-master-ai"
            ],
            "env": {
                "ANTHROPIC_API_KEY": "XXX",
                "PERPLEXITY_API_KEY": "YYY"
            }
        }
    }
}

igormoochnick avatar Jun 15 '25 21:06 igormoochnick

same issue for me, I get the following errors

[DEBUG] MCP server "task-master": Connection failed: McpError: MCP error -32000: Connection closed
[DEBUG] MCP server "task-master": Error message: MCP error -32000: Connection closed
[DEBUG] MCP server "task-master": Error stack: McpError: MCP error -32000: Connection closed
    at Wl1._onclose (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1321:12595)
    at _transport.onclose (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1321:12095)
    at ChildProcess.<anonymous> (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1323:1444)
    at ChildProcess.emit (node:events:507:28)
    at ChildProcess.emit (node:domain:489:12)
    at maybeClose (node:internal/child_process:1101:16)
    at Socket.<anonymous> (node:internal/child_process:457:11)
    at Socket.emit (node:events:507:28)
    at Socket.emit (node:domain:489:12)
    at Pipe.<anonymous> (node:net:351:12)

with the following MCP config

"mcpServers": {
    "telegram-mcp": {
      "type": "stdio",
      "command": "uv",
      "args": [
        "--directory=/Users/awallis/dev/telegram-mcp",
        "run",
        "main.py"
      ],
      "env": {}
    },
    "task-master": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "--package=task-master-ai",
        "task-master-ai"
      ],
      "env": {
        "OPENROUTER_API_KEY": "sk-or-v1-REDACTED",
        "MODEL": "anthropic/claude-sonnet-4",
        "MAX_TOKENS": 128000000,
        "TEMPERATURE": 0.2,
        "DEFAULT_SUBTASKS": 5,
        "DEFAULT_PRIORITY": "medium"
      }
    }
  },

adawalli avatar Jun 19 '25 22:06 adawalli

I tried in both user context and project context with the same results :(

adawalli avatar Jun 19 '25 22:06 adawalli

@igormoochnick , try following the steps in here: https://github.com/eyaltoledano/claude-task-master/issues/761

remove "--package=task-master-ai", for some reason, that other issue was closed as a bug, but this is clearly not user induced when we are following the docs

adawalli avatar Jun 19 '25 22:06 adawalli

Is claude code supposed to use the MCP through Cursor? Or are we supposed to get claude code to run its own instance of the server? If so what is the command for that. All it wants to do is read the raw file version of the task master tasks for me.

SmartCarrion avatar Jun 27 '25 04:06 SmartCarrion

Is claude code supposed to use the MCP through Cursor? Or are we supposed to get claude code to run its own instance of the server? If so what is the command for that. All it wants to do is read the raw file version of the task master tasks for me.

I think it effectively calls claude -p, so no, I don't think you need to run an MCP or do anything special - just have claude installed and configured

adawalli avatar Jun 29 '25 15:06 adawalli

you need to have a different mcp file either at your project level in the form of .mcp.json by using the claude cli for adding MCP servers. in your ~/.claude.json if you search mcpServers you'll find project level and global mcp configs as well https://claudelog.com/configuration#mcp-configuration

arielhauter avatar Jun 30 '25 09:06 arielhauter

Is there any way to NOT use cursor and just use Claude Code ? Where do we put the mcp json ? It seems like Claude Code with a task master mcp added never ends up calling the tool.

marko911 avatar Jul 15 '25 06:07 marko911

improved and implemented as of 0.20.0, but this can be improved by adding a .mcp.json into the claude code rules @joedanz

Crunchyman-ralph avatar Jul 15 '25 12:07 Crunchyman-ralph

Ah, didn’t realize the support file-based now. Will get that added to the Claude profile, thanks!

joedanz avatar Jul 15 '25 12:07 joedanz

Added .mcp.json as part of 0.21.0

Crunchyman-ralph avatar Jul 23 '25 15:07 Crunchyman-ralph