{"record":{"id":"ec12cd8beebff42c","repo":"BerriAI/litellm","slug":"error-processing-response-e-ec12cd","errorCode":null,"errorMessage":"Error processing response: {e}","messagePattern":"Error processing response: (.+?)","errorType":"exception","errorClass":"BedrockError","httpStatus":null,"severity":"error","filePath":"litellm/llms/bedrock/chat/invoke_agent/transformation.py","lineNumber":468,"sourceCode":"            verbose_logger.debug(\"Parsed %s events from stream\", len(events))\n\n            # Extract response content from chunk events\n            content: Final = self._extract_response_content(events)\n\n            # Extract usage information from trace events\n            usage_info: Final = self._extract_usage_info(events)\n\n            # Build and return the model response\n            return self._build_model_response(\n                content=content,\n                model=model,\n                usage_info=usage_info,\n                model_response=model_response,\n            )\n\n        except Exception as e:\n            verbose_logger.error(\"Error processing Bedrock Invoke Agent response: %s\", e)\n            raise BedrockError(\n                message=f\"Error processing response: {e}\",\n                status_code=raw_response.status_code,\n            )\n\n    def validate_environment(\n        self,\n        headers: dict,\n        model: str,\n        messages: list[AllMessageValues],\n        optional_params: dict,\n        litellm_params: dict,\n        api_key: str | None = None,\n        api_base: str | None = None,\n    ) -> dict:\n        return headers\n\n    def get_error_class(self, error_message: str, status_code: int, headers: dict | httpx.Headers) -> BaseLLMException:\n        return BedrockError(status_code=status_code, message=error_message)","sourceCodeStart":450,"sourceCodeEnd":486,"githubUrl":"https://github.com/BerriAI/litellm/blob/6c2dcb801bf2b75c18f1bb24140e7cf57465cc4d/litellm/llms/bedrock/chat/invoke_agent/transformation.py#L450-L486","documentation":"Error \"Error processing response: {e}\" thrown in BerriAI/litellm.","triggerScenarios":"Thrown at litellm/llms/bedrock/chat/invoke_agent/transformation.py:468 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the agent response stream; see the wrapped exception."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"6c2dcb801bf2b75c18f1bb24140e7cf57465cc4d","analyzedAt":"2026-08-15T07:12:03.035Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}