Making 'Silent Failures' Crash at Startup — How Claude Code v2.1.225 Drew a Line Under Headless Failures and 'Overuse' for Unattended Agents
Claude Code v2.1.225, released on August 8, focused intensively on "silent failure" bugs that break unattended, headless runs — 401s from expired tokens, broken authentication on macOS, and more. We look at this update, which also adds a gateway spend-limit display, from an operational perspective.
The scary thing about an agent that no one is watching isn't that it stops — it's that it "fails silently." A token quietly expires, authentication stops going through, and it spins its wheels until you restart it. A malfunction you'd spot at a glance if you were looking at the screen goes unnoticed when unattended, melting away nothing but time and money. Claude Code v2.1.225, released on August 8, 2026, was a release that focused squarely on this kind of "silent failure." A follow-up fix, v2.1.226, shipped the same day. This time we'll look at the update through the lens of running agents unattended and headless.
Six holes that were clogging up headless runs
The fixes in v2.1.225 are lined up precisely for environments with no human present. Here are the main ones.
- 401 failures from expired tokens: Fixed a bug where a long-lived
CLAUDE_CODE_OAUTH_TOKENwas being replaced by a short-lived token from a saved login, breaking headless sessions until restart. - Broken MCP authentication on macOS: Resolved an issue where, after a keychain read timed out, the MCP OAuth server would fire off a stream of 401s as if authentication had never happened.
- Miscounting in auto mode: Auto mode was counting a safety filter's refusal of its own permission checks toward the "consecutive blocks" limit. The behavior remains a refusal, but instead of making the model retry, it now tells it to "move on."
- Stuck cross-session messages: Fixed cross-session messages that, in headless or at startup, would pile up with no notification and no expiry.
- Silent failure of the self-hosted runner: When
--base-dircouldn't be created or written to, the runner would finish registration and then fail on every session; it now crashes at startup with a clear error. - False reports from web sessions: Resolved an issue where Claude Code on the web sessions were falsely reported as "stuck" and, on every reconnect, resent a growing mountain of events.
What they all have in common is that they're the kind of failure where "no error surfaces, and you can't tell until a restart or human intervention." In interactive use, if you're unlucky it's a one-time snag; but in operations that keep running on cron or CI, this silence accumulates and quietly brings things to a halt.
Showing a limit on "run and forget"
The same release includes two additions related to cost and trust boundaries. Unattended operation runs fast, but if you forget to stop it, the only thing that grows is the bill — these are the brakes for that.
| Addition | Details |
|---|---|
| Gateway limit display | Usage warnings now support gateway spend limits. When a limit is reached, the message spells out the limit amount, the reset time, and a message from the operator (the gateway side also needs 2.1.225). |
| Workspace trust check | claude agents now shows a workspace trust prompt in untrusted directories, matching the behavior of the interactive claude. |
The spend-limit display in particular turns situations where it was previously unclear "why it stopped" into something you can explain concretely with a limit amount and a reset time. When an organization wants to cast a budget net over its agents, having the reason for a stop reach the operator also matters from an audit standpoint.
Tightening up the previous day's move the day after
This batch of fixes is continuous with the previous day's v2.1.224, released August 7. v2.1.224 was the release that introduced claude self-hosted-runner (for Team/Enterprise), which lets you make your own machine or container the execution target for Claude Code's web, mobile, and desktop. It's the foundation for unattended operation — keeping code in-house while calling out only for the brains. The following day's v2.1.225 plugged the hole where that self-hosted runner would silently fail when it couldn't create its storage location — you can see the pattern of shipping a new feature and then tightening up its operational rough edges the very next day.
What it means for practitioners, and the caveats
The implication for teams is simple. The more the foundation for running agents unattended falls into place, the more the decisive factor shifts from "smartness" to "not failing silently." These fixes may not be flashy, but they're a practical update that raises the reliability of headless operation a notch. If you're running Claude Code on cron or CI, the update is well worth it.
At the same time, the fact that this many "silent failures" were fixed all at once also reflects, conversely, just how large the operational-monitoring surface of unattended agents really is. Execution beyond human sight runs fast and cheap, but failures are hard to see, and both cost and permissions tend to quietly expand. That's exactly why it's essential to lay down mechanisms to "stop and verify," like spend limits and trust prompts, alongside it. Keeping the reins of convenience in the operator's hands — adopting it on that premise is the sensible move. Note that the same-day v2.1.226 was a follow-up release announced only as "bug fixes and reliability improvements," carrying on this stabilization trend.
References: Claude Code changelog (official) / anthropics/claude-code CHANGELOG.md / Claude Code Updates - August 2026 (Releasebot) / Claude Code Changelog (gradually.ai) / Claude Code v2.1.226 — Every Release, Summarized (Havoptic)