Skip to content
Permalink
Browse files
chore: use gapic-generator-python 0.52.0 (#152)
- [ ] Regenerate this pull request now.

fix: improper types in pagers generation
PiperOrigin-RevId: 399773015

Source-Link: googleapis/googleapis@410c184

Source-Link: googleapis/googleapis-gen@290e883
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMjkwZTg4MzU0NWUzYWM5ZmYyYmQwMGNkMGRhY2IyOGYxYjhjYTk0NSJ9
  • Loading branch information
gcf-owl-bot committed Sep 30, 2021
1 parent 7f2eaf6 commit 68142512b75ee81a1fee0e982edd00a617706a00
Showing with 12 additions and 12 deletions.
  1. +6 −6 google/cloud/container_v1/services/cluster_manager/pagers.py
  2. +6 −6 google/cloud/container_v1beta1/services/cluster_manager/pagers.py
@@ -15,13 +15,13 @@
#
from typing import (
Any,
AsyncIterable,
AsyncIterator,
Awaitable,
Callable,
Iterable,
Sequence,
Tuple,
Optional,
Iterator,
)

from google.cloud.container_v1.types import cluster_service
@@ -74,14 +74,14 @@ def __getattr__(self, name: str) -> Any:
return getattr(self._response, name)

@property
def pages(self) -> Iterable[cluster_service.ListUsableSubnetworksResponse]:
def pages(self) -> Iterator[cluster_service.ListUsableSubnetworksResponse]:
yield self._response
while self._response.next_page_token:
self._request.page_token = self._response.next_page_token
self._response = self._method(self._request, metadata=self._metadata)
yield self._response

def __iter__(self) -> Iterable[cluster_service.UsableSubnetwork]:
def __iter__(self) -> Iterator[cluster_service.UsableSubnetwork]:
for page in self.pages:
yield from page.subnetworks

@@ -138,14 +138,14 @@ def __getattr__(self, name: str) -> Any:
@property
async def pages(
self,
) -> AsyncIterable[cluster_service.ListUsableSubnetworksResponse]:
) -> AsyncIterator[cluster_service.ListUsableSubnetworksResponse]:
yield self._response
while self._response.next_page_token:
self._request.page_token = self._response.next_page_token
self._response = await self._method(self._request, metadata=self._metadata)
yield self._response

def __aiter__(self) -> AsyncIterable[cluster_service.UsableSubnetwork]:
def __aiter__(self) -> AsyncIterator[cluster_service.UsableSubnetwork]:
async def async_generator():
async for page in self.pages:
for response in page.subnetworks:
@@ -15,13 +15,13 @@
#
from typing import (
Any,
AsyncIterable,
AsyncIterator,
Awaitable,
Callable,
Iterable,
Sequence,
Tuple,
Optional,
Iterator,
)

from google.cloud.container_v1beta1.types import cluster_service
@@ -74,14 +74,14 @@ def __getattr__(self, name: str) -> Any:
return getattr(self._response, name)

@property
def pages(self) -> Iterable[cluster_service.ListUsableSubnetworksResponse]:
def pages(self) -> Iterator[cluster_service.ListUsableSubnetworksResponse]:
yield self._response
while self._response.next_page_token:
self._request.page_token = self._response.next_page_token
self._response = self._method(self._request, metadata=self._metadata)
yield self._response

def __iter__(self) -> Iterable[cluster_service.UsableSubnetwork]:
def __iter__(self) -> Iterator[cluster_service.UsableSubnetwork]:
for page in self.pages:
yield from page.subnetworks

@@ -138,14 +138,14 @@ def __getattr__(self, name: str) -> Any:
@property
async def pages(
self,
) -> AsyncIterable[cluster_service.ListUsableSubnetworksResponse]:
) -> AsyncIterator[cluster_service.ListUsableSubnetworksResponse]:
yield self._response
while self._response.next_page_token:
self._request.page_token = self._response.next_page_token
self._response = await self._method(self._request, metadata=self._metadata)
yield self._response

def __aiter__(self) -> AsyncIterable[cluster_service.UsableSubnetwork]:
def __aiter__(self) -> AsyncIterator[cluster_service.UsableSubnetwork]:
async def async_generator():
async for page in self.pages:
for response in page.subnetworks:

0 comments on commit 6814251

Please sign in to comment.