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

PubSub 0.37.1 Subscription Client is Broken #5820

Closed
niwa-kazutomo opened this issue Aug 20, 2018 · 3 comments
Closed

PubSub 0.37.1 Subscription Client is Broken #5820

niwa-kazutomo opened this issue Aug 20, 2018 · 3 comments
Assignees
Labels
api: pubsub Issues related to the Pub/Sub API. 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. type: question Request for information or clarification. Not an issue.

Comments

@niwa-kazutomo
Copy link

Hi,

I encountered the following error.

  File "/******/PubsubAccessor.py", line 129, in create_subscriber_client
    credentials=credentials,
  File "/******/lib/python2.7/site-packages/google/cloud/pubsub_v1/gapic/subscriber_client.py", line 188, in __init__
    self.iam_policy_stub = (iam_policy_pb2.IAMPolicyStub(channel))
  File "/******/lib/python2.7/site-packages/google/iam/v1/iam_policy_pb2.py", line 344, in __init__
    self.SetIamPolicy = channel.unary_unary(
AttributeError: 'NoneType' object has no attribute 'unary_unary'

This problem did not occur in 0.35.4.
I checked the commit log and found a strange part.

371333a#diff-e221f62050dd418b49b113c7909d0ea2L129

Channel initialization processing has been deleted.

371333a#diff-e221f62050dd418b49b113c7909d0ea2R188

However, implementations using channel remain.

Thanks,
Kazutomo

@tseaver tseaver added type: question Request for information or clarification. Not an issue. api: pubsub Issues related to the Pub/Sub API. packaging labels Aug 20, 2018
@tseaver
Copy link
Contributor

tseaver commented Aug 20, 2018

@theacodes I believe you have the state to point this issue in the right direction.

@theacodes theacodes added type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. priority: p1 Important issue which blocks shipping the next release. Will be fixed prior to next release. and removed packaging labels Aug 20, 2018
@theacodes
Copy link
Contributor

@lukesneeringer

@lukesneeringer
Copy link
Contributor

Lines 188 and 189 in subscriber_client.py should not be there.
As best as I can tell, gapic-generator does not write them, so this was probably an incomplete sync of some kind? If you re-generate, you should get a file without those lines. (A similar edit applies to publisher_client.py.)

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 Pub/Sub API. 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. type: question Request for information or clarification. Not an issue.
Projects
None yet
Development

No branches or pull requests

4 participants