Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

samples.snippets.subscriber_test: test_remove_dead_letter_policy failed #227

Closed
flaky-bot bot opened this issue Oct 21, 2020 · 7 comments · Fixed by #233, #255, #263 or #298
Closed

samples.snippets.subscriber_test: test_remove_dead_letter_policy failed #227

flaky-bot bot opened this issue Oct 21, 2020 · 7 comments · Fixed by #233, #255, #263 or #298
Assignees
Labels
api: pubsub Issues related to the googleapis/python-pubsub API. priority: p2 Moderately-important priority. Fix may not be included in next release. samples Issues that are directly related to samples. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@flaky-bot
Copy link

flaky-bot bot commented Oct 21, 2020

This test failed!

To configure my behavior, see the Build Cop Bot documentation.

If I'm commenting on this issue too often, add the buildcop: quiet label and
I will stop commenting.


commit: 7de13b8
buildURL: Build Status, Sponge
status: failed

Test output
args = (subscription: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-94797d067923478cb47afe733b09d01a"
,)
kwargs = {'metadata': [('x-goog-request-params', 'subscription=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-94797d067923478cb47afe733b09d01a'), ('x-goog-api-client', 'gl-python/3.8.3 grpc/1.32.0 gax/1.23.0')]}
@six.wraps(callable_)
def error_remapped_callable(*args, **kwargs):
    try:
      return callable_(*args, **kwargs)

.nox/py-3-8/lib/python3.8/site-packages/google/api_core/grpc_helpers.py:57:


self = <grpc._channel._UnaryUnaryMultiCallable object at 0x7f24afc6d6a0>
request = subscription: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-94797d067923478cb47afe733b09d01a"

timeout = None
metadata = [('x-goog-request-params', 'subscription=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-94797d067923478cb47afe733b09d01a'), ('x-goog-api-client', 'gl-python/3.8.3 grpc/1.32.0 gax/1.23.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-8/lib/python3.8/site-packages/grpc/_channel.py:826:


state = <grpc._channel._RPCState object at 0x7f24acb35a00>
call = <grpc._cython.cygrpc.SegregatedCall object at 0x7f24afbb06c0>
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.UNKNOWN
E details = "Stream removed"
E debug_error_string = "{"created":"@1603278725.494860777","description":"Error received from peer ipv4:74.125.195.95:443","file":"src/core/lib/surface/call.cc","file_line":1061,"grpc_message":"Stream removed","grpc_status":2}"
E >

.nox/py-3-8/lib/python3.8/site-packages/grpc/_channel.py:729: _InactiveRpcError

The above exception was the direct cause of the following exception:

subscriber_client = <google.cloud.pubsub_v1.SubscriberClient object at 0x7f24afc81b50>
topic = 'projects/python-docs-samples-tests/topics/subscription-test-topic-94797d067923478cb47afe733b09d01a'

@pytest.fixture(scope="module")
def subscription_dlq(subscriber_client, topic):
    subscription_path = subscriber_client.subscription_path(PROJECT, SUBSCRIPTION_DLQ)

    try:
        subscription = subscriber_client.get_subscription(
            request={"subscription": subscription_path}
        )
    except:  # noqa
        subscription = subscriber_client.create_subscription(
            request={"name": subscription_path, "topic": topic}
        )

    yield subscription.name
  subscriber_client.delete_subscription(request={"subscription": subscription.name})

subscriber_test.py:144:


../../google/cloud/pubsub_v1/_gapic.py:40: in
fx = lambda self, *a, **kw: wrapped_fx(self.api, *a, **kw) # noqa
../../google/pubsub_v1/services/subscriber/client.py:723: in delete_subscription
rpc(
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/gapic_v1/method.py:145: in call
return wrapped_func(*args, **kwargs)
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/retry.py:281: in retry_wrapped_func
return retry_target(
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/retry.py:184: in retry_target
return target()
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/grpc_helpers.py:59: 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.UNKNOWN
details = "Stream removed"
debug_error
....195.95:443","file":"src/core/lib/surface/call.cc","file_line":1061,"grpc_message":"Stream removed","grpc_status":2}"

???
E google.api_core.exceptions.Unknown: None Stream removed

:3: Unknown

@flaky-bot flaky-bot bot added buildcop: issue priority: p1 Important issue which blocks shipping the next release. Will be fixed prior to next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Oct 21, 2020
@product-auto-label product-auto-label bot added api: pubsub Issues related to the googleapis/python-pubsub API. samples Issues that are directly related to samples. labels Oct 21, 2020
@flaky-bot
Copy link
Author

flaky-bot bot commented Oct 21, 2020

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 (7de13b8), this test passed in one build (Build Status, Sponge) and failed in another build (Build Status, Sponge).

@anguillanneuf anguillanneuf self-assigned this Oct 23, 2020
@anguillanneuf
Copy link
Contributor

I should probably remove test removing dead letter policy from subscription last.

@anguillanneuf anguillanneuf added priority: p2 Moderately-important priority. Fix may not be included in next release. and removed priority: p1 Important issue which blocks shipping the next release. Will be fixed prior to next release. labels Oct 23, 2020
@flaky-bot
Copy link
Author

flaky-bot bot commented Dec 14, 2020

Oops! Looks like this issue is still flaky. It failed again. 😬

I reopened the issue, but a human will need to close it again.


commit: 7c532a2
buildURL: Build Status, Sponge
status: failed

Test output
args = (subscription: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-c0137ef0edc348ab814fdfa3b38ed8ce"
,)
kwargs = {'metadata': [('x-goog-request-params', 'subscription=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-c0137ef0edc348ab814fdfa3b38ed8ce'), ('x-goog-api-client', 'gl-python/3.8.3 grpc/1.34.0 gax/1.23.0')]}
@six.wraps(callable_)
def error_remapped_callable(*args, **kwargs):
    try:
      return callable_(*args, **kwargs)

.nox/py-3-8/lib/python3.8/site-packages/google/api_core/grpc_helpers.py:57:


self = <grpc._channel._UnaryUnaryMultiCallable object at 0x7f02db3e67c0>
request = subscription: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-c0137ef0edc348ab814fdfa3b38ed8ce"

timeout = None
metadata = [('x-goog-request-params', 'subscription=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-c0137ef0edc348ab814fdfa3b38ed8ce'), ('x-goog-api-client', 'gl-python/3.8.3 grpc/1.34.0 gax/1.23.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-8/lib/python3.8/site-packages/grpc/_channel.py:923:


state = <grpc._channel._RPCState object at 0x7f02d9ff3430>
call = <grpc._cython.cygrpc.SegregatedCall object at 0x7f02db326480>
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.UNKNOWN
E details = "Stream removed"
E debug_error_string = "{"created":"@1607950552.854664425","description":"Error received from peer ipv4:108.177.98.95:443","file":"src/core/lib/surface/call.cc","file_line":1062,"grpc_message":"Stream removed","grpc_status":2}"
E >

.nox/py-3-8/lib/python3.8/site-packages/grpc/_channel.py:826: _InactiveRpcError

The above exception was the direct cause of the following exception:

subscriber_client = <google.cloud.pubsub_v1.SubscriberClient object at 0x7f02db422910>
topic = 'projects/python-docs-samples-tests/topics/subscription-test-topic-c0137ef0edc348ab814fdfa3b38ed8ce'
dead_letter_topic = 'projects/python-docs-samples-tests/topics/subscription-test-dead-letter-topic-c0137ef0edc348ab814fdfa3b38ed8ce'

@pytest.fixture(scope="module")
def subscription_dlq(subscriber_client, topic, dead_letter_topic):
    from google.cloud.pubsub_v1.types import DeadLetterPolicy

    subscription_path = subscriber_client.subscription_path(
        PROJECT_ID, SUBSCRIPTION_DLQ
    )

    try:
        subscription = subscriber_client.delete_subscription(
            request={"subscription": subscription_path}
        )
    except NotFound:
        request = {
            "name": subscription_path,
            "topic": topic,
            "dead_letter_policy": DeadLetterPolicy(
                dead_letter_topic=dead_letter_topic, max_delivery_attempts=10
            ),
        }
        subscription = subscriber_client.create_subscription(request)

    yield subscription.name
  subscriber_client.delete_subscription(request={"subscription": subscription.name})

subscriber_test.py:161:


../../google/cloud/pubsub_v1/_gapic.py:40: in
fx = lambda self, *a, **kw: wrapped_fx(self.api, *a, **kw) # noqa
../../google/pubsub_v1/services/subscriber/client.py:812: in delete_subscription
rpc(
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/gapic_v1/method.py:145: in call
return wrapped_func(*args, **kwargs)
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/retry.py:281: in retry_wrapped_func
return retry_target(
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/retry.py:184: in retry_target
return target()
.nox/py-3-8/lib/python3.8/site-packages/google/api_core/grpc_helpers.py:59: 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.UNKNOWN
details = "Stream removed"
debug_error
...7.98.95:443","file":"src/core/lib/surface/call.cc","file_line":1062,"grpc_message":"Stream removed","grpc_status":2}"

???
E google.api_core.exceptions.Unknown: None Stream removed

:3: Unknown

@flaky-bot
Copy link
Author

flaky-bot bot commented Dec 16, 2020

Oops! Looks like this issue is still flaky. It failed again. 😬

I reopened the issue, but a human will need to close it again.


commit: 94d738c
buildURL: Build Status, Sponge
status: failed

Test output
args = (subscription {
  name: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-40d5a960b...
update_mask {
  paths: "dead_letter_policy.dead_letter_topic"
  paths: "dead_letter_policy.max_delivery_attempts"
}
,)
kwargs = {'metadata': [('x-goog-request-params', 'subscription.name=projects/python-docs-samples-tests/subscriptions/subscripti...-subscription-dlq-40d5a960b4f54760bdfdb338dc1aae16'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.0')]}
@six.wraps(callable_)
def error_remapped_callable(*args, **kwargs):
    try:
      return callable_(*args, **kwargs)

.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:57:


self = <grpc._channel._UnaryUnaryMultiCallable object at 0x7f33f03ce710>
request = subscription {
name: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-40d5a960b4...
}
update_mask {
paths: "dead_letter_policy.dead_letter_topic"
paths: "dead_letter_policy.max_delivery_attempts"
}

timeout = None
metadata = [('x-goog-request-params', 'subscription.name=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-40d5a960b4f54760bdfdb338dc1aae16'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.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-7/lib/python3.7/site-packages/grpc/_channel.py:923:


state = <grpc._channel._RPCState object at 0x7f33f0149590>
call = <grpc._cython.cygrpc.SegregatedCall object at 0x7f33f03bc5a0>
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.INVALID_ARGUMENT
E details = "Invalid resource name given (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information."
E debug_error_string = "{"created":"@1608092726.017104807","description":"Error received from peer ipv4:74.125.195.95:443","file":"src/core/lib/surface/call.cc","file_line":1062,"grpc_message":"Invalid resource name given (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information.","grpc_status":3}"
E >

.nox/py-3-7/lib/python3.7/site-packages/grpc/_channel.py:826: _InactiveRpcError

The above exception was the direct cause of the following exception:

subscriber_client = <google.cloud.pubsub_v1.SubscriberClient object at 0x7f33f33a89d0>
subscription_dlq = 'projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-40d5a960b4f54760bdfdb338dc1aae16'

def test_remove_dead_letter_policy(subscriber_client, subscription_dlq):
    subscription_after_update = subscriber.remove_dead_letter_policy(
      PROJECT, TOPIC, SUBSCRIPTION_DLQ
    )

subscriber_test.py:367:


subscriber.py:361: in remove_dead_letter_policy
request={"subscription": subscription, "update_mask": update_mask}
../../google/cloud/pubsub_v1/_gapic.py:40: in
fx = lambda self, *a, **kw: wrapped_fx(self.api, *a, **kw) # noqa
../../google/pubsub_v1/services/subscriber/client.py:566: in update_subscription
response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,)
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/gapic_v1/method.py:145: in call
return wrapped_func(*args, **kwargs)
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:286: in retry_wrapped_func
on_error=on_error,
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:184: in retry_target
return target()
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:59: 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.INVALID_ARGUMENT
details = "Invalid resource nam... (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information.","grpc_status":3}"

???
E google.api_core.exceptions.InvalidArgument: 400 Invalid resource name given (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information.

:3: InvalidArgument

@flaky-bot
Copy link
Author

flaky-bot bot commented Dec 16, 2020

Oops! Looks like this issue is still flaky. It failed again. 😬

I reopened the issue, but a human will need to close it again.


commit: 94d738c
buildURL: Build Status, Sponge
status: failed

Test output
args = (subscription {
  name: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-b25ee1bba...
update_mask {
  paths: "dead_letter_policy.dead_letter_topic"
  paths: "dead_letter_policy.max_delivery_attempts"
}
,)
kwargs = {'metadata': [('x-goog-request-params', 'subscription.name=projects/python-docs-samples-tests/subscriptions/subscripti...-subscription-dlq-b25ee1bba52446f3b1a2844fdd400d3c'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.0')]}
@six.wraps(callable_)
def error_remapped_callable(*args, **kwargs):
    try:
      return callable_(*args, **kwargs)

.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:57:


self = <grpc._channel._UnaryUnaryMultiCallable object at 0x7f2270060390>
request = subscription {
name: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-b25ee1bba5...
}
update_mask {
paths: "dead_letter_policy.dead_letter_topic"
paths: "dead_letter_policy.max_delivery_attempts"
}

timeout = None
metadata = [('x-goog-request-params', 'subscription.name=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-b25ee1bba52446f3b1a2844fdd400d3c'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.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-7/lib/python3.7/site-packages/grpc/_channel.py:923:


state = <grpc._channel._RPCState object at 0x7f2270067950>
call = <grpc._cython.cygrpc.SegregatedCall object at 0x7f2270054960>
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.INVALID_ARGUMENT
E details = "Invalid resource name given (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information."
E debug_error_string = "{"created":"@1608093351.861847233","description":"Error received from peer ipv4:74.125.142.95:443","file":"src/core/lib/surface/call.cc","file_line":1062,"grpc_message":"Invalid resource name given (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information.","grpc_status":3}"
E >

.nox/py-3-7/lib/python3.7/site-packages/grpc/_channel.py:826: _InactiveRpcError

The above exception was the direct cause of the following exception:

subscriber_client = <google.cloud.pubsub_v1.SubscriberClient object at 0x7f22737c94d0>
subscription_dlq = 'projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-b25ee1bba52446f3b1a2844fdd400d3c'

def test_remove_dead_letter_policy(subscriber_client, subscription_dlq):
    subscription_after_update = subscriber.remove_dead_letter_policy(
      PROJECT, TOPIC, SUBSCRIPTION_DLQ
    )

subscriber_test.py:367:


subscriber.py:361: in remove_dead_letter_policy
request={"subscription": subscription, "update_mask": update_mask}
../../google/cloud/pubsub_v1/_gapic.py:40: in
fx = lambda self, *a, **kw: wrapped_fx(self.api, *a, **kw) # noqa
../../google/pubsub_v1/services/subscriber/client.py:566: in update_subscription
response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,)
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/gapic_v1/method.py:145: in call
return wrapped_func(*args, **kwargs)
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:286: in retry_wrapped_func
on_error=on_error,
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:184: in retry_target
return target()
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:59: 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.INVALID_ARGUMENT
details = "Invalid resource nam... (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information.","grpc_status":3}"

???
E google.api_core.exceptions.InvalidArgument: 400 Invalid resource name given (name=). Refer to https://cloud.google.com/pubsub/docs/admin#resource_names for more information.

:3: InvalidArgument

@flaky-bot flaky-bot bot reopened this Dec 16, 2020
@flaky-bot
Copy link
Author

flaky-bot bot commented Dec 16, 2020

Oops! Looks like this issue is still flaky. It failed again. 😬

I reopened the issue, but a human will need to close it again.


commit: 2584147
buildURL: Build Status, Sponge
status: failed

Test output
args = (subscription {
  name: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-765b12c32...sts/topics/subscription-test-topic-765b12c321bc42bb91d1caf9fafa8079"
}
update_mask {
  paths: "dead_letter_policy"
}
,)
kwargs = {'metadata': [('x-goog-request-params', 'subscription.name=projects/python-docs-samples-tests/subscriptions/subscripti...-subscription-dlq-765b12c321bc42bb91d1caf9fafa8079'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.0')]}
@six.wraps(callable_)
def error_remapped_callable(*args, **kwargs):
    try:
      return callable_(*args, **kwargs)

.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:57:


self = <grpc._channel._UnaryUnaryMultiCallable object at 0x7f050af5bc10>
request = subscription {
name: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-765b12c321...tests/topics/subscription-test-topic-765b12c321bc42bb91d1caf9fafa8079"
}
update_mask {
paths: "dead_letter_policy"
}

timeout = None
metadata = [('x-goog-request-params', 'subscription.name=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-765b12c321bc42bb91d1caf9fafa8079'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.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-7/lib/python3.7/site-packages/grpc/_channel.py:923:


state = <grpc._channel._RPCState object at 0x7f050afccf10>
call = <grpc._cython.cygrpc.SegregatedCall object at 0x7f050af4e320>
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.INTERNAL
E details = "A service error has occurred. Please retry your request. If the error persists, please report it. [code=e8c0]"
E debug_error_string = "{"created":"@1608116643.704405190","description":"Error received from peer ipv4:74.125.195.95:443","file":"src/core/lib/surface/call.cc","file_line":1062,"grpc_message":"A service error has occurred. Please retry your request. If the error persists, please report it. [code=e8c0]","grpc_status":13}"
E >

.nox/py-3-7/lib/python3.7/site-packages/grpc/_channel.py:826: _InactiveRpcError

The above exception was the direct cause of the following exception:

subscription_dlq = 'projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-765b12c321bc42bb91d1caf9fafa8079'
capsys = <_pytest.capture.CaptureFixture object at 0x7f05080ec8d0>

def test_remove_dead_letter_policy(subscription_dlq, capsys):
    subscription_after_update = subscriber.remove_dead_letter_policy(
      PROJECT_ID, TOPIC, SUBSCRIPTION_DLQ
    )

subscriber_test.py:390:


subscriber.py:362: in remove_dead_letter_policy
request={"subscription": subscription, "update_mask": update_mask}
../../google/cloud/pubsub_v1/_gapic.py:40: in
fx = lambda self, *a, **kw: wrapped_fx(self.api, *a, **kw) # noqa
../../google/pubsub_v1/services/subscriber/client.py:655: in update_subscription
response = rpc(request, retry=retry, timeout=timeout, metadata=metadata,)
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/gapic_v1/method.py:145: in call
return wrapped_func(*args, **kwargs)
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:286: in retry_wrapped_func
on_error=on_error,
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:184: in retry_target
return target()
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:59: 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.INTERNAL
details = "A service error has occurred...ror has occurred. Please retry your request. If the error persists, please report it. [code=e8c0]","grpc_status":13}"

???
E google.api_core.exceptions.InternalServerError: 500 A service error has occurred. Please retry your request. If the error persists, please report it. [code=e8c0]

:3: InternalServerError

@flaky-bot
Copy link
Author

flaky-bot bot commented Dec 25, 2020

Oops! Looks like this issue is still flaky. It failed again. 😬

I reopened the issue, but a human will need to close it again.


commit: fd2840c
buildURL: Build Status, Sponge
status: failed

Test output
args = (subscription: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-ffeff04a9e1d4d66ba4b5d94d24436aa"
,)
kwargs = {'metadata': [('x-goog-request-params', 'subscription=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-ffeff04a9e1d4d66ba4b5d94d24436aa'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.1')]}
@six.wraps(callable_)
def error_remapped_callable(*args, **kwargs):
    try:
      return callable_(*args, **kwargs)

.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:57:


self = <grpc._channel._UnaryUnaryMultiCallable object at 0x7f3897c56850>
request = subscription: "projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-ffeff04a9e1d4d66ba4b5d94d24436aa"

timeout = None
metadata = [('x-goog-request-params', 'subscription=projects/python-docs-samples-tests/subscriptions/subscription-test-subscription-dlq-ffeff04a9e1d4d66ba4b5d94d24436aa'), ('x-goog-api-client', 'gl-python/3.7.7 grpc/1.34.0 gax/1.24.1')]
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-7/lib/python3.7/site-packages/grpc/_channel.py:923:


state = <grpc._channel._RPCState object at 0x7f3897ac8e10>
call = <grpc._cython.cygrpc.SegregatedCall object at 0x7f38949bbaf0>
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.UNKNOWN
E details = "Stream removed"
E debug_error_string = "{"created":"@1608894440.787204005","description":"Error received from peer ipv4:173.194.202.95:443","file":"src/core/lib/surface/call.cc","file_line":1062,"grpc_message":"Stream removed","grpc_status":2}"
E >

.nox/py-3-7/lib/python3.7/site-packages/grpc/_channel.py:826: _InactiveRpcError

The above exception was the direct cause of the following exception:

subscriber_client = <google.cloud.pubsub_v1.SubscriberClient object at 0x7f3897d01c90>
topic = 'projects/python-docs-samples-tests/topics/subscription-test-topic-ffeff04a9e1d4d66ba4b5d94d24436aa'
dead_letter_topic = 'projects/python-docs-samples-tests/topics/subscription-test-dead-letter-topic-ffeff04a9e1d4d66ba4b5d94d24436aa'

@pytest.fixture(scope="module")
def subscription_dlq(subscriber_client, topic, dead_letter_topic):
    from google.cloud.pubsub_v1.types import DeadLetterPolicy

    subscription_path = subscriber_client.subscription_path(
        PROJECT_ID, SUBSCRIPTION_DLQ
    )

    try:
        subscription = subscriber_client.delete_subscription(
            request={"subscription": subscription_path}
        )
    except NotFound:
        request = {
            "name": subscription_path,
            "topic": topic,
            "dead_letter_policy": DeadLetterPolicy(
                dead_letter_topic=dead_letter_topic, max_delivery_attempts=10
            ),
        }
        subscription = subscriber_client.create_subscription(request)

    yield subscription.name
  subscriber_client.delete_subscription(request={"subscription": subscription.name})

subscriber_test.py:161:


../../google/cloud/pubsub_v1/_gapic.py:40: in
fx = lambda self, *a, **kw: wrapped_fx(self.api, *a, **kw) # noqa
../../google/pubsub_v1/services/subscriber/client.py:813: in delete_subscription
request, retry=retry, timeout=timeout, metadata=metadata,
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/gapic_v1/method.py:145: in call
return wrapped_func(*args, **kwargs)
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:286: in retry_wrapped_func
on_error=on_error,
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/retry.py:184: in retry_target
return target()
.nox/py-3-7/lib/python3.7/site-packages/google/api_core/grpc_helpers.py:59: 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.UNKNOWN
details = "Stream removed"
debug_error
....202.95:443","file":"src/core/lib/surface/call.cc","file_line":1062,"grpc_message":"Stream removed","grpc_status":2}"

???
E google.api_core.exceptions.Unknown: None Stream removed

:3: Unknown

@flaky-bot flaky-bot bot reopened this Dec 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: pubsub Issues related to the googleapis/python-pubsub API. priority: p2 Moderately-important priority. Fix may not be included in next release. samples Issues that are directly related to samples. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
1 participant