Anthropic API Error: Misinterpreted Usage Policy Violation During Code Navigation
Bug Description
Claude code is misinterpreting its own generated commands as being in violation of the usage policy. Context leading up to error pasted here for reference: Great, there are tests for checkpoint resume functionality. Now let me check the CheckpointMixin to understand how checkpoints are actually handled at the client level.
⏺ Read(cake/clients/checkpoint_mixin.py)
⎿ Read 100 lines (ctrl+r to expand)
✻ Thinking…
Perfect, I can see that UnifiedCheckpoint and CheckpointMixin provide standardized checkpoint management. This is part of UnifiedBaseClientV2 through the mixin. Now let me check how the Zendesk
client specifically handles checkpoints vs how it should be handled through BaseDataLakeSyncManager.
Let me look at the pattern of other sync managers to see if any properly inherit from BaseDataLakeSyncManager.
⏺ Search(pattern: "class.DataLakeSyncManager.BaseDataLakeSyncManager", path: "cake/utils", glob: "*.py", output_mode: "content")
⎿ Found 0 lines
✻ Thinking…
Confirmed - NO sync managers currently inherit from BaseDataLakeSyncManager! This is the core architectural problem.
Now let me check if there's any documentation about why this pattern was abandoned.
⏺ Search(pattern: "10.hour|performance|hang|slow.scan", path: "docs", glob: "*.md", output_mode: "content", head_limit: 30)
⎿ Found 30 lines (ctrl+r to expand)
✻ Thinking…
Let me look for specific documentation about the file scanning issue or the UnifiedSummaryManager pattern.
⏺ Search(pattern: "TODO_CORRECT_SYNC_MANAGER_PATTERN|UnifiedSummaryManager", glob: "**/*.md", output_mode: "content", head_limit: 20)
⎿ Found 20 lines (ctrl+r to expand)
⎿ API Error: Claude Code is unable to respond to this request, which appears to violate our Usage Policy (https://www.anthropic.com/legal/aup). Please double press esc to edit your last message
or start a new session for Claude Code to assist with a different task.
Environment Info
- Platform: darwin
- Terminal: Apple_Terminal
- Version: 1.0.76
- Feedback ID: 886c9e06-2c71-477f-a13f-80e5b179347a
Errors
[{"error":"Error: Request was aborted.\n at PZ1._createMessage (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:944:7955)\n at processTicksAndRejections (node:internal/process/task_queues:105:5)\n at runNextTicks (node:internal/process/task_queues:69:3)\n at process.processTimers (node:internal/timers:540:9)","timestamp":"2025-08-12T19:20:25.584Z"},{"error":"Error: Request was aborted.\n at PZ1._createMessage (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:944:7955)\n at processTicksAndRejections (node:internal/process/task_queues:105:5)\n at runNextTicks (node:internal/process/task_queues:69:3)\n at listOnTimeout (node:internal/timers:569:9)\n at process.processTimers (node:internal/timers:543:7)","timestamp":"2025-08-12T19:51:59.808Z"},{"error":"Error: Request was aborted.\n at PZ1._createMessage (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:944:7955)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)","timestamp":"2025-08-12T20:16:43.400Z"},{"error":"Error: File content (290.4KB) exceeds maximum allowed size (256KB). Please use offset and limit parameters to read specific portions of the file, or use the GrepTool to search for specific content.\n at Object.call (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1856:949)\n at call.next (<anonymous>)\n at BN8 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:3126:11539)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async NuB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:3126:7800)\n at async OjB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2132:822)\n at async AN8 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:3126:6911)\n at async oq8 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:3126:6396)\n at async cS (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:3126:4860)\n at async cS (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:3126:5541)","timestamp":"2025-08-12T23:33:49.864Z"},{"error":"Error: File content (290.4KB) exceeds maximum allowed size (256KB). Please use offset and limit parameters to read specific portions of the file, or use the GrepTool to search for specific content.\n at Object.call (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1856:949)\n at call.next (<anonymous>)\n at BN8 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:3126:11539)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async NuB (file:///opt/homebrew
Note: Error logs were truncated.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗