You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
__________ERRORatsetupofTestInstanceAdminAPI.test_cluster_exists__________target=functools.partial(<boundmethodPollingFuture._done_or_raiseof<google.api_core.operation.Operationobjectat0x7fb024845240>>)
predicate=<functionif_exception_type.<locals>.if_exception_type_predicateat0x7fb0249bc488>sleep_generator=<generatorobjectexponential_sleep_generatorat0x7fb024880930>deadline=10, on_error=Nonedefretry_target(target, predicate, sleep_generator, deadline, on_error=None):
"""Call a function and retry if it fails. This is the lowest-level retry helper. Generally, you'll use the higher-level retry helper :class:`Retry`. Args: target(Callable): The function to call and retry. This must be a nullary function - apply arguments with `functools.partial`. predicate (Callable[Exception]): A callable used to determine if an exception raised by the target should be considered retryable. It should return True to retry or False otherwise. sleep_generator (Iterable[float]): An infinite iterator that determines how long to sleep between retries. deadline (float): How long to keep retrying the target. on_error (Callable): A function to call while processing a retryable exception. Any error raised by this function will *not* be caught. Returns: Any: the return value of the target function. Raises: google.api_core.RetryError: If the deadline is exceeded while retrying. ValueError: If the sleep generator stops yielding values. Exception: If the target raises a method that isn't retryable. """ifdeadlineisnotNone:
deadline_datetime=datetime_helpers.utcnow() +datetime.timedelta(
seconds=deadline
)
else:
deadline_datetime=Nonelast_exc=Noneforsleepinsleep_generator:
try:
>returntarget()
../api_core/google/api_core/retry.py:182:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self=<google.api_core.operation.Operationobjectat0x7fb024845240>def_done_or_raise(self):
"""Check if the future is done and raise if it's not."""ifnotself.done():
>raise_OperationNotComplete()
Egoogle.api_core.future.polling._OperationNotComplete
../api_core/google/api_core/future/polling.py:81: _OperationNotCompleteTheaboveexceptionwasthedirectcauseofthefollowingexception:
self=<google.api_core.operation.Operationobjectat0x7fb024845240>timeout=10def_blocking_poll(self, timeout=None):
"""Poll and wait for the Future to be resolved. Args: timeout (int): How long (in seconds) to wait for the operation to complete. If None, wait indefinitely. """ifself._result_set:
returnretry_=self._retry.with_deadline(timeout)
try:
>retry_(self._done_or_raise)()
../api_core/google/api_core/future/polling.py:101:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
args= (), kwargs= {}
target=functools.partial(<boundmethodPollingFuture._done_or_raiseof<google.api_core.operation.Operationobjectat0x7fb024845240>>)
sleep_generator=<generatorobjectexponential_sleep_generatorat0x7fb024880930>@general_helpers.wraps(func)defretry_wrapped_func(*args, **kwargs):
"""A wrapper that calls target function with retry."""target=functools.partial(func, *args, **kwargs)
sleep_generator=exponential_sleep_generator(
self._initial, self._maximum, multiplier=self._multiplier
)
returnretry_target(
target,
self._predicate,
sleep_generator,
self._deadline,
>on_error=on_error,
)
../api_core/google/api_core/retry.py:277:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
target=functools.partial(<boundmethodPollingFuture._done_or_raiseof<google.api_core.operation.Operationobjectat0x7fb024845240>>)
predicate=<functionif_exception_type.<locals>.if_exception_type_predicateat0x7fb0249bc488>sleep_generator=<generatorobjectexponential_sleep_generatorat0x7fb024880930>deadline=10, on_error=Nonedefretry_target(target, predicate, sleep_generator, deadline, on_error=None):
"""Call a function and retry if it fails. This is the lowest-level retry helper. Generally, you'll use the higher-level retry helper :class:`Retry`. Args: target(Callable): The function to call and retry. This must be a nullary function - apply arguments with `functools.partial`. predicate (Callable[Exception]): A callable used to determine if an exception raised by the target should be considered retryable. It should return True to retry or False otherwise. sleep_generator (Iterable[float]): An infinite iterator that determines how long to sleep between retries. deadline (float): How long to keep retrying the target. on_error (Callable): A function to call while processing a retryable exception. Any error raised by this function will *not* be caught. Returns: Any: the return value of the target function. Raises: google.api_core.RetryError: If the deadline is exceeded while retrying. ValueError: If the sleep generator stops yielding values. Exception: If the target raises a method that isn't retryable. """ifdeadlineisnotNone:
deadline_datetime=datetime_helpers.utcnow() +datetime.timedelta(
seconds=deadline
)
else:
deadline_datetime=Nonelast_exc=Noneforsleepinsleep_generator:
try:
returntarget()
# pylint: disable=broad-except# This function explicitly must deal with broad exceptions.exceptExceptionasexc:
ifnotpredicate(exc):
raiselast_exc=excifon_errorisnotNone:
on_error(exc)
now=datetime_helpers.utcnow()
ifdeadline_datetimeisnotNoneanddeadline_datetime<now:
six.raise_from(
exceptions.RetryError(
"Deadline of {:.1f}s exceeded while calling {}".format(
deadline, target
),
last_exc,
),
>last_exc,
)
../api_core/google/api_core/retry.py:202:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
value=None, from_value=_OperationNotComplete()
> ???
Egoogle.api_core.exceptions.RetryError: Deadlineof10.0sexceededwhilecallingfunctools.partial(<boundmethodPollingFuture._done_or_raiseof<google.api_core.operation.Operationobjectat0x7fb024845240>>), lastexception:
<string>:3: RetryErrorDuringhandlingoftheaboveexception, anotherexceptionoccurred:
defsetUpModule():
fromgoogle.cloud.exceptionsimportGrpcRendezvousfromgoogle.cloud.bigtable.enumsimportInstance# See: https://github.com/googleapis/google-cloud-python/issues/5928interfaces=table_admin_config.config["interfaces"]
iface_config=interfaces["google.bigtable.admin.v2.BigtableTableAdmin"]
methods=iface_config["methods"]
create_table=methods["CreateTable"]
create_table["timeout_millis"] =90000Config.IN_EMULATOR=os.getenv(BIGTABLE_EMULATOR) isnotNoneifConfig.IN_EMULATOR:
credentials=EmulatorCreds()
Config.CLIENT=Client(admin=True, credentials=credentials)
else:
Config.CLIENT=Client(admin=True)
Config.INSTANCE=Config.CLIENT.instance(INSTANCE_ID, labels=LABELS)
Config.CLUSTER=Config.INSTANCE.cluster(
CLUSTER_ID, location_id=LOCATION_ID, serve_nodes=SERVE_NODES
)
Config.INSTANCE_DATA=Config.CLIENT.instance(
INSTANCE_ID_DATA, instance_type=Instance.Type.DEVELOPMENT, labels=LABELS
)
Config.CLUSTER_DATA=Config.INSTANCE_DATA.cluster(
CLUSTER_ID_DATA, location_id=LOCATION_ID
)
ifnotConfig.IN_EMULATOR:
retry=RetryErrors(GrpcRendezvous, error_predicate=_retry_on_unavailable)
instances, failed_locations=retry(Config.CLIENT.list_instances)()
iflen(failed_locations) !=0:
raiseValueError("List instances failed in module set up.")
EXISTING_INSTANCES[:] =instances# After listing, create the test instances.admin_op=Config.INSTANCE.create(clusters=[Config.CLUSTER])
admin_op.result(timeout=10)
data_op=Config.INSTANCE_DATA.create(clusters=[Config.CLUSTER_DATA])
>data_op.result(timeout=10)
tests/system.py:141:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
../api_core/google/api_core/future/polling.py:122: inresultself._blocking_poll(timeout=timeout)
__ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self=<google.api_core.operation.Operationobjectat0x7fb024845240>timeout=10def_blocking_poll(self, timeout=None):
"""Poll and wait for the Future to be resolved. Args: timeout (int): How long (in seconds) to wait for the operation to complete. If None, wait indefinitely. """ifself._result_set:
returnretry_=self._retry.with_deadline(timeout)
try:
retry_(self._done_or_raise)()
exceptexceptions.RetryError:
raiseconcurrent.futures.TimeoutError(
>"Operation did not complete within the designated ""timeout."
)
Econcurrent.futures._base.TimeoutError: Operationdidnotcompletewithinthedesignatedtimeout.
../api_core/google/api_core/future/polling.py:104: TimeoutError
From this CI failure:
Repeated multiple times.