[Bug] Anthropic API Error: Prompt too long in /goal stop hook

Resolved 💬 3 comments Opened May 14, 2026 by Crazytieguy Closed May 17, 2026

Bug Description
Got "Stop hook error: Hook evaluator API error: Prompt is too long" during /goal.

Environment Info

  • Platform: darwin
  • Terminal: WezTerm
  • Version: 2.1.140
  • Feedback ID: b2473f9e-c437-4dbe-bd43-20ee7a988307

Errors

[{"error":"SyntaxError: JSON Parse error: Property name must be a string literal\n    at <parse> (:0)\n    at parse (unknown)\n    at $$q (/$bunfs/root/src/entrypoints/cli.js:175:10088)\n    at O (/$bunfs/root/src/entrypoints/cli.js:131:18457)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:177:1430)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:5234:741)\n    at map (native:1:11)\n    at WP_ (/$bunfs/root/src/entrypoints/cli.js:5234:559)\n    at pVK (/$bunfs/root/src/entrypoints/cli.js:9032:10590)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T20:47:14.154Z"},{"error":"Error: The socket connection was closed unexpectedly. For more information, pass `verbose: true` in the second argument to fetch()\n    at from (/$bunfs/root/src/entrypoints/cli.js:113:7862)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:121:12898)\n    at emitError (node:events:43:23)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:120:1149)\n    at emitError (node:events:43:23)\n    at <anonymous> (node:_http_client:251:22)\n    at processTicksAndRejections (native:7:39)\n    at request (/$bunfs/root/src/entrypoints/cli.js:123:2467)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T20:58:04.345Z"},{"error":"MaxFileReadTokenExceededError: [REDACTED] content (32728 tokens) exceeds maximum allowed tokens (25000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at $a7 (/$bunfs/root/src/entrypoints/cli.js:4915:13010)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T21:30:14.295Z"},{"error":"Error: The socket connection was closed unexpectedly. For more information, pass `verbose: true` in the second argument to fetch()\n    at from (/$bunfs/root/src/entrypoints/cli.js:113:7862)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:121:12898)\n    at emitError (node:events:43:23)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:120:1149)\n    at emitError (node:events:43:23)\n    at <anonymous> (node:_http_client:251:22)\n    at processTicksAndRejections (native:7:39)\n    at request (/$bunfs/root/src/entrypoints/cli.js:123:2467)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T21:41:16.903Z"},{"error":"MaxFileReadTokenExceededError: [REDACTED] content (32728 tokens) exceeds maximum allowed tokens (25000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at $a7 (/$bunfs/root/src/entrypoints/cli.js:4915:13010)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T22:31:18.238Z"},{"error":"Error: The socket connection was closed unexpectedly. For more information, pass `verbose: true` in the second argument to fetch()\n    at from (/$bunfs/root/src/entrypoints/cli.js:113:7862)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:121:12898)\n    at emitError (node:events:43:23)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:120:1149)\n    at emitError (node:events:43:23)\n    at <anonymous> (node:_http_client:251:22)\n    at processTicksAndRejections (native:7:39)\n    at request (/$bunfs/root/src/entrypoints/cli.js:123:2467)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T22:55:02.347Z"},{"error":"Error: Request was aborted.\n    at makeRequest (/$bunfs/root/src/entrypoints/cli.js:51:6192)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T23:42:05.009Z"},{"error":"Error: ECONNREFUSED\n    at from (/$bunfs/root/src/entrypoints/cli.js:113:7862)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:121:12898)\n    at emitError (node:events:43:23)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:120:1149)\n    at emitError (node:events:43:23)\n    at <anonymous> (node:_http_client:251:22)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-05-13T23:48:22.626Z"},{"error":"SyntaxError: JSON Parse error: Property name must be a string literal\n    at <parse> (:0)\n    at parse (unknown)\n    at $$q (/$bunfs/root/src/entrypoints/cli.js:175:10088)\n    at O (/$bunfs/root/src/entrypoints/cli.js:131:18457)\n    at <anonymous> (/$bunfs/root/src/entrypoints/cli.js:177:1430)\n    at <anonymous> (/$bunfs/r…

Note: Content was truncated.

View original on GitHub ↗

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