Skip to content

Conversation

ascender1729
Copy link

@ascender1729 ascender1729 commented Oct 8, 2025

Changes

Removes deprecated singular tool loading methods scheduled for removal in SDK 2.0:

  • ToolLoader.load_python_tool()
  • ToolLoader.load_tool()

Also removes the warnings import and all tests for deprecated methods.

Migration

Replace deprecated methods with plural equivalents:

# Old
tool = ToolLoader.load_python_tool(path, name)

# New
tools = ToolLoader.load_python_tools(path, name)
tool = tools[0]  # if you only need one

Testing

All loader tests pass (1/1 test). 251 tests pass in tools and telemetry modules.

Fixes #828

Breaking change - Users must update to plural methods.

Remove deprecated singular tool loading methods that were marked for
removal in Strands SDK 2.0. These methods were deprecated in PR strands-agents#742
in favor of the plural variants that return lists.

Removed methods:
- ToolLoader.load_python_tool() - use load_python_tools() instead
- ToolLoader.load_tool() - use load_tools() instead

Also removed:
- warnings import (no longer needed)
- All tests specific to the deprecated methods

The plural methods (load_python_tools and load_tools) remain and
should be used instead as they properly handle files with multiple
decorated tool functions.

Fixes strands-agents#828
@dbschmigelski
Copy link
Member

Hi, we don't have a 2.0 planned. If and when that occurs we will appreciate the PRs. But because things will surely drift between the impl now and then, and generally to reduce the number of open/stale PRs, I'm going to close this out.

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.

Remove deprecated ToolLoader methods

2 participants