Skip to content
This repository has been archived by the owner on Jul 6, 2023. It is now read-only.

docs: Fix formatting of request arg in docstring #223

Merged
merged 3 commits into from
Mar 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 3 additions & 4 deletions google/cloud/tpu_v1/services/tpu/async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -370,8 +370,7 @@ async def sample_get_node():

Args:
request (Optional[Union[google.cloud.tpu_v1.types.GetNodeRequest, dict]]):
The request object. Request for
[GetNode][google.cloud.tpu.v1.Tpu.GetNode].
The request object. Request for [GetNode][google.cloud.tpu.v1.Tpu.GetNode].
name (:class:`str`):
Required. The resource name.
This corresponds to the ``name`` field
Expand Down Expand Up @@ -1014,7 +1013,7 @@ async def sample_list_tensor_flow_versions():
Returns:
google.cloud.tpu_v1.services.tpu.pagers.ListTensorFlowVersionsAsyncPager:
Response for
[ListTensorFlowVersions][google.cloud.tpu.v1.Tpu.ListTensorFlowVersions].
[ListTensorFlowVersions][google.cloud.tpu.v1.Tpu.ListTensorFlowVersions].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down Expand Up @@ -1227,7 +1226,7 @@ async def sample_list_accelerator_types():
Returns:
google.cloud.tpu_v1.services.tpu.pagers.ListAcceleratorTypesAsyncPager:
Response for
[ListAcceleratorTypes][google.cloud.tpu.v1.Tpu.ListAcceleratorTypes].
[ListAcceleratorTypes][google.cloud.tpu.v1.Tpu.ListAcceleratorTypes].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down
7 changes: 3 additions & 4 deletions google/cloud/tpu_v1/services/tpu/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -643,8 +643,7 @@ def sample_get_node():

Args:
request (Union[google.cloud.tpu_v1.types.GetNodeRequest, dict]):
The request object. Request for
[GetNode][google.cloud.tpu.v1.Tpu.GetNode].
The request object. Request for [GetNode][google.cloud.tpu.v1.Tpu.GetNode].
name (str):
Required. The resource name.
This corresponds to the ``name`` field
Expand Down Expand Up @@ -1290,7 +1289,7 @@ def sample_list_tensor_flow_versions():
Returns:
google.cloud.tpu_v1.services.tpu.pagers.ListTensorFlowVersionsPager:
Response for
[ListTensorFlowVersions][google.cloud.tpu.v1.Tpu.ListTensorFlowVersions].
[ListTensorFlowVersions][google.cloud.tpu.v1.Tpu.ListTensorFlowVersions].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down Expand Up @@ -1505,7 +1504,7 @@ def sample_list_accelerator_types():
Returns:
google.cloud.tpu_v1.services.tpu.pagers.ListAcceleratorTypesPager:
Response for
[ListAcceleratorTypes][google.cloud.tpu.v1.Tpu.ListAcceleratorTypes].
[ListAcceleratorTypes][google.cloud.tpu.v1.Tpu.ListAcceleratorTypes].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down
11 changes: 5 additions & 6 deletions google/cloud/tpu_v2/services/tpu/async_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -370,8 +370,7 @@ async def sample_get_node():

Args:
request (Optional[Union[google.cloud.tpu_v2.types.GetNodeRequest, dict]]):
The request object. Request for
[GetNode][google.cloud.tpu.v2.Tpu.GetNode].
The request object. Request for [GetNode][google.cloud.tpu.v2.Tpu.GetNode].
name (:class:`str`):
Required. The resource name.
This corresponds to the ``name`` field
Expand Down Expand Up @@ -1058,7 +1057,7 @@ async def sample_generate_service_identity():
Returns:
google.cloud.tpu_v2.types.GenerateServiceIdentityResponse:
Response for
[GenerateServiceIdentity][google.cloud.tpu.v2.Tpu.GenerateServiceIdentity].
[GenerateServiceIdentity][google.cloud.tpu.v2.Tpu.GenerateServiceIdentity].

"""
# Create or coerce a protobuf request object.
Expand Down Expand Up @@ -1145,7 +1144,7 @@ async def sample_list_accelerator_types():
Returns:
google.cloud.tpu_v2.services.tpu.pagers.ListAcceleratorTypesAsyncPager:
Response for
[ListAcceleratorTypes][google.cloud.tpu.v2.Tpu.ListAcceleratorTypes].
[ListAcceleratorTypes][google.cloud.tpu.v2.Tpu.ListAcceleratorTypes].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down Expand Up @@ -1358,7 +1357,7 @@ async def sample_list_runtime_versions():
Returns:
google.cloud.tpu_v2.services.tpu.pagers.ListRuntimeVersionsAsyncPager:
Response for
[ListRuntimeVersions][google.cloud.tpu.v2.Tpu.ListRuntimeVersions].
[ListRuntimeVersions][google.cloud.tpu.v2.Tpu.ListRuntimeVersions].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down Expand Up @@ -1564,7 +1563,7 @@ async def sample_get_guest_attributes():
Returns:
google.cloud.tpu_v2.types.GetGuestAttributesResponse:
Response for
[GetGuestAttributes][google.cloud.tpu.v2.Tpu.GetGuestAttributes].
[GetGuestAttributes][google.cloud.tpu.v2.Tpu.GetGuestAttributes].

"""
# Create or coerce a protobuf request object.
Expand Down
11 changes: 5 additions & 6 deletions google/cloud/tpu_v2/services/tpu/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -647,8 +647,7 @@ def sample_get_node():

Args:
request (Union[google.cloud.tpu_v2.types.GetNodeRequest, dict]):
The request object. Request for
[GetNode][google.cloud.tpu.v2.Tpu.GetNode].
The request object. Request for [GetNode][google.cloud.tpu.v2.Tpu.GetNode].
name (str):
Required. The resource name.
This corresponds to the ``name`` field
Expand Down Expand Up @@ -1337,7 +1336,7 @@ def sample_generate_service_identity():
Returns:
google.cloud.tpu_v2.types.GenerateServiceIdentityResponse:
Response for
[GenerateServiceIdentity][google.cloud.tpu.v2.Tpu.GenerateServiceIdentity].
[GenerateServiceIdentity][google.cloud.tpu.v2.Tpu.GenerateServiceIdentity].

"""
# Create or coerce a protobuf request object.
Expand Down Expand Up @@ -1427,7 +1426,7 @@ def sample_list_accelerator_types():
Returns:
google.cloud.tpu_v2.services.tpu.pagers.ListAcceleratorTypesPager:
Response for
[ListAcceleratorTypes][google.cloud.tpu.v2.Tpu.ListAcceleratorTypes].
[ListAcceleratorTypes][google.cloud.tpu.v2.Tpu.ListAcceleratorTypes].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down Expand Up @@ -1640,7 +1639,7 @@ def sample_list_runtime_versions():
Returns:
google.cloud.tpu_v2.services.tpu.pagers.ListRuntimeVersionsPager:
Response for
[ListRuntimeVersions][google.cloud.tpu.v2.Tpu.ListRuntimeVersions].
[ListRuntimeVersions][google.cloud.tpu.v2.Tpu.ListRuntimeVersions].

Iterating over this object will yield results and
resolve additional pages automatically.
Expand Down Expand Up @@ -1846,7 +1845,7 @@ def sample_get_guest_attributes():
Returns:
google.cloud.tpu_v2.types.GetGuestAttributesResponse:
Response for
[GetGuestAttributes][google.cloud.tpu.v2.Tpu.GetGuestAttributes].
[GetGuestAttributes][google.cloud.tpu.v2.Tpu.GetGuestAttributes].

"""
# Create or coerce a protobuf request object.
Expand Down
12 changes: 0 additions & 12 deletions google/cloud/tpu_v2/services/tpu/transports/rest.py
Original file line number Diff line number Diff line change
Expand Up @@ -779,7 +779,6 @@ def __call__(
request (~.cloud_tpu.CreateNodeRequest):
The request object. Request for
[CreateNode][google.cloud.tpu.v2.Tpu.CreateNode].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -877,7 +876,6 @@ def __call__(
request (~.cloud_tpu.DeleteNodeRequest):
The request object. Request for
[DeleteNode][google.cloud.tpu.v2.Tpu.DeleteNode].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -966,7 +964,6 @@ def __call__(
request (~.cloud_tpu.GenerateServiceIdentityRequest):
The request object. Request for
[GenerateServiceIdentity][google.cloud.tpu.v2.Tpu.GenerateServiceIdentity].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1067,7 +1064,6 @@ def __call__(
request (~.cloud_tpu.GetAcceleratorTypeRequest):
The request object. Request for
[GetAcceleratorType][google.cloud.tpu.v2.Tpu.GetAcceleratorType].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1159,7 +1155,6 @@ def __call__(
request (~.cloud_tpu.GetGuestAttributesRequest):
The request object. Request for
[GetGuestAttributes][google.cloud.tpu.v2.Tpu.GetGuestAttributes].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1346,7 +1341,6 @@ def __call__(
request (~.cloud_tpu.GetRuntimeVersionRequest):
The request object. Request for
[GetRuntimeVersion][google.cloud.tpu.v2.Tpu.GetRuntimeVersion].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1438,7 +1432,6 @@ def __call__(
request (~.cloud_tpu.ListAcceleratorTypesRequest):
The request object. Request for
[ListAcceleratorTypes][google.cloud.tpu.v2.Tpu.ListAcceleratorTypes].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1530,7 +1523,6 @@ def __call__(
request (~.cloud_tpu.ListNodesRequest):
The request object. Request for
[ListNodes][google.cloud.tpu.v2.Tpu.ListNodes].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1620,7 +1612,6 @@ def __call__(
request (~.cloud_tpu.ListRuntimeVersionsRequest):
The request object. Request for
[ListRuntimeVersions][google.cloud.tpu.v2.Tpu.ListRuntimeVersions].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1712,7 +1703,6 @@ def __call__(
request (~.cloud_tpu.StartNodeRequest):
The request object. Request for
[StartNode][google.cloud.tpu.v2.Tpu.StartNode].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1810,7 +1800,6 @@ def __call__(
request (~.cloud_tpu.StopNodeRequest):
The request object. Request for
[StopNode][google.cloud.tpu.v2.Tpu.StopNode].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down Expand Up @@ -1910,7 +1899,6 @@ def __call__(
request (~.cloud_tpu.UpdateNodeRequest):
The request object. Request for
[UpdateNode][google.cloud.tpu.v2.Tpu.UpdateNode].

retry (google.api_core.retry.Retry): Designation of what errors, if any,
should be retried.
timeout (float): The timeout for this request.
Expand Down