mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-20 00:11:50 +00:00
fix(types): import CachedTokensDetails on its own line in openai.py
CodeQL resolves `from openai import Omit` in litellm/types/llms/openai.py to the
module itself, so every importer of a name whose definition line is in the diff
is reported as an unsafe cyclic import. 76ae35dfcd edited the line that defines
BaseLiteLLMOpenAIResponseObject there and got two alerts at files this PR does
not touch. That line is now byte-identical to main and CachedTokensDetails
arrives through a relative import isort keeps separate.
This commit is contained in:
parent
76ae35dfcd
commit
6f7882db34
1 changed files with 3 additions and 1 deletions
|
|
@ -82,7 +82,7 @@ from typing_extensions import (
|
|||
override,
|
||||
)
|
||||
|
||||
from litellm.types.llms.base import BaseLiteLLMOpenAIResponseObject, CachedTokensDetails
|
||||
from litellm.types.llms.base import BaseLiteLLMOpenAIResponseObject
|
||||
from litellm.types.responses.main import (
|
||||
CustomToolCallOutputItem,
|
||||
GenericResponseOutputItem,
|
||||
|
|
@ -91,6 +91,8 @@ from litellm.types.responses.main import (
|
|||
OutputImageGenerationCall,
|
||||
)
|
||||
|
||||
from .base import CachedTokensDetails
|
||||
|
||||
FileContent = IO[bytes] | bytes | PathLike
|
||||
|
||||
FileTypes = (
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue