Repository navigation
samples.samples.backup_sample_test: test_restore_database failed #321
Description
Note: #265 was also for this test, but it was closed more than 10 days ago. So, I didn't mark it flaky.
commit: 7bddb81
buildURL: Build Status, Sponge
status: failed
Test output
args = (parent: "projects/python-docs-samples-tests/instances/test-instance-cb071c9acc"
database_id: "test-db-03194bdc9f"
backup: "projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/backups/test-backup-888713c2aa"
,)
kwargs = {'metadata': [('google-cloud-resource-prefix', 'projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/...sts/instances/test-instance-cb071c9acc'), ('x-goog-api-client', 'gl-python/3.6.13 grpc/1.37.0 gax/1.26.3 gccl/3.3.0')]}
@six.wraps(callable_)
def error_remapped_callable(*args, **kwargs):
try:
return callable_(*args, **kwargs)
.nox/py-3-6/lib/python3.6/site-packages/google/api_core/grpc_helpers.py:73:
self = <grpc._channel._UnaryUnaryMultiCallable object at 0x7f1d17506b38>
request = parent: "projects/python-docs-samples-tests/instances/test-instance-cb071c9acc"
database_id: "test-db-03194bdc9f"
backup: "projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/backups/test-backup-888713c2aa"
timeout = None
metadata = [('google-cloud-resource-prefix', 'projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/databases/tes...ests/instances/test-instance-cb071c9acc'), ('x-goog-api-client', 'gl-python/3.6.13 grpc/1.37.0 gax/1.26.3 gccl/3.3.0')]
credentials = None, wait_for_ready = None, compression = None
def __call__(self,
request,
timeout=None,
metadata=None,
credentials=None,
wait_for_ready=None,
compression=None):
state, call, = self._blocking(request, timeout, metadata, credentials,
wait_for_ready, compression)
return _end_unary_response_blocking(state, call, False, None)
.nox/py-3-6/lib/python3.6/site-packages/grpc/_channel.py:946:
state = <grpc._channel._RPCState object at 0x7f1d17506be0>
call = <grpc._cython.cygrpc.SegregatedCall object at 0x7f1d17471a08>
with_call = False, deadline = None
def _end_unary_response_blocking(state, call, with_call, deadline):
if state.code is grpc.StatusCode.OK:
if with_call:
rendezvous = _MultiThreadedRendezvous(state, call, None, deadline)
return state.response, rendezvous
else:
return state.response
else:
raise _InactiveRpcError(state)
E grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
E status = StatusCode.FAILED_PRECONDITION
E details = "Cannot create database projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/databases/test-db-03194bdc9f from backup projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/backups/test-backup-888713c2aa because the backup is still being created. Please retry the operation once the pending backup is complete."
E debug_error_string = "{"created":"@1619429450.424122356","description":"Error received from peer ipv4:108.177.98.95:443","file":"src/core/lib/surface/call.cc","file_line":1067,"grpc_message":"Cannot create database projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/databases/test-db-03194bdc9f from backup projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/backups/test-backup-888713c2aa because the backup is still being created. Please retry the operation once the pending backup is complete.","grpc_status":9}"
E >
.nox/py-3-6/lib/python3.6/site-packages/grpc/_channel.py:849: _InactiveRpcError
The above exception was the direct cause of the following exception:
capsys = <_pytest.capture.CaptureFixture object at 0x7f1d17523710>
@RetryErrors(exception=DeadlineExceeded, max_tries=2)
def test_restore_database(capsys):
backup_sample.restore_database(INSTANCE_ID, RESTORE_DB_ID, BACKUP_ID)
backup_sample_test.py:83:
backup_sample.py:69: in restore_database
operation = new_database.restore(backup)
../../google/cloud/spanner_v1/database.py:665: in restore
future = api.restore_database(request=request, metadata=metadata,)
../../google/cloud/spanner_admin_database_v1/services/database_admin/client.py:1906: in restore_database
response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,)
.nox/py-3-6/lib/python3.6/site-packages/google/api_core/gapic_v1/method.py:145: in call
return wrapped_func(*args, **kwargs)
.nox/py-3-6/lib/python3.6/site-packages/google/api_core/grpc_helpers.py:75: in error_remapped_callable
six.raise_from(exceptions.from_grpc_error(exc), exc)
value = None
from_value = <_InactiveRpcError of RPC that terminated with:
status = StatusCode.FAILED_PRECONDITION
details = "Cannot create dat...the backup is still being created. Please retry the operation once the pending backup is complete.","grpc_status":9}"
???
E google.api_core.exceptions.FailedPrecondition: 400 Cannot create database projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/databases/test-db-03194bdc9f from backup projects/python-docs-samples-tests/instances/test-instance-cb071c9acc/backups/test-backup-888713c2aa because the backup is still being created. Please retry the operation once the pending backup is complete.
:3: FailedPrecondition
Activity
flaky-bot commentedon Apr 26, 2021
Looks like this issue is flaky. 😟
I'm going to leave this open and stop commenting.
A human should fix and close this.
When run at the same commit (7bddb81), this test passed in one build (Build Status, Sponge) and failed in another build (Build Status, Sponge).
larkee commentedon Apr 26, 2021
Failed due to #320