[Bug] Sub-agents terminate immediately due to prompt size exceeding context window

Resolved 💬 2 comments Opened Apr 6, 2026 by Nemesis-hub Closed May 18, 2026

Bug Description
When Claude launches a bunch of sub-agents, they all terminate immediately, with no tool uses, no nothing. And when I asked Claude about it, it said that the prompt was too large to use, and so all the agents terminate immediately. This bug has been happening for a long while; each time Claude tries to launch sub-agents.

Environment Info

  • Platform: darwin
  • Terminal: WarpTerminal
  • Version: 2.1.92
  • Feedback ID: 3d5ff64b-799e-4d90-8f77-3ee92ed41ee7

Errors

[{"error":"Error: Failed to clone repository for git-subdir source: Cloning into '/Users/2sharks/.claude/plugins/cache/temp_subdir_1775502773880_ounznq.clone'...\ngit@github.com: Permission denied (publickey).\r\nfatal: Could not read from remote repository.\n\nPlease make sure you have the correct access rights\nand the repository exists.\n    at jHY (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:4758:20730)\n    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)\n    at async w48 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:4758:22885)\n    at async WHY (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:4762:9461)\n    at async Promise.allSettled (index 1)\n    at async WkK (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:4762:6464)\n    at async Promise.all (index 0)\n    at async fkK (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:4762:17814)\n    at async file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:4762:19171\n    at async file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:8195:13251","timestamp":"2026-04-06T19:12:54.977Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"prompt is too long: 208990 tokens > 200000 maximum\"},\"request_id\":\"req_011CZo3qKHdoKKiWtQqPToUd\"}\n    at nq.generate (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:8:51294)\n    at dE.makeStatusError (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:1651)\n    at dE.makeRequest (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:4927)\n    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)","timestamp":"2026-04-06T19:13:09.491Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"prompt is too long: 208990 tokens > 200000 maximum\"},\"request_id\":\"req_011CZo3qZtiSGanui7ntGTPt\"}\n    at nq.generate (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:8:51294)\n    at dE.makeStatusError (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:1651)\n    at dE.makeRequest (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:4927)\n    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)","timestamp":"2026-04-06T19:13:13.083Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"prompt is too long: 208990 tokens > 200000 maximum\"},\"request_id\":\"req_011CZo3quFoA55GgUtkTJAqv\"}\n    at nq.generate (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:8:51294)\n    at dE.makeStatusError (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:1651)\n    at dE.makeRequest (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:4927)\n    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)","timestamp":"2026-04-06T19:13:17.709Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"prompt is too long: 208990 tokens > 200000 maximum\"},\"request_id\":\"req_011CZo3rHbxcuaevfAvRFjfL\"}\n    at nq.generate (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:8:51294)\n    at dE.makeStatusError (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:1651)\n    at dE.makeRequest (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:47:4927)\n    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)","timestamp":"2026-04-06T19:13:22.401Z"}]

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗