mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-13 23:11:40 +00:00
refactor(google_genai): type streaming iterator response as httpx.Response
Drops 4 reportUnknown* basedpyright findings that the bytes-buffering rewrite would otherwise leak from the untyped response parameter.
This commit is contained in:
parent
d2a2e15cf5
commit
ea56e834c3
1 changed files with 4 additions and 2 deletions
|
|
@ -2,6 +2,8 @@ import asyncio
|
|||
from datetime import datetime
|
||||
from typing import TYPE_CHECKING, Any, Dict, List, Optional, Tuple
|
||||
|
||||
import httpx
|
||||
|
||||
from litellm.litellm_core_utils.litellm_logging import Logging as LiteLLMLoggingObj
|
||||
from litellm.proxy.pass_through_endpoints.success_handler import (
|
||||
PassThroughEndpointLogging,
|
||||
|
|
@ -92,7 +94,7 @@ class GoogleGenAIGenerateContentStreamingIterator(
|
|||
|
||||
def __init__(
|
||||
self,
|
||||
response,
|
||||
response: httpx.Response,
|
||||
model: str,
|
||||
logging_obj: LiteLLMLoggingObj,
|
||||
generate_content_provider_config: BaseGoogleGenAIGenerateContentConfig,
|
||||
|
|
@ -153,7 +155,7 @@ class AsyncGoogleGenAIGenerateContentStreamingIterator(
|
|||
|
||||
def __init__(
|
||||
self,
|
||||
response,
|
||||
response: httpx.Response,
|
||||
model: str,
|
||||
logging_obj: LiteLLMLoggingObj,
|
||||
generate_content_provider_config: BaseGoogleGenAIGenerateContentConfig,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue