Follow Discord
Sweep 22 Oct 2026 · 21:04Z Build v2.1.309 528 read Stable v2.1.308 Latest v2.1.308 Next v2.1.309 Feeds RSS JSON llms.txt llms-full.txt Unofficial

Claude Code v2.1.305 ·

Headless runs wait for the session to end and for context usage requests before exiting

Headless Claude Code now waits up to 30 seconds for the session to end and up to 5 minutes for a pending get_context_usage request before exiting

You'll notice Improvements
JSON All of v2.1.305
You'll noticeTier: how much it should matter to you
2Useful: my rating, 1 to 5
1Signal: worth watching, 1 to 5
Headless ModeArea: what it touches
ImprovementsKind: in v2.1.305,
ImprovementsSection of the release
What

In headless use, meaning Claude Code running without its interactive screen (for example driven by another program), shutting down now takes two extra waits:

  • Up to 30 seconds for the session to finish ending.
  • Then up to 300,000 milliseconds (5 minutes) for any get_context_usage request still in progress. If one is, Claude Code reports "get_context_usage still pending at teardown".

Before, shutdown only waited for pending reads to finish.

Why

A headless run can now take noticeably longer to exit if a context usage request hangs. If your scripts time out on exit, this is a likely place to look.

See this entry in the whole of v2.1.305 →

Feedback