You'll noticeTier: how much it should matter to you
2Useful: my rating, 1 to 5
1Signal: worth watching, 1 to 5
Print ModeArea: what it touches
ImprovementsKind: in v2.1.311,
ImprovementsSection of the release
What
In print mode (-p), Claude Code answers once and exits, but it may first wait for background work to finish. The way it waits after a turn has been reworked:
Quiet wait: when the only background work still running is shell commands (local_bash) and nothing else is pending, Claude Code now sleeps until something changes. It wakes when the message queue, its internal state or the session state changes. Before, it checked every 100 milliseconds.
CLAUDE_CODE_DISABLE_QUIET_BACKGROUND_WAIT: a new environment variable (a named value you set in your shell before starting a program). Setting it restores the old 100ms checking.
Wait ceiling: the stop path for the maximum wait still reads the tengu_print_ceiling_stop_agents flag (fallback true), and tengu_giggly_dragonfly still has fallback true. Nothing has been read about either flag. Its message still says that setting CLAUDE_CODE_PRINT_BG_WAIT_CEILING_MS=0 makes Claude Code wait indefinitely. The keep-alive logic around these flags was reworked to fit the new wait.
Why
Headless runs that sit waiting on background shells should wake up the computer less often while idle. If the new waiting causes trouble, the environment variable switches back to the old behaviour.