refactor(proxy): import CustomLogger under TYPE_CHECKING in key management endpoints

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
yucheng 2026-09-13 09:02:59 +00:00
parent d45f42f220
commit 62b9130c5f

View file

@ -39,7 +39,6 @@ from litellm.constants import (
MINIMUM_CUSTOM_KEY_LENGTH,
UI_SESSION_TOKEN_TEAM_ID,
)
from litellm.integrations.custom_logger import CustomLogger
from litellm.litellm_core_utils.duration_parser import duration_in_seconds
from litellm.litellm_core_utils.safe_json_dumps import safe_dumps
from litellm.models.credentials import CredentialItem
@ -164,6 +163,8 @@ if TYPE_CHECKING:
from prisma import Prisma
from prisma import models as prisma_models
from litellm.integrations.custom_logger import CustomLogger
_RepositoryModelT = TypeVar("_RepositoryModelT", bound=BaseModel)
@ -7136,7 +7137,7 @@ def _callback_entry_error(entry: Mapping[str, object]) -> str | None:
return None
async def flush_gcs_and_describe_failures(gcs_logger: CustomLogger | None, health_check_event_id: str) -> str | None:
async def flush_gcs_and_describe_failures(gcs_logger: "CustomLogger | None", health_check_event_id: str) -> str | None:
from litellm.integrations.gcs_bucket.gcs_bucket import GCSBucketLogger
if not isinstance(gcs_logger, GCSBucketLogger):