Skip to content

Commit 8b197a7

Browse files
authored
fix: include aiobotocore in the bedrock extra (#6419)
### Overview `BedrockCompletion.acall()` (the async completion path used when a crew is kicked off asynchronously) requires `aiobotocore` to build its async client. The `bedrock` extra, however, only declared `boto3`. Crews configured with an AWS Bedrock model work fine under a synchronous `kickoff()`, since that path only needs `boto3`, but raise `NotImplementedError: Async support for AWS Bedrock requires aiobotocore` as soon as they're kicked off asynchronously, since `aiobotocore` was never installed. The fix adds `aiobotocore` to the `bedrock` extra, so `crewai[bedrock]` installs both the sync (`boto3`) and async (`aiobotocore`) dependencies the native Bedrock provider needs. The lockfile is regenerated to match. The exception message is also corrected — it previously pointed to a `bedrock-async` extra that never existed in `pyproject.toml`. ### Changes - `lib/crewai/pyproject.toml`: add `aiobotocore~=3.5.0` to the `bedrock` extra - `uv.lock`: regenerated to reflect the updated `bedrock` extra - `lib/crewai/src/crewai/llms/providers/bedrock/completion.py`: fix the install hint in the `NotImplementedError` message to reference the real `bedrock` extra instead of the nonexistent `bedrock-async`
1 parent f630c47 commit 8b197a7

3 files changed

Lines changed: 5 additions & 2 deletions

File tree

lib/crewai/pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ litellm = [
9292
]
9393
bedrock = [
9494
"boto3~=1.42.90",
95+
"aiobotocore~=3.5.0",
9596
]
9697
google-genai = [
9798
"google-genai~=1.65.0",

lib/crewai/src/crewai/llms/providers/bedrock/completion.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,7 +492,7 @@ async def acall(
492492
if not AIOBOTOCORE_AVAILABLE:
493493
raise NotImplementedError(
494494
"Async support for AWS Bedrock requires aiobotocore. "
495-
'Install with: uv add "crewai[bedrock-async]"'
495+
'Install with: uv add "crewai[bedrock]"'
496496
)
497497

498498
with llm_call_context():

uv.lock

Lines changed: 3 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)