The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
Fix azure image mypy issues
Sameer Kankutee126e98a7fd1
diff --git a/litellm/llms/azure_ai/image_edit/flux2_transformation.py b/litellm/llms/azure_ai/image_edit/flux2_transformation.pyindex 87bae59ba0f..77d46ff9179 100644--- a/litellm/llms/azure_ai/image_edit/flux2_transformation.py+++ b/litellm/llms/azure_ai/image_edit/flux2_transformation.py@@ -88,7 +88,7 @@ class AzureFoundryFlux2ImageEditConfig(OpenAIImageEditConfig):self,model: str,prompt: Optional[str],- image: FileTypes,+ image: Optional[FileTypes],image_edit_optional_request_params: Dict,litellm_params: GenericLiteLLMParams,headers: dict,@@ -102,6 +102,9 @@ class AzureFoundryFlux2ImageEditConfig(OpenAIImageEditConfig):if prompt is None:raise ValueError("FLUX 2 image edit requires a prompt.")+ if image is None:+ raise ValueError("FLUX 2 image edit requires an image.")+image_b64 = self._convert_image_to_base64(image)# Build request body with required params