KBCodeKB
42 issues

Fix MCP SDK Zod v4 Incompatibility: "_parse is not a function" and "_def" Errors (-32603) in Claude Desktop, Cursor, VS Code, and Cline

Unverified

The MCP TypeScript SDK (v1.17.5 and earlier) is incompatible with Zod v4.x due to breaking changes in Zod's internal API. When a project has Zod v4 installed, MCP servers fail with JSON-RPC error code -32603: 'w._parse is not a function' or 'null is not an object (evaluating F._def)'. The MCP SDK has a hard dependency on Zod ^3.23.8 and directly calls internal Zod v3 methods (_parse, _def) that were removed or changed in Zod v4. Package manager hoisting can cause silent runtime mismatches: even when `npm list zod` shows v3, a hoisted Zod v4 from another dependency may win at runtime in monorepos. The error manifests in ALL MCP client applications: Claude Desktop, Cursor, VS Code, Cline, and any tool using the MCP TypeScript SDK. MCP maintainer felixweinberger shipped a backward-compatible fix in v1.23.0-beta.0 (November 2025) that supports both Zod v3 and v4 via dependency change to `^3.25 || ^4.0`, stable in v1.23.1+. Verified: `npm view @modelcontextprotocol/sdk@1.17.5 dependencies.zod` returns `^3.23.8`, `npm view @modelcontextprotocol/sdk@1.23.1 dependencies.zod` returns `^3.25 || ^4.0`. Latest SDK as of June 2026 is v1.29.0.

Fix Claude Code v2.1.120 Regression: --resume/--continue Crash ('g9H is not a function') and 'sandbox required but unavailable' on macOS, Linux, and Windows

Unverified

Claude Code v2.1.120 (auto-updated April 24-25, 2026) introduced a critical regression that broke all --resume and --continue functionality. Two distinct crash modes were reported: (1) REPL mount crash with 'g9H is not a function. (In g9H(K), g9H is undefined)' — caused by an undefined onSessionRestored callback in the REPL component, and (2) 'sandbox required but unavailable' error on resume even when sandbox.enabled=false in settings — caused by the resume code path consulting the sandbox gate before honoring user settings. Both were confirmed cross-platform (macOS, Linux, Windows). Anthropic acknowledged the regression within hours and rolled back the auto-update pointer from v2.1.120 to v2.1.119. Users on v2.1.120 can work around by rolling back to v2.1.119 or using /resume inside a fresh interactive session. The fix shipped in v2.1.121+ (auto-updater restores working version).

Fix Claude Desktop MCP Tools Failing with 'Required' Parameter Error — Missing arguments in JSON-RPC tools/call (July 2025 Regression)

Unverified

On July 23, 2025, all MCP tools in Claude Desktop suddenly stopped working with parameter validation errors. Every tools/call JSON-RPC request was sent WITHOUT the required 'arguments' field, causing all MCP servers to reject tool calls with: 'expected: object, received: undefined' / 'Required' / 'Cannot convert undefined or null to object'. The first tool call in a fresh conversation would work, but all subsequent calls failed because the arguments parameter was stripped from the JSON-RPC params. Affected ALL MCP servers — local filesystem, remote proxies, first-party connectors (Atlassian/Jira, Asana, Slack), and custom MCP servers alike. Root cause: upstream Anthropic API failure on July 23, 2025 that emitted malformed tool-use content blocks without arguments, which Claude Desktop relayed directly to MCP servers. Anthropic staff (ollie-anthropic) confirmed the issue as an 'upstream API failure affecting all MCP tool calls' and deployed a server-side fix within hours, requiring only a Claude Desktop restart. Status page incident: https://status.anthropic.com/incidents/9px1qykyb9w4. Impact: 59 community reactions, 66 comments — a global MCP outage affecting all Claude Desktop users. Agent Decision Tree: (1) Check if this is a historical event — the bug occurred July 23, 2025 and was fixed same day. If user reports are from July 23, 2025, verify with dates. (2) If symptoms match but date is different, this may be a new incident — check https://status.anthropic.com/ for current outages. (3) First diagnostic: inspect MCP server logs for tools/call params. If params contain only '"name":"tool_name"' without '"arguments":{...}', this is the bug. (4) If first call works and subsequent calls fail, this is the classic signature. (5) Apply Solution 1 (restart + fresh conversation). (6) If problem persists after restart, escalate to Anthropic support with MCP server log excerpts.

mcp

Fix Claude Agent SDK Not Reading .mcp.json Project-Scoped MCP Servers (v2.0.71+) — Conductor, CI/CD, and Non-Interactive Environments

Unverified

The Claude Agent SDK (`query()` function) does not read project-scoped MCP servers from `.mcp.json` on startup, even with `settingSources: ['project']`. MCP servers only become available after manually launching `claude` CLI, running `/mcp`, then restarting the SDK. This blocks all non-interactive environments including CI/CD pipelines and automation platforms like Conductor. User-scoped and local-scoped MCPs load correctly — only project-scoped `.mcp.json` is affected. Fix shipped in v2.0.71 (December 16, 2025), confirmed by Anthropic staff assignee ollie-anthropic: 'this should be fixed in the latest release coming out today.'

Fix VS Code Claude Code "Not Responding" Session Hang (v2.1.84) — No Stop/Recover Button for Stuck Tasks

Unverified

When Claude Code running in VS Code (v2.1.84 and earlier) gets stuck during a multi-step task, the UI displays "Not responding - try stopping" but provides NO actionable way to stop, cancel, or recover. The session becomes a dead end — users must force-quit VS Code and lose all progress, including completed tasks upstream of the stall. This occurs when a task involves an external operation (e.g., `gh repo create`, network calls) that hangs beyond the backend heartbeat timeout of 60 seconds. The spinner turns red but there is no stop button, cancel button, retry option, or task-skip mechanism. Anthropic staff member qing-ant confirmed the timeout was too aggressive and deployed a fix in the March 27, 2026 release (v2.1.86). The affected version v2.1.84 was published March 25, 2026 and the fix version v2.1.86 was published March 27, 2026 — same day the issue was closed. Latest Claude Code as of June 13, 2026 is v2.1.177.

Fix Claude Code Native Terminal Cursor Tracking for Screen Readers (NVDA, VoiceOver, BRLTTY), CJK IME, and Accessibility — on Linux, macOS, and Windows

Unverified

Claude Code's TUI renderer did not position the terminal's native cursor to follow the text input caret. This broke screen readers (BRLTTY, NVDA, JAWS, VoiceOver, Orca, Narrator) which track the cursor to decide what to display, caused CJK IME preedit/composition text to appear at the bottom-left corner instead of at the insertion point, and prevented screen magnifiers from following user input. The native cursor remained stuck at the bottom of the screen, making it impossible for blind and low-vision users to edit prompts or know where their cursor was. Root cause: the custom TUI renderer uses a full-screen overwrite model where the last render write determines cursor position — the cursor was not declaratively positioned to follow the text input caret. Fixed in v2.1.84 when qing-ant added declarative cursor positioning. Latest version as of June 2026 is v2.1.177.

Fix Scheduled Routines MCP 'Tool Call Requires Approval' Error on Claude.ai with Custom and First-Party Connectors (May 2026 Regression)

Unverified

A regression introduced around 2026-05-20 caused every MCP tool call inside claude.ai scheduled routines to fail with 'Streamable HTTP error: Error POSTing to endpoint: MCP tool call requires approval', silently no-oping all connector-dependent automations. The bug affected 18+ first-party connectors (Slack, Atlassian/Jira, Gmail, Google Calendar, Google Drive, Datadog, Sentry, Notion, Linear, Figma, Amplitude, Guru, Ramp, Zapier, monday.com, Todoist, Snowflake, Microsoft 365) and all custom OAuth MCP connectors. Root cause: the platform's permission model treated interactive approval (call-time 'ask the user') and unattended approval (bind-time grant from routine config) as a single gate, so routines with no human present silently failed. The permitted_tools field on mcp_connections was not being honored as a standing grant for the non-interactive routine surface. Anthropic deployed a platform-side fix within ~10 hours of acknowledgment. Local CLI cron jobs using the same connectors worked throughout as a temporary workaround.

Fix MCP Python SDK sse_app() Mount Prefix 404 Error in Starlette, FastAPI, and Custom MCP Servers

Unverified

The MCP Python SDK's `sse_app()` method ignores URL mount prefixes when generating SSE message endpoint URIs. When an MCP server is mounted under a prefix via Starlette's `Mount()` or FastAPI's `app.mount()`, the SSE handshake returns `/messages/` instead of `/<prefix>/messages/`. MCP clients then POST to the wrong URL, receiving HTTP 404. This affects all environments using non-root-mounted MCP servers — including Claude Desktop, Cursor, VS Code, and custom MCP clients. Fixed in mcp >= 1.9.0 via PR #659, which reads the ASGI `root_path` scope attribute for proper prefix inference.

Fix Claude Code Terminal Display Corruption: Garbled Characters, Gibberish Text, and Unreadable Output in macOS Terminal, VS Code, and JupyterLab (v2.1.142–v2.1.145+)

Unverified

Starting around Claude Code v2.1.142 (May 2026), the terminal display becomes progressively corrupted during sessions — all output renders as garbled symbols, random characters, and unreadable text instead of clean English/ASCII. This affects: (1) shell prompts and user input appearing as random symbols, (2) all Claude Code assistant responses, system messages, and status updates rendering as gibberish, (3) table/box-drawing characters showing corrupted line-drawing symbols instead of clean ASCII borders, (4) the corruption persisting across the entire session from start to finish with no readable sections, and (5) getting progressively worse with continued usage until the terminal is almost completely unusable. Anthropic staff (bcherny) acknowledged the issue and diana-ant reported it fixed in v2.1.144 (May 18, 2026), but multiple users confirmed the corruption persists in v2.1.144 and v2.1.145 in VS Code integrated terminal and JupyterLab terminal on macOS. The corruption may be correlated with the /goal command introduced in v2.1.142. Workarounds include: resizing the terminal window, toggling full-screen mode, using /save and /resume to restore readability, or downgrading to v2.1.141 (last known-good version before /goal was introduced).

claude-code

Fix Claude Code API Error 400: Image Dimensions Exceed 2000px — Conversation Permanently Broken on macOS, Linux, and Windows After Pasting Large Images

Unverified

When a user pastes an image exceeding 2000px dimensions into Claude Code, the API returns a 400 error: 'At least one of the image dimensions exceed max allowed size for many-image requests: 2000 pixels'. The critical issue is that the oversized image remains in the conversation history, causing ALL subsequent requests to fail with the same error — even plain text messages with no images attached. Users must either use the /compact command to remove the offending image from context, or start a completely new conversation and manually reconstruct context. This is a regression bug (worked in prior versions) with 90+ reactions and 110+ comments from affected users across all platforms (macOS, Linux, Windows). The issue was reported as early as v2.0.28 and was closed as completed. The root cause is that Claude Code performs client-side image validation AFTER adding images to the conversation buffer — the API rejects the oversized image but the client keeps resending it with every subsequent request because the image is already committed to the message store. Community workarounds include using /compact (which compresses conversation history and drops the oversized image) or a manual fix documented by the community involving clearing the image from message history.

claude-code

Fix Claude Code tmpclaude-*-cwd Temp File Pollution in Working Directory on Windows, VS Code, and GitHub Copilot — Cleanup Script Included

Unverified

Claude Code v2.1.5+ creates `tmpclaude-*-cwd` temporary files directly in the current working directory instead of the system temp directory (`%TEMP%` or `/tmp`). These files accumulate over sessions — users report 119+ files in a single 2.5-hour session — and are never automatically cleaned up. Each file contains a Unix-style path (e.g., `/c/Users/.../project`) and clutters git status output. This is a regression from the original fix in issue #8856, where temp files were correctly placed in `/tmp/claude-*-cwd`. The regression changed both the naming pattern (from `claude-*-cwd` to `tmpclaude-*-cwd`) and the location (from system temp to working directory). The issue primarily affects Windows users (Git Bash, PowerShell, CMD) but also occurs on macOS/Linux and in VS Code when Claude Code is invoked via agent handoff or GitHub Copilot delegation. Anthropic staff (@ashwin-ant) reopened the issue after initial bot-closure, personally merged the fix on February 18, 2026 (commit b757fc9), shipping in v2.1.47+. The latest Claude Code version as of June 12, 2026 is v2.1.175. Users on older versions should upgrade to v2.1.47 or later. For users who cannot upgrade immediately, community cleanup scripts and .gitignore entries provide effective mitigation. 88 reactions and 72 comments confirm widespread impact.

claude-code

Fix Claude Code API Error 400: 'tool_use ids were found without tool_result blocks' from Parallel Tool Execution in Claude Desktop, VS Code, and Cursor

Unverified

Claude Code throws 'API Error: 400 due to tool use concurrency issues' with message 'tool_use ids were found without tool_result blocks immediately after' when parallel tool execution creates mismatched tool_use/tool_result pairs in the API request. This affects Claude Desktop, VS Code Claude extension, and Cursor users with PostToolUse hooks, complex CLAUDE.md instructions, and multi-tool workflows. Root cause: Claude Code's default parallel execution sends multiple tool_use blocks concurrently; when PostToolUse hook output triggers additional user messages mid-stream, the Anthropic API receives tool_use ids without corresponding tool_result blocks and rejects the request with HTTP 400. This triggers a destructive feedback loop where Claude Code's recovery logic replays PostToolUse hook output as fake user messages, causing runaway tool calls. Anthropic staff (bcherny/@Anthropic) confirmed multiple root causes were fixed incrementally; the complete fix landed in v2.0.43+ (Nov 17, 2025). Impact: 277+ reactions, 270+ comments, 25+ cross-referenced duplicate issues — one of the most-reported Claude Code bugs of 2025. Agent Decision Tree: (1) First check version with 'claude --version' — if < 2.0.19, apply Solution 1. (2) If version is current but error persists, check for PostToolUse hooks with Solution 3. (3) If no hooks are active, apply Solution 2 (CLAUDE.md sequential execution). (4) If error occurs after teleport or IDE switch, apply Solution 4 (lock file cleanup). (5) As last resort, use CLI /rewind to recover the session.

Fix MCP TypeScript SDK EvalError: AJV Code Generation Blocked on Cloudflare Workers, Deno Deploy, and Edge Environments

Unverified

When using the MCP TypeScript SDK's elicitation (elicitInput) feature in Cloudflare Workers or other edge environments that disallow dynamic code generation, schema validation fails with 'EvalError: Code generation from strings disallowed for this context'. The root cause is AJV v6 using `new Function` for dynamic code generation, which is blocked in Workers/edge runtimes. This affects all MCP servers deployed on Cloudflare Workers requiring elicitation. The MCP SDK originally bundled AJV v6 (v1.8.0-v1.10.x), upgraded to AJV v8 in v1.11.0, but the upgrade was reverted in v1.12.0 due to a separate Workers SDK bug (#517). AJV v6 remained until v1.21.0, when AJV v8 was re-applied permanently. The fix version is v1.21.0. The MCP SDK maintainers (dsp-ant, bhosmer-ant) acknowledged and closed the issue. Cloudflare also supports elicitation via the McpAgent class as an alternative approach.

Fix MCP TypeScript SDK Zod v4 Incompatibility: '_parse is not a function' (-32603) in Claude Desktop, Cursor, VS Code, and Custom MCP Servers

Unverified

MCP TypeScript SDK v1.17.0 through v1.17.5 is incompatible with Zod v4.x due to breaking changes in Zod's internal API. When projects use Zod v4 alongside the MCP SDK, tools fail with JSON-RPC error -32603: 'w._parse is not a function' and 'null is not an object (evaluating F._def)'. Root cause: the MCP SDK directly calls internal Zod methods (_parse, _def) that were removed or changed in Zod v4. The fix was shipped in MCP SDK v1.23.0-beta.0 and stable v1.23.0+ by maintainer felixweinberger, who added backward-compatible Zod v4 support via PR #869. This affects all MCP server implementations using the TypeScript SDK, including Claude Desktop, Cursor, VS Code, Cline, and any custom MCP server built with @modelcontextprotocol/sdk. NPM/Bun dependency resolution can silently hoist Zod v4 even when the SDK specifies zod@^3, causing the error to appear without explicit Zod v4 installation. Workarounds include upgrading the SDK to v1.23.0+, pinning Zod to v3.x in package.json overrides, or using the v1.23.0-beta.0 release for early adoption.

mcpcursor

Fix Claude Code Terminal Enhanced Keyboard Mode (kitty Keyboard Protocol/modifyOtherKeys) Persisting After Exit — Ctrl-C/Ctrl-D Broken in Ghostty, Kitty, WezTerm, and tmux (v2.1.86 Fix)

Unverified

After exiting Claude Code, the terminal remains stuck in enhanced keyboard input mode (kitty keyboard protocol and/or modifyOtherKeys/XTMODKEYS), causing Ctrl-C, Ctrl-D, and other control key combinations to produce raw escape sequences (e.g., '9;5u', '0;133u') instead of sending SIGINT and EOF. This affects all terminals that support enhanced keyboard protocols — Ghostty, Kitty, WezTerm, foot, and tmux sessions. The root cause is that Claude Code enables these protocols for its own key handling but does not restore the terminal to the previous state on exit or when spawning subprocesses. Anthropic staff (@ashwin-ant) confirmed the fix in v2.1.86. Three community-verified workarounds provide immediate relief: a one-shot printf escape sequence, a persistent Stop hook in settings.json, or the classic 'reset' command. This issue accumulated 63 reactions and 22 comments with confirmations across macOS, Linux, and multiple terminal emulators.

claude-code

Fix Disabled Telemetry Silently Downgrading Prompt Cache TTL from 1-Hour to 5-Minutes in Claude Code on Windows, macOS, and WSL2

Unverified

When telemetry is disabled via DISABLE_TELEMETRY=1 or CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1 (either as environment variables or in ~/.claude/settings.json), Claude Code silently downgrades prompt cache TTL from 1-hour to 5-minutes for Max plan subscribers. This causes significantly higher token usage and costs, as the shorter cache TTL means more cache misses and re-computation. The issue affects all platforms (Windows, macOS, WSL2) and applies only to Max plan subscribers — Pro plan subscribers already use 5-minute TTL. Detection is via session JSONL files in ~/.claude/projects/*/ where the usage.cache_creation field shows ephemeral_5m_input_tokens instead of ephemeral_1h_input_tokens. Anthropic confirmed the issue and shipped a client-side fix in v2.1.108 (April 13, 2026). Users should either remove telemetry-disabling flags or upgrade to v2.1.108+.

Fix Claude Code Plugin False Positive: security-guidance Hook Blocks File Writes on 'exec(' Substring in Markdown, TypeScript, and Non-JS Files — Resolve security_reminder_hook.py Exit Code 2

Unverified

The Claude Code security-guidance plugin's `child_process_exec` rule performs plain substring matching on the bare string `exec(` across ALL file types with no file-extension awareness. This causes false-positive blocks on legitimate code patterns in Markdown documentation, TypeScript files using `RegExp.prototype.exec()`, and any non-JavaScript file containing the text `exec(`. When the hook detects a match, it prints a command-injection warning to stderr and exits with code 2, blocking the `Write`/`Edit`/`MultiEdit` tool call entirely. The fix (merged in anthropics/claude-plugins-official#2074 on May 29, 2026) gates XSS and browser-DOM substring rules to JS-family file extensions only. Affected patterns include `exec(`, `document.cookie`, `document.write`, `eval(`, `window.eval`, `localStorage`, and `sessionStorage`. Until the updated plugin ships, workarounds include temporarily disabling the security-guidance plugin or rewriting affected code patterns to avoid the trigger substrings.

Fix MCP OAuth CIMD redirect_uris Port Mismatch (-32000/invalid_redirect_uri) in Claude Code 2.1.80+ for Granola, Slack, and All CIMD-Enabled MCP Providers

Unverified

Starting in Claude Code v2.1.80, a new clientMetadataUrl getter on the MCP OAuth provider class causes every provider that supports Client ID Metadata Documents (CIMD, per IETF OAuth 2.1 draft-ietf-oauth-v2-1-13 §8.4.2) to receive portless redirect_uris (http://localhost/callback) while the local OAuth callback server binds to port 3118 (or custom MCP_OAUTH_CALLBACK_PORT). This mismatch triggers invalid_redirect_uri errors for ALL CIMD-supporting MCP providers — confirmed for Granola (mcp.granola.ai) and Slack (mcp.slack.com), but affects any provider advertising client_id_metadata_document_supported: true. Root cause identified via binary diffing of cli.js between v2.1.79 (last working) and v2.1.81 (broken). Three solutions: downgrade to v2.1.79, verify via diff diagnostic, and clear the Keychain cache that blocks retry. OAuth 2.1 standard (§8.4.2) explicitly requires allowing any port, making the portless published metadata non-compliant as well.

claude-codemcp

MCP server shows as disconnected in the client

Verified

An MCP server fails to connect or repeatedly drops in the client.

mcpmcpconfigurationtransport

Fix MCP Server npx Connection Error (-32000) in Claude Desktop, Cursor, and Cline

Unverified

MCP servers using npx as the launch command fail with 'MCP error -32000: Connection closed' across popular AI coding clients (Claude Desktop, Cursor, Cline). npx works in terminal but fails when spawned by the MCP client because the child process doesn't inherit the full system PATH, or the npx cache is corrupted. This covers Windows, macOS, and Linux with three proven fixes: (1) ensure npx is on PATH visible to the MCP client, (2) clear corrupted npx cache, (3) migrate deprecated MCP server packages to maintained alternatives.

Claude Code ANTHROPIC_BASE_URL 或自定义 model 配置不生效

Unverified

设置 ANTHROPIC_BASE_URL 指向第三方 Anthropic 兼容端点(如 OpenRouter、LiteLLM 网关、DeepSeek API 代理)并在 settings.json 中配置自定义 model 后,Claude Code 可能忽略这些配置:请求仍发往 api.anthropic.com,/model 选择器不出现自定义模型,模型能力丢失。根因涉及 BASE_URL 路由与 model 请求体字段认知鸿沟、gateway model discovery 默认关闭、模型名前缀过滤、settings 优先级冲突、第三方端点兼容性不足。

claude-code

Claude Code: ANTHROPIC_BASE_URL ignored or custom model not applied with third-party providers

Unverified

When ANTHROPIC_BASE_URL points to a third-party Anthropic-compatible endpoint (LiteLLM gateway, OpenRouter, DeepSeek proxy) and a custom model is set via settings.json or ANTHROPIC_MODEL, Claude Code may ignore the base URL and send requests to api.anthropic.com, or the model picker may not show the custom model. Root causes include: (1) misunderstanding that BASE_URL only routes while model field determines the model ID in the request body, (2) gateway model discovery disabled by default, (3) model name prefix filtering only accepts claude/* and anthropic/* prefixed names, (4) settings precedence conflicts, (5) third-party endpoint incomplete Anthropic Messages API compatibility.

claude-code

@ai-sdk/google Gemini 2.5 Flash Function Calling Fails — Zod Thought Part Validation Error

Unverified

Production breaking: Vercel AI SDK @ai-sdk/google suddenly fails for all Gemini 2.5 Flash users. Function calling streams throw AI_TypeValidationError because Gemini introduced 'thought' parts (reasoning tokens) in API responses that the SDK Zod schema did not recognize — it only accepted text/functionCall/inlineData. 32 GitHub reactions, 22 comments, fix confirmed by Vercel team and shipped in @ai-sdk/google@1.2.19. Three resolution paths: upgrade, disable thinking, or downgrade model. Affects all Next.js / Vercel AI SDK apps using Gemini 2.5 Flash with tools.

nextjs

Claude Code Prompt Cache TTL Changed from 1h to 5m — Quota Burn Rate Spike and Cost Impact

Unverified

Around March 6, 2026, Claude Code users began experiencing a sudden spike in quota consumption and extra-usage billing. Analysis of ~120K API calls from user session JSONL logs revealed that Anthropic changed the default prompt-cache TTL from 1-hour to 5-minute per-request optimization. This caused a 17-26% cost increase for long coding sessions because cache_create operations (charged at write rate, $3.75-$6.25/MTok) replaced cheaper cache_read hits ($0.30-$0.50/MTok) when sessions paused beyond 5 minutes. A client-side bug in versions before v2.1.90 exacerbated the issue: sessions that exhausted subscription quotas would stay permanently on 5m TTL. Keywords: Claude Code cache TTL, prompt caching ephemeral_5m, quota burn rate, cache_create vs cache_read, Anthropic API pricing, v2.1.90 fix, JSONL session analysis, Max plan quota exhaustion.

Fix Claude Code API Error 400: "out of extra usage" Billing Routing Triggered by "HERMES.md" in Git Commit Messages

Unverified

When a git repository's recent commit history contains the case-sensitive string "HERMES.md", Claude Code routes API requests to "extra usage" billing instead of the included Max plan quota. This silently burns through extra usage credits ($200+ in reported cases) while plan capacity remains largely untouched. The error message ('out of extra usage') gives no indication that content-based routing is the cause, making it extremely difficult to diagnose. Anthropic staff (bcherny) confirmed: 'This was an overactive anti-abuse system. Fixed.' The fix was applied server-side. Workarounds include rewriting commit messages to use lowercase 'hermes.md' or using orphan branches to isolate project history.

claude-code

Fix Claude Code Task Agent 'tools: Tool names must be unique' API Error (400) When Spawning Subprocess with MCP Tools

Unverified

Claude Code v2.0.30 introduced a regression in subprocess tool inheritance that causes Task agent spawns to fail with API Error 400: 'tools: Tool names must be unique'. Core tools, MCP tools from multiple servers, and custom agent tools are incorrectly deduplicated during subprocess initialization, producing duplicate tool names that the Anthropic API rejects. Affects all built-in subagents (Explore, Plan, general-purpose), custom agents defined in .claude/agents/, and the /sidequest command. The main Claude Code session functions normally — only subprocess launches fail. Anthropic staff confirmed and shipped the fix in v2.0.31 within 6 hours of the report. Multiple community-confirmed workarounds available: downgrade to v2.0.29, temporarily disable MCP servers before agent launch, or pin npx to v2.0.29 in shell aliases.

claude-codemcp

Fix MCP Servers Not Working with NVM/npx (ENOENT/-32000) in Claude Desktop, Cursor, and Cline

Unverified

When using NVM (Node Version Manager), MCP servers fail to connect from GUI applications like Claude Desktop, Cursor, and Cline. The root cause is that GUI apps spawn child processes via spawn() with shell: false, so NVM's shell functions (which resolve node/npx) are unavailable. Symptoms include silent connection failures, 'Client Closed', ENOENT errors, and -32000 'Connection closed'. This affects all major Node version managers (nvm, fnm, Volta, n, nodenv, proto, mise) across macOS, Windows, and Linux. Seven verified workarounds are provided — from simple PATH injection to full version manager migration — ordered by complexity. 91 comments and 182 reactions on the official modelcontextprotocol/servers repo confirm this is a widespread issue affecting thousands of MCP users.

mcpclaude-code

Fix MCP Server npx Connection Error (ENOENT/-32000) with NVM, fnm, Volta, mise in Claude Desktop, Cursor, and VS Code

Unverified

GUI applications like Claude Desktop, Cursor, and VS Code spawn MCP server processes using child_process.spawn() with shell:false, which means Node Version Manager (NVM, fnm, Volta, mise, n, proto, nvm-windows, nodenv) shell functions and PATH modifications are not inherited. This causes 'spawn npx ENOENT', 'env: node: No such file or directory', and MCP server connection failures with error code -32000. The root cause is that Electron-based apps do not source shell profiles (.zshrc, .bashrc) before spawning child processes. Additionally, Claude Desktop enumerates all installed NVM Node versions and resolves the alphabetically-first (often oldest pre-v18) version, which fails with modern MCP servers requiring Node >=18 — this explains why some MCP servers mysteriously work while others fail. Five proven workarounds exist: absolute paths, shell wrapper scripts, bash -c wrappers, env PATH injection, and version-manager-native exec commands. This issue has 91 comments, 182 reactions, and affects virtually every Node developer using a version manager with MCP.

Claude Code Cache TTL Regression: 1h→5m Causes 20-32% Quota Inflation (v2.1.90/v2.1.108 Fix)

Unverified

Analysis of ~120K API calls across two machines reveals that Anthropic's prompt cache TTL silently regressed from 1 hour to 5 minutes around March 6-8, 2026, causing a 20-32% increase in cache creation costs and significant quota consumption spikes for subscription users. Two Claude Code bugs were confirmed as root causes: an overage-latch bug (fixed in v2.1.90) and a telemetry-disabled fallback (fixed in v2.1.108). Users on Pro/Max plans who previously never hit limits began exhausting quotas in 1.5 hours instead of 5+. Upgrade to v2.1.108+ resolves the known bugs. Anthropic is also introducing env vars for manual TTL control per staff comments.

Fix Claude Code Quality Regression: Restore Deep Thinking, Effort Settings, and Agent Performance for Complex Engineering

Unverified

Claude Code users experienced a sharp quality regression starting March 2026 — Claude ignored instructions, produced incorrect 'simplest fixes,' stopped reading code before editing, and repeatedly tried to stop working prematurely. Quantitative analysis of 234,760 tool calls and 17,871 thinking blocks across 6,852 sessions revealed the root cause: Anthropic reduced the default thinking budget by switching to adaptive thinking mode and setting effort=85 (medium) by default. The model's read:edit ratio dropped from 6.6 to 2.0, 'simplest fix' mentions tripled, and premature-stopping behaviors went from 0 to 173 incidents/day. The fix is to restore deep reasoning by enabling thinking summaries, setting effort to high/max, and disabling adaptive thinking if needed. This issue has 3,290 GitHub reactions, 583 comments, and an official Anthropic staff response with confirmed workarounds.

claude-code

MCP Server Horizontal Scaling: Session Persistence Across Multiple Workers in Streamable HTTP Mode

Unverified

When deploying MCP servers (FastMCP) horizontally on AWS ECS or Kubernetes, clients hit intermittent 'Bad Request: No valid session ID provided' 400 errors because StreamableHTTPSessionManager stores sessions in-memory only. Five solutions ranging from ALB sticky sessions to custom Redis-backed session managers and the emerging mcp-persist package, with the long-term fix awaiting an official SDK-level pluggable SessionStore protocol.

GitHub MCP Server Fails to Start: npx Command Error and Connection Closed (-32000)

Unverified

When configuring MCP servers that use npx as the launch command (e.g., GitHub MCP server), the server fails to connect with error -32000: Connection closed. The npx command works in terminal but fails when spawned by the MCP client due to PATH inheritance issues or corrupted npx cache. Solutions include fixing PATH in child process spawn, clearing npx cache, and migrating to the updated github.com/github/github-mcp-server package.

Claude Desktop OAuth 2.1 Custom MCP Connector Fails with 401/end_error While CLI Works

Unverified

Claude Desktop (Electron, >= 0.13.x) and claude.ai web interface fail to connect to custom MCP servers using OAuth 2.1/SSE/Streamable HTTP, while Claude Code CLI connects successfully to the same server. The GitHub issue has 71+ reactions, 66 comments, was closed as completed by Anthropic staff. Multiple root causes confirmed: WAF blocking Anthropic outbound IPs, missing WWW-Authenticate header on 401 responses, CORS misconfiguration on .well-known endpoints, and DCR format issues (float client_secret_expires_at rejected by RFC 7591 integer parser, token_endpoint_auth_method: client_secret_post rejected by better-auth). Complete fix kit below with copyable config examples and verification curl commands.

claude-codemcpcloudflare-workers

viem throws a chain id mismatch error

Unverified

viem rejects a transaction or request because the configured chain id does not match the provider.

viemweb3configurationrpc

Cloudflare Worker environment variable is missing at runtime

Unverified

A binding/secret is undefined inside a Cloudflare Worker.

cloudflare-workerscloudflareenvironmentsecrets

Next.js environment variable is not loaded

Unverified

An environment variable is undefined at runtime in a Next.js app.

nextjsenvironmentconfigurationbuild

pnpm workspace dependency resolution fails

Unverified

Installing in a pnpm monorepo fails to resolve a workspace dependency.

pnpmmonorepodependenciesinstall

Codex gets permission denied when editing files

Unverified

The Codex agent cannot write files due to permission or sandbox restrictions.

codexpermissionssandboxfilesystem

OpenRouter returns 429 Too Many Requests

Unverified

Requests to OpenRouter fail with HTTP 429 due to rate or credit limits.

openrouterrate-limithttpapi

Cursor rules are not applied to AI responses

Unverified

Project rules defined in .cursor/rules are ignored by the AI in Cursor.

cursorconfigurationrulesconventions

Claude Code ANTHROPIC_BASE_URL is not respected

Unverified

Requests still go to the default Anthropic endpoint despite setting ANTHROPIC_BASE_URL.

claude-codeconfigurationproxyenvironment

Claude Code custom model is not loaded from settings.json

Unverified

Claude Code keeps using the default model even after setting a custom model in settings.json.

claude-codeconfigurationmodelsettings