mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-15 09:12:18 +00:00
fix(lint): satisfy ruff strict budget by removing banned Any import and annotations
This commit is contained in:
parent
bb10787746
commit
7f8dcee068
3 changed files with 4 additions and 6 deletions
|
|
@ -5,7 +5,7 @@ Canonical definition for ``litellm_endusertable``. Re-exported from
|
|||
``litellm.proxy._types`` for backwards compatibility.
|
||||
"""
|
||||
|
||||
from typing import Any, Literal
|
||||
from typing import Literal
|
||||
|
||||
from pydantic import BaseModel, ConfigDict, model_validator
|
||||
|
||||
|
|
@ -28,7 +28,7 @@ class LiteLLM_EndUserTable(LiteLLMPydanticObjectBase):
|
|||
|
||||
@model_validator(mode="before")
|
||||
@classmethod
|
||||
def set_model_info(cls, values: Any) -> Any:
|
||||
def set_model_info(cls, values):
|
||||
if isinstance(values, BaseModel):
|
||||
normalized = values.model_dump()
|
||||
elif hasattr(values, "__dict__") and not isinstance(values, dict):
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ Canonical definition for ``litellm_tagtable``. Re-exported from
|
|||
"""
|
||||
|
||||
from datetime import datetime
|
||||
from typing import Any
|
||||
|
||||
from pydantic import BaseModel, model_validator
|
||||
|
||||
|
|
@ -28,7 +27,7 @@ class LiteLLM_TagTable(LiteLLMPydanticObjectBase):
|
|||
|
||||
@model_validator(mode="before")
|
||||
@classmethod
|
||||
def set_model_info(cls, values: Any) -> Any:
|
||||
def set_model_info(cls, values):
|
||||
if isinstance(values, BaseModel):
|
||||
normalized = values.model_dump()
|
||||
elif hasattr(values, "__dict__") and not isinstance(values, dict):
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ Canonical definition for ``litellm_usertable``. Re-exported from
|
|||
"""
|
||||
|
||||
from datetime import datetime
|
||||
from typing import Any
|
||||
|
||||
from pydantic import BaseModel, ConfigDict, Field, model_validator
|
||||
|
||||
|
|
@ -50,7 +49,7 @@ class LiteLLM_UserTable(LiteLLMPydanticObjectBase):
|
|||
|
||||
@model_validator(mode="before")
|
||||
@classmethod
|
||||
def set_model_info(cls, values: Any) -> Any:
|
||||
def set_model_info(cls, values):
|
||||
if isinstance(values, BaseModel):
|
||||
normalized = values.model_dump()
|
||||
elif hasattr(values, "__dict__") and not isinstance(values, dict):
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue