BerriAI/litellm · error · OCIError

{response_json["error"]}

Error message

{response_json["error"]}

What it means

Error "{response_json["error"]}" thrown in BerriAI/litellm.

Source

Thrown at litellm/llms/oci/chat/transformation.py:617

        logging_obj: LiteLLMLoggingObj,
        request_data: dict,
        messages: list[AllMessageValues],
        optional_params: dict,
        litellm_params: dict,
        encoding: Any,
        api_key: str | None = None,
        json_mode: bool | None = None,
    ) -> ModelResponse:
        response_json: Final = raw_response.json()

        if not isinstance(response_json, dict):
            raise OCIError(
                message="Invalid response format from OCI",
                status_code=raw_response.status_code,
            )

        if response_json.get("error") is not None:
            raise OCIError(
                message=str(response_json["error"]),
                status_code=raw_response.status_code,
            )

        vendor: Final = get_vendor_from_model(model)
        if vendor == OCIVendors.COHERE:
            model_response = handle_cohere_response(response_json, model, model_response, raw_response)
        else:
            model_response = handle_generic_response(response_json, model, model_response, raw_response)

        model_response._hidden_params["additional_headers"] = raw_response.headers
        return model_response

    @track_llm_api_timing()
    def get_sync_custom_stream_wrapper(
        self,
        model: str,
        custom_llm_provider: str,

View on GitHub (pinned to 6c2dcb801b)

Solutions

  1. Inspect the OCI error field in the response.

When it happens

Trigger: Thrown at litellm/llms/oci/chat/transformation.py:617 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of BerriAI/litellm@6c2dcb801b (2026-08-15). Data as JSON: /api/errors/dbb5c458495271b9. Report an issue: GitHub.