Skip to content

Sync fork with strands-agents/sdk-python/main#23

Closed
mehtarac wants to merge 13 commits into
mehtarac:mainfrom
strands-agents:main
Closed

Sync fork with strands-agents/sdk-python/main#23
mehtarac wants to merge 13 commits into
mehtarac:mainfrom
strands-agents:main

Conversation

@mehtarac
Copy link
Copy Markdown
Owner

@mehtarac mehtarac commented Nov 9, 2025

Description

Sync fork with the main branch of the sdk.

Related Issues

Documentation PR

Type of Change

Bug fix
New feature
Breaking change
Documentation update
Other (please describe):

Testing

How have you tested the change? Verify that the changes do not break functionality or introduce warnings in consuming repositories: agents-docs, agents-tools, agents-cli

  • I ran hatch run prepare

Checklist

  • I have read the CONTRIBUTING document
  • I have added any necessary tests that prove my fix is effective or my feature works
  • I have updated the documentation accordingly
  • I have added an appropriate example to the documentation to outline the feature, or no new docs are needed
  • My changes generate no new warnings
  • Any dependent changes have been merged and published

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

zastrowm and others added 5 commits November 5, 2025 14:24
PR#1078 mentioned that context overflows were not handled, but I wasn't able to reproduce using the code changes in it.  However, in testing (using @DEA's suggested test) I was able to reproduce and consistently got a "prompt is too long:" error

Co-authored-by: Mackenzie Zastrow <zastrowm@users.noreply.github.com>
…1142)

Per #1067 including the args in the description is redundant as it's already included in the parameter docs which can increase the token counts.  Strip args from the description strings for inputSpecs

---------

Co-authored-by: Mackenzie Zastrow <zastrowm@users.noreply.github.com>
@codecov-commenter
Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

❌ Patch coverage is 96.36364% with 4 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/strands/hooks/registry.py 91.66% 1 Missing and 1 partial ⚠️
src/strands/telemetry/tracer.py 86.66% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

---------

Co-authored-by: Dean Schmigelski <dbschmigelski+github@gmail.com>
Fixes #995 where if a MCP tool_call receives a 5XX error from the server, the call hangs and never ends. The root cause is that Anthropic's MCP client - on receiving a 5XX - bubbles up an exception that ends up cancelling all TaskGroup tasks which results in the session/client/asyncio loop being torn down and the tool_call never resolves, thus the hang.

The fix is two fold:

- Detect that the situation occurs and trigger a close `close_future` future
- Update all background_invokes to eagerly bail on `close_future` being triggered

---------

Co-authored-by: Mackenzie Zastrow <zastrowm@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants