[Bug] Anthropic API Error: Usage Policy false positive issue blocking operations
Bug Description
Trying to build a compiler, and new sessions are going to Usage Policy violations within just a couple of prompts.
● Bash(git diff --stat HEAD -- Codex.Codex/Types/TypeEnv.codex Codex.Codex/Types/TypeChecker.codex
Codex.Codex/opening.codex 2>&1 | head -20)
⎿ Codex.Codex/Types/TypeChecker.codex | 263 +++++++++++++++++++++++++++++++++---
Codex.Codex/Types/TypeEnv.codex | 57 +++++---
2 files changed, 282 insertions(+), 38 deletions(-)
● Bash(git log --all --oneline --diff-filter=A --name-only 2>&1 | grep -iE
"env.diag|env.probe|env.bind|bind.diag|lookup.diag|first.byte|byte.loss|loss.rate" |…)
⎿ (No output)
● Bash(git diff HEAD -- Codex.Codex/Types/TypeEnv.codex 2>&1 | head -120)
⎿ diff --git a/Codex.Codex/Types/TypeEnv.codex b/Codex.Codex/Types/TypeEnv.codex
index 1a75dda..57903bf 100644
--- a/Codex.Codex/Types/TypeEnv.codex
… +75 lines (ctrl+o to expand)
● Bash(git diff HEAD -- Codex.Codex/Types/TypeChecker.codex 2>&1 | head -80)
⎿ diff --git a/Codex.Codex/Types/TypeChecker.codex b/Codex.Codex/Types/TypeChecker.codex
index d93e277..a74d9e6 100644
--- a/Codex.Codex/Types/TypeChecker.codex
… +32 lines (ctrl+o to expand)
● Bash(git diff HEAD -- Codex.Codex/Types/TypeChecker.codex 2>&1 | grep -nE
"^\+.*(env-lookup|diag|probe|loss|first-byte|byte-13|ErrorTy|print-line|counter|increment)"…)
⎿ 119:+ then (unify (declared.state) (env-lookup (declared.env) (def.name.value)) (declared.
expected-type) (def.span)).state
125:+ in let env-type = env-lookup env (def.name.value)
… +8 lines (ctrl+o to expand)
Searched for 4 patterns, read 1 file, listed 2 directories (ctrl+o to expand)
❯ look for the tool with a directory scan sorted by date, the tools you were using should be near the top
Read 4 files, listed 3 directories (ctrl+o 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. If you are seeing this refusal
repeatedly, try running /model claude-sonnet-4-20250514 to switch models.
Environment Info
- Platform: win32
- Terminal: windows-terminal
- Version: 2.1.119
- Feedback ID: 9555d059-a088-4fe8-a704-870bbcc3a7cb
Errors
[]This issue has 6 comments on GitHub. Read the full discussion on GitHub ↗