Skip to content

fix(bedrock): normalize 3gp video format#2306

Open
he-yufeng wants to merge 1 commit into
strands-agents:mainfrom
he-yufeng:fix/bedrock-3gp-video-format
Open

fix(bedrock): normalize 3gp video format#2306
he-yufeng wants to merge 1 commit into
strands-agents:mainfrom
he-yufeng:fix/bedrock-3gp-video-format

Conversation

@he-yufeng
Copy link
Copy Markdown

Summary

Fixes the Bedrock 3GP part of #2204.

Bedrock expects the video format enum to be three_gp, while common MIME/extension paths produce 3gp, 3gpp, or 3g2. The SDK currently forwards the value as-is, so a valid 3GP video content block can be rejected by the Bedrock Converse API.

This normalizes those aliases when formatting Bedrock video content blocks. Other media-format gaps from #2204 are left out of this PR.

To verify

Ran locally:

python -m pytest tests/strands/models/test_bedrock.py::test_format_request_maps_3gp_video_formats -q
python -m pytest tests/strands/models/test_bedrock.py -q
python -m ruff check src/strands/models/bedrock.py tests/strands/models/test_bedrock.py
python -m py_compile src/strands/models/bedrock.py tests/strands/models/test_bedrock.py
git diff --check

@he-yufeng he-yufeng force-pushed the fix/bedrock-3gp-video-format branch from 5944452 to e814ac7 Compare May 20, 2026 19:09
@github-actions github-actions Bot removed the size/s label May 20, 2026
@he-yufeng he-yufeng force-pushed the fix/bedrock-3gp-video-format branch from e814ac7 to 012dc57 Compare May 20, 2026 19:10
@github-actions github-actions Bot removed the size/s label May 20, 2026
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.

1 participant