Skip to content

Commit 3d380ba

Browse files
yashwantbezawadacopybara-github
authored andcommitted
Copybara import of the project:
-- 2681770 by Yashwant Bezawada <yashwant_b@me.com>: fix: PrivateEndpoint.raw_predict parameter name Fixes #6101 Changed parameter name from 'body' to 'data' in PrivateEndpoint.raw_predict to match google-auth-transport's AuthorizedSession.post() API signature. The google-auth-transport library updated its API, changing the parameter name from 'body' to 'data'. The Endpoint class was already updated to use 'data', but PrivateEndpoint class was missed, causing TypeError when calling raw_predict() on PrivateEndpoint instances. This fix aligns PrivateEndpoint.raw_predict() with Endpoint.raw_predict() implementation. Signed-off-by: Yashwant Bezawada <yashwant_b@me.com> COPYBARA_INTEGRATE_REVIEW=#6107 from yashwantbezawada:fix/private-endpoint-raw-predict-parameter e550151 PiperOrigin-RevId: 904180559
1 parent e566540 commit 3d380ba

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

google/cloud/aiplatform/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4240,7 +4240,7 @@ def raw_predict(
42404240
url = f"https://{endpoint_override}/v1/projects/{self.project}/locations/{self.location}/endpoints/{self.name}:rawPredict"
42414241
return self._authorized_session.post(
42424242
url=url,
4243-
body=body,
4243+
data=body,
42444244
headers=headers,
42454245
)
42464246

0 commit comments

Comments
 (0)