Skip to content

Commit fbc2661

Browse files
committed
Fix the return type of GoogleCloudBeforeRequestHook#before_request
1 parent 6c0ef97 commit fbc2661

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • packages/mistralai_gcp/src/mistralai_gcp

packages/mistralai_gcp/src/mistralai_gcp/sdk.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import json
44
import weakref
5-
from typing import Any, Optional, cast
5+
from typing import Any, Optional, Union, cast
66

77
import google.auth
88
import google.auth.credentials
@@ -197,7 +197,7 @@ def __init__(self, region: str, project_id: str):
197197

198198
def before_request(
199199
self, hook_ctx, request: httpx.Request
200-
) -> httpx.Request | Exception:
200+
) -> Union[httpx.Request, Exception]:
201201
# The goal of this function is to template in the region, project and model into the URL path
202202
# We do this here so that the API remains more user-friendly
203203
model_id = None

0 commit comments

Comments
 (0)