From dfd89a12cf8ea13fbe915548a2caeb744039bb2a Mon Sep 17 00:00:00 2001 From: zkllll2002 Date: Wed, 22 Jul 2026 16:46:13 +0800 Subject: [PATCH] fix(bedrock): avoid strict typing lint regressions --- litellm/llms/bedrock/chat/invoke_handler.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/litellm/llms/bedrock/chat/invoke_handler.py b/litellm/llms/bedrock/chat/invoke_handler.py index 0cd32b4275b..f33fee8d908 100644 --- a/litellm/llms/bedrock/chat/invoke_handler.py +++ b/litellm/llms/bedrock/chat/invoke_handler.py @@ -9,9 +9,7 @@ from functools import partial from typing import ( AsyncIterator, Callable, - Dict, Iterator, - List, Optional, Tuple, cast, @@ -1288,8 +1286,8 @@ class AWSEventStreamDecoder: # Bedrock can stream multiple content blocks concurrently. Keep the # state keyed by contentBlockIndex so a later block start cannot change # how an earlier block's delta is interpreted. - self._content_blocks_by_content_block_index: Dict[int, List[ContentBlockDeltaEvent]] = {} - self._tool_names_by_content_block_index: Dict[int, str] = {} + self._content_blocks_by_content_block_index: dict[int, list[ContentBlockDeltaEvent]] = {} + self._tool_names_by_content_block_index: dict[int, str] = {} self.tool_calls_index: Optional[int] = None self.response_id: Optional[str] = None self.json_mode = json_mode