Download Latest Version v0.2.163 source code.zip (516.6 kB) Google Add to Preferred Sources
Home / v0.2.160
Name Modified Size InfoDownloads / Week
Parent folder
README.md 2026-09-25 1.1 kB
v0.2.160 source code.tar.gz 2026-09-25 425.8 kB
v0.2.160 source code.zip 2026-09-25 516.5 kB
Totals: 3 Items   943.4 kB 0

Bug Fixes

  • Fixed follow-up turns failing after background subagents: When using query() with hooks, can_use_tool, or SDK MCP servers, stdin was closed too early if a subagent finished just before the turn's result arrived. Follow-up turns would then fail with "Stream closed" and the model would report the tool as refused. The SDK now listens for the CLI's session_state_changed messages and keeps stdin open until the CLI reports idle, matching the TypeScript SDK's behavior. A bounded wait ceiling (configurable via CLAUDE_CODE_PRINT_BG_WAIT_CEILING_MS, default 10 minutes) prevents indefinite hangs. Older CLIs without state events fall back to the previous close-at-first-result behavior. (#1190, [#1279])

Documentation

  • Aligned docstrings with the code and fixed docstring formatting (#1293)

Internal/Other Changes

  • Updated bundled Claude CLI to version 2.1.283
  • CI: skip wheels over PyPI's per-file limit instead of failing the release (#1309)

PyPI: https://pypi.org/project/claude-agent-sdk/0.2.160/

:::bash
pip install claude-agent-sdk==0.2.160
Source: README.md, updated 2026-09-25