Skip to content

docs: clarify that tools=None uses the default toolset in ClaudeAgentOptions#1033

Open
areiche2 wants to merge 1 commit into
anthropics:mainfrom
areiche2:main
Open

docs: clarify that tools=None uses the default toolset in ClaudeAgentOptions#1033
areiche2 wants to merge 1 commit into
anthropics:mainfrom
areiche2:main

Conversation

@areiche2

Copy link
Copy Markdown

Summary

The change documents what the default tools=None means on ClaudeAgentOptions. The docstring currently explains list[str], [], and the claude_code preset, but not None. I'm suggesting the change for two reasons:

  • I misread None as "no tools", when it actually means the opposite: all built-in tools are available.
  • I feel that the SDK would benefit from documenting the default somewhere.

No behavior change. Docstring only.

Note

None is the only value that skips flag construction entirely. Please refer to subprocess_cli.py:241:

    if self._options.tools is not None:
        ...  # builds the --tools flag

…Options

The tools docstring documented list[str], [] and the claude_code preset but not the default None. Since [] means "disable all built-in tools", None was easy to misread the same way.
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.

1 participant