Skip to content

Commit afe5372

Browse files
Improve docstring
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
1 parent 261a13e commit afe5372

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

infrahub_sdk/client.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -894,13 +894,17 @@ async def execute_graphql(
894894
branch_name (str, optional): Name of the branch on which the query will be executed. Defaults to None.
895895
at (str, optional): Time when the query should be executed. Defaults to None.
896896
timeout (int, optional): Timeout in second for the query. Defaults to None.
897-
raise_for_error (bool, optional): Deprecated, flag to indicate that we need to raise an exception if the response has some errors.
898-
Defaults to True.
897+
raise_for_error (bool | None, optional): Deprecated. Controls only HTTP status handling.
898+
- None (default) or True: HTTP errors raise via resp.raise_for_status().
899+
- False: HTTP errors are not automatically raised.
900+
GraphQL errors always raise GraphQLError.
901+
Defaults to None.
902+
899903
Raises:
900-
GraphQLError: _description_
904+
GraphQLError: When the GraphQL response contains errors.
901905
902906
Returns:
903-
_type_: _description_
907+
dict: The GraphQL data payload (response["data"]).
904908
"""
905909
if raise_for_error is not None:
906910
warnings.warn(

0 commit comments

Comments
 (0)