Skip to content

Commit 35a1e80

Browse files
committed
chore(internal): fix lint issue
1 parent 8986424 commit 35a1e80

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/openai/lib/azure.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import os
44
import inspect
5-
from typing import Any, Union, Mapping, TypeVar, Callable, Awaitable, overload
5+
from typing import Any, Union, Mapping, TypeVar, Callable, Awaitable, cast, overload
66
from typing_extensions import Self, override
77

88
import httpx
@@ -515,7 +515,7 @@ async def _get_azure_ad_token(self) -> str | None:
515515
token = provider()
516516
if inspect.isawaitable(token):
517517
token = await token
518-
if not token or not isinstance(token, str):
518+
if not token or not isinstance(cast(Any, token), str):
519519
raise ValueError(
520520
f"Expected `azure_ad_token_provider` argument to return a string but it returned {token}",
521521
)

0 commit comments

Comments
 (0)