Skip to content

Conversation

@gguuss
Copy link
Contributor

@gguuss gguuss commented Oct 4, 2019

No description provided.

@gguuss gguuss self-assigned this Oct 4, 2019
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Oct 4, 2019
@gguuss gguuss requested a review from dpebot October 4, 2019 19:55
@gguuss gguuss requested a review from crwilcox October 4, 2019 22:12
@gguuss
Copy link
Contributor Author

gguuss commented Oct 8, 2019

Now I remember - all of the CRUD methods started failing for this sample. As far as I can tell, the library updates should not affect the API calls. In fact, downgrading to the previous commit does not affect test results:

______________________________________________________________________________________ test_create_feed _______________________________________________________________________________________
Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 57, in error_remapped_callable
    return callable_(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 604, in __call__
    return _end_unary_response_blocking(state, call, False, None)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 506, in _end_unary_response_blocking
    raise _Rendezvous(state, None, None, deadline)
grpc._channel._Rendezvous: <_Rendezvous of RPC that terminated with:
        status = StatusCode.INVALID_ARGUMENT
        details = "Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305)."
        debug_error_string = "{"created":"@1570561326.443398903","description":"Error received from peer ipv6:[2607:f8b0:400a:804::200a]:443","file":"src/core/lib/surface/call.cc","file_line":1055,"grpc_message":"Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).","grpc_status":3}"
>

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

Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_createfeed_test.py", line 40, in test_create_feed
    PROJECT, FEED_ID, [ASSET_NAME, ], full_topic_name)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_createfeed.py", line 36, in create_feed
    response = client.create_feed(parent, feed_id, feed)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/cloud/asset_v1p2beta1/gapic/asset_service_client.py", line 524, in create_feed
    request, retry=retry, timeout=timeout, metadata=metadata
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/gapic_v1/method.py", line 143, in __call__
    return wrapped_func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 277, in retry_wrapped_func
    on_error=on_error,
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 182, in retry_target
    return target()
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/timeout.py", line 214, in func_with_timeout
    return func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 59, in error_remapped_callable
    six.raise_from(exceptions.from_grpc_error(exc), exc)
  File "<string>", line 3, in raise_from
google.api_core.exceptions.InvalidArgument: 400 Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).
______________________________________________________________________________________ test_delete_feed _______________________________________________________________________________________
Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 57, in error_remapped_callable
    return callable_(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 604, in __call__
    return _end_unary_response_blocking(state, call, False, None)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 506, in _end_unary_response_blocking
    raise _Rendezvous(state, None, None, deadline)
grpc._channel._Rendezvous: <_Rendezvous of RPC that terminated with:
        status = StatusCode.INVALID_ARGUMENT
        details = "Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305)."
        debug_error_string = "{"created":"@1570561327.361421362","description":"Error received from peer ipv6:[2607:f8b0:400a:804::200a]:443","file":"src/core/lib/surface/call.cc","file_line":1055,"grpc_message":"Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).","grpc_status":3}"
>

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

Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_deletefeed_test.py", line 38, in test_delete_feed
    PROJECT, FEED_ID, [ASSET_NAME, ], full_topic_name)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_createfeed.py", line 36, in create_feed
    response = client.create_feed(parent, feed_id, feed)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/cloud/asset_v1p2beta1/gapic/asset_service_client.py", line 524, in create_feed
    request, retry=retry, timeout=timeout, metadata=metadata
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/gapic_v1/method.py", line 143, in __call__
    return wrapped_func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 277, in retry_wrapped_func
    on_error=on_error,
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 182, in retry_target
    return target()
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/timeout.py", line 214, in func_with_timeout
    return func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 59, in error_remapped_callable
    six.raise_from(exceptions.from_grpc_error(exc), exc)
  File "<string>", line 3, in raise_from
google.api_core.exceptions.InvalidArgument: 400 Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).
________________________________________________________________________________________ test_get_feed ________________________________________________________________________________________
Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 57, in error_remapped_callable
    return callable_(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 604, in __call__
    return _end_unary_response_blocking(state, call, False, None)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 506, in _end_unary_response_blocking
    raise _Rendezvous(state, None, None, deadline)
grpc._channel._Rendezvous: <_Rendezvous of RPC that terminated with:
        status = StatusCode.INVALID_ARGUMENT
        details = "Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305)."
        debug_error_string = "{"created":"@1570561361.012064894","description":"Error received from peer ipv6:[2607:f8b0:400a:804::200a]:443","file":"src/core/lib/surface/call.cc","file_line":1055,"grpc_message":"Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).","grpc_status":3}"
>

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

Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_getfeed_test.py", line 39, in test_get_feed
    PROJECT, FEED_ID, [ASSET_NAME, ], full_topic_name)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_createfeed.py", line 36, in create_feed
    response = client.create_feed(parent, feed_id, feed)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/cloud/asset_v1p2beta1/gapic/asset_service_client.py", line 524, in create_feed
    request, retry=retry, timeout=timeout, metadata=metadata
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/gapic_v1/method.py", line 143, in __call__
    return wrapped_func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 277, in retry_wrapped_func
    on_error=on_error,
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 182, in retry_target
    return target()
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/timeout.py", line 214, in func_with_timeout
    return func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 59, in error_remapped_callable
    six.raise_from(exceptions.from_grpc_error(exc), exc)
  File "<string>", line 3, in raise_from
google.api_core.exceptions.InvalidArgument: 400 Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).
______________________________________________________________________________________ test_update_feed _______________________________________________________________________________________
Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 57, in error_remapped_callable
    return callable_(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 604, in __call__
    return _end_unary_response_blocking(state, call, False, None)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/grpc/_channel.py", line 506, in _end_unary_response_blocking
    raise _Rendezvous(state, None, None, deadline)
grpc._channel._Rendezvous: <_Rendezvous of RPC that terminated with:
        status = StatusCode.INVALID_ARGUMENT
        details = "Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305)."
        debug_error_string = "{"created":"@1570561362.660226737","description":"Error received from peer ipv6:[2607:f8b0:400a:804::200a]:443","file":"src/core/lib/surface/call.cc","file_line":1055,"grpc_message":"Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).","grpc_status":3}"
>

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

Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_updatefeed_test.py", line 40, in test_update_feed
    PROJECT, FEED_ID, [ASSET_NAME, ], full_topic_name)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/asset/cloud-client/quickstart_createfeed.py", line 36, in create_feed
    response = client.create_feed(parent, feed_id, feed)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/cloud/asset_v1p2beta1/gapic/asset_service_client.py", line 524, in create_feed
    request, retry=retry, timeout=timeout, metadata=metadata
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/gapic_v1/method.py", line 143, in __call__
    return wrapped_func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 277, in retry_wrapped_func
    on_error=on_error,
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/retry.py", line 182, in retry_target
    return target()
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/timeout.py", line 214, in func_with_timeout
    return func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-asset-cloud-client/lib/python3.6/site-packages/google/api_core/grpc_helpers.py", line 59, in error_remapped_callable
    six.raise_from(exceptions.from_grpc_error(exc), exc)
  File "<string>", line 3, in raise_from
google.api_core.exceptions.InvalidArgument: 400 Fail to use projects/intense-wavelet-343/topics/topic-1570561305 as feed output destination. Error: Resource not found (resource=topic-1570561305).

Unable to determine how to set up the tests, I gave up on contributing fixes in this case. It's entirely possible there's a race condition or pre-sample setup that is missing.

Copy link
Contributor Author

@gguuss gguuss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The CRUD tests in asset were almost definitely broken. I think the right thing to do is follow up internally with cwxie

@gguuss
Copy link
Contributor Author

gguuss commented Oct 10, 2019

Tracking down cwxie worked, the tests are now re-enabled and fixed!

@gguuss gguuss requested a review from crwilcox October 16, 2019 17:59
@gguuss gguuss closed this Oct 16, 2019
@gguuss gguuss reopened this Oct 16, 2019
@gguuss
Copy link
Contributor Author

gguuss commented Oct 16, 2019

@tswast Any idea why the composer tests might be failing (e.g. API changes, not unexpected responses)?

@tswast
Copy link
Contributor

tswast commented Oct 16, 2019

@gguuss It's due to a dependency problem in apache-airflow[gcp_api]==1.10.3 #2471 (comment) Supposedly fixed in 1.10.4

@gguuss
Copy link
Contributor Author

gguuss commented Oct 16, 2019

@tswast I tried pinning an older version of flask, still seeing:

Traceback (most recent call last):
  File "/usr/local/google/home/class/code/samples/python-docs-samples/composer/workflows/kubernetes_pod_operator_test.py", line 24, in test_dag_import
    from . import kubernetes_pod_operator as module
  File "/usr/local/google/home/class/code/samples/python-docs-samples/composer/workflows/kubernetes_pod_operator.py", line 215, in <module>
    affinity={})
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-composer-workflows/lib/python3.6/site-packages/airflow/utils/decorators.py", line 98, in wrapper
    result = func(*args, **kwargs)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-composer-workflows/lib/python3.6/site-packages/airflow/contrib/operators/kubernetes_pod_operator.py", line 229, in __init__
    self.resources = self._set_resources(resources)
  File "/usr/local/google/home/class/code/samples/python-docs-samples/.nox/py36-sample-composer-workflows/lib/python3.6/site-packages/airflow/contrib/operators/kubernetes_pod_operator.py", line 169, in _set_resources
    for item in resources.keys():
AttributeError: 'Resources' object has no attribute 'keys'

I'll see about downgrading to 1.10.2

@tswast
Copy link
Contributor

tswast commented Oct 16, 2019

@leahecole Gus's traceback seems to indicate there's a new Resources object in some Kubernetes logic that used to be a dictionary. Any ideas? Or should we just disable the kubernetespodoperator test for now?

@leahecole
Copy link
Collaborator

Ugh given that it's blocking other people, I'd say disable it and assign either an issue, a buganizer bug, or both to me to fix once I'm back from this trip. I'll be able to take a look at it the week of the 28th, but I don't want it to block folks before then.

@gguuss
Copy link
Contributor Author

gguuss commented Oct 17, 2019

I found a "fix", which is to pass the dictionary from the pod resource object instead of the object itself.

@leahecole
Copy link
Collaborator

heh. Noted. @gguuss do you need any action from me at this point? If so, let me know and I'll prioritize it for Monday.

@gguuss
Copy link
Contributor Author

gguuss commented Oct 18, 2019 via email

@gguuss
Copy link
Contributor Author

gguuss commented Oct 23, 2019

@crwilcox friendly ping :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants