claude-code - 💡(How to fix) Fix HERMES.md in git commit messages causes requests to route to extra usage billing instead of plan quota [4 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#53262Fetched 2026-04-26 05:20:13
View on GitHub
Comments
4
Participants
3
Timeline
14
Reactions
6
Author
Timeline (top)
commented ×4labeled ×4subscribed ×4closed ×1

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 burned through $200 in extra usage credits while my Max 20x plan capacity remained largely untouched (13% weekly usage).

Error Message

This FAILS with "out of extra usage" (routes to extra usage billing)

mkdir /tmp/test-fail && cd /tmp/test-fail git init && echo test > test.txt && git add . && git commit -m "add HERMES.md" claude -p "say hello" --model "claude-opus-4-6[1m]"

=> API Error: 400 "You're out of extra usage..."

This WORKS (routes to plan quota)

mkdir /tmp/test-pass && cd /tmp/test-pass git init && echo test > test.txt && git add . && git commit -m "add hermes.md" claude -p "say hello" --model "claude-opus-4-6[1m]"

=> "Hello!"

Cleanup

rm -rf /tmp/test-fail /tmp/test-pass

Root Cause

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 burned through $200 in extra usage credits while my Max 20x plan capacity remained largely untouched (13% weekly usage).

Code Example

# This FAILS with "out of extra usage" (routes to extra usage billing)
mkdir /tmp/test-fail && cd /tmp/test-fail
git init && echo test > test.txt && git add . && git commit -m "add HERMES.md"
claude -p "say hello" --model "claude-opus-4-6[1m]"
# => API Error: 400 "You're out of extra usage..."

# This WORKS (routes to plan quota)
mkdir /tmp/test-pass && cd /tmp/test-pass
git init && echo test > test.txt && git add . && git commit -m "add hermes.md"
claude -p "say hello" --model "claude-opus-4-6[1m]"
# => "Hello!"

# Cleanup
rm -rf /tmp/test-fail /tmp/test-pass
RAW_BUFFERClick to expand / collapse

Summary

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 burned through $200 in extra usage credits while my Max 20x plan capacity remained largely untouched (13% weekly usage).

Environment

  • Claude Code v2.1.119
  • macOS (Apple Silicon)
  • Max 20x plan ($200/month)
  • Model: claude-opus-4-6[1m] (also reproduces with claude-opus-4-7)

Reproduction

Minimal reproduction — no project files needed:

# This FAILS with "out of extra usage" (routes to extra usage billing)
mkdir /tmp/test-fail && cd /tmp/test-fail
git init && echo test > test.txt && git add . && git commit -m "add HERMES.md"
claude -p "say hello" --model "claude-opus-4-6[1m]"
# => API Error: 400 "You're out of extra usage..."

# This WORKS (routes to plan quota)
mkdir /tmp/test-pass && cd /tmp/test-pass
git init && echo test > test.txt && git add . && git commit -m "add hermes.md"
claude -p "say hello" --model "claude-opus-4-6[1m]"
# => "Hello!"

# Cleanup
rm -rf /tmp/test-fail /tmp/test-pass

The trigger is the string HERMES.md in git commit messages — not the presence of a file with that name on disk. Claude Code includes recent commits in its system prompt, and something server-side routes the request differently when this string is present.

What triggers it vs. what doesn't

Commit messageResult
"HERMES.md"Fails — routes to extra usage
"test HERMES.md test"Fails
"hermes.md" (lowercase)Works
"HERMES" (no extension)Works
"HERMES.txt"Works
"AGENTS.md"Works
"README.md"Works
File named HERMES.md on disk, clean commit msgWorks
Same repo, orphan branch (no history)Works

Impact

  • $200.98 in extra usage credits consumed for requests that should have been covered by the included Max 20x plan quota
  • Multiple projects became completely unusable once extra usage was depleted, while the plan dashboard showed 86%+ remaining weekly capacity
  • The error message ("out of extra usage") gives no indication that content-based routing is the cause, making this extremely difficult to diagnose
  • Any user with HERMES.md in recent git commits would silently have their usage billed to extra credits

Expected behavior

API request billing should not depend on the content of git commit messages in the system prompt. All requests from a Max plan subscriber should route to the included plan quota first.

How I found this

Systematic binary search: cloning affected repos, testing orphan branches, then isolating individual commit message strings until HERMES.md was identified as the exact trigger.

extent analysis

TL;DR

Avoid using the case-sensitive string HERMES.md in git commit messages to prevent Claude Code from routing API requests to extra usage billing.

Guidance

  • Verify that the issue is resolved by creating a new commit with a different message and checking if the API request is routed to the included Max plan quota.
  • To mitigate the issue, update recent commit messages to avoid the HERMES.md string, or use a different branch without the problematic commit history.
  • Test API requests with different commit messages to confirm the trigger is indeed the HERMES.md string.
  • Consider reaching out to Claude Code support to report the issue and request a fix or workaround.

Example

No code snippet is necessary, as the issue is triggered by a specific string in git commit messages.

Notes

The issue seems to be specific to Claude Code's handling of git commit messages in the system prompt, and may not be related to the actual file system or project content.

Recommendation

Apply workaround: avoid using the HERMES.md string in git commit messages until a fix is available from Claude Code, to prevent unexpected extra usage billing.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

API request billing should not depend on the content of git commit messages in the system prompt. All requests from a Max plan subscriber should route to the included plan quota first.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix HERMES.md in git commit messages causes requests to route to extra usage billing instead of plan quota [4 comments, 3 participants]