From 40b0f72dae7a45b8d0816b352316142e150b0ae0 Mon Sep 17 00:00:00 2001 From: Julio Quinteros Pro Date: Wed, 18 Feb 2026 19:04:30 -0300 Subject: [PATCH] fix(types): add = None defaults to Optional[str] fields in managed table models In Pydantic v2, `Optional[str]` without a default value is a required field (callers must explicitly pass `None`). This caused `ValidationError` when constructing `LiteLLM_ManagedFileTable` and `LiteLLM_ManagedVectorStoreTable` without providing `created_by`/`updated_by`. Co-Authored-By: Claude Sonnet 4.6 --- litellm/proxy/_types.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/litellm/proxy/_types.py b/litellm/proxy/_types.py index c327dd130a..4689907643 100644 --- a/litellm/proxy/_types.py +++ b/litellm/proxy/_types.py @@ -3957,8 +3957,8 @@ class LiteLLM_ManagedFileTable(LiteLLMPydanticObjectBase): file_object: Optional[OpenAIFileObject] = None model_mappings: Dict[str, str] flat_model_file_ids: List[str] - created_by: Optional[str] - updated_by: Optional[str] + created_by: Optional[str] = None + updated_by: Optional[str] = None storage_backend: Optional[str] = None storage_url: Optional[str] = None @@ -3976,8 +3976,8 @@ class LiteLLM_ManagedVectorStoreTable(LiteLLMPydanticObjectBase): resource_object: Optional[Any] = None # VectorStoreCreateResponse model_mappings: Dict[str, str] flat_model_resource_ids: List[str] - created_by: Optional[str] - updated_by: Optional[str] + created_by: Optional[str] = None + updated_by: Optional[str] = None storage_backend: Optional[str] = None storage_url: Optional[str] = None