Skip to content

fix: spill long system prompts on Windows#962

Open
MukundaKatta wants to merge 1 commit into
anthropics:mainfrom
MukundaKatta:codex/claude-agent-long-system-prompt
Open

fix: spill long system prompts on Windows#962
MukundaKatta wants to merge 1 commit into
anthropics:mainfrom
MukundaKatta:codex/claude-agent-long-system-prompt

Conversation

@MukundaKatta
Copy link
Copy Markdown

Fixes #883

  • rewrite oversized inline --system-prompt and --append-system-prompt args to temporary --*-file args before spawning Claude Code on Windows
  • clean up temporary prompt files after close or failed connect
  • report Windows WinError 206 as a command-line-length failure instead of CLINotFoundError when the CLI path exists

Checks:

  • uv run --extra dev pytest tests/test_transport.py -q
  • uv run --extra dev ruff check src/claude_agent_sdk/_internal/transport/subprocess_cli.py tests/test_transport.py
  • uv run --extra dev ruff format --check src/claude_agent_sdk/_internal/transport/subprocess_cli.py tests/test_transport.py
  • git diff --check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows: SDK should fall back to --system-prompt-file when cmdline overflows (follow-up to #501)

1 participant