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

NameError in generated Ads service templates #882

Closed
BenRKarl opened this issue May 12, 2021 · 3 comments
Closed

NameError in generated Ads service templates #882

BenRKarl opened this issue May 12, 2021 · 3 comments
Labels
triage me I really want to be triaged.

Comments

@BenRKarl
Copy link
Contributor

A recent change seems to have changed the import statement for field_mask_pb2 but not the calling code further down in the file. The issue is that the following:

from google.protobuf import field_mask_pb2 as gp_field_mask  # type: ignore

Is now being generated as:

from google.protobuf import field_mask_pb2 # type: ignore

Resulting in the error:

NameError: name 'gp_field_mask' is not defined

It seems to only be isolated to two places in a single file, for example here.

And here's the proto definition for that class.

@BenRKarl
Copy link
Contributor Author

Just noticed it's also an issue with this field as well.

In previous versions we saw:

from google.rpc import status_pb2 as gr_status  # type: ignore 

But now:

from google.rpc import status_pb2 # type: ignore 

@yoshi-automation yoshi-automation added the triage me I really want to be triaged. label May 14, 2021
@busunkim96
Copy link
Contributor

Ah sorry about that. This was fixed in #883 (latest release 0.46.3)

@BenRKarl
Copy link
Contributor Author

Awesome! I'll close this for now but will reopen if we see any other issues after the next time we regenerate. Thanks for the quick turnaround!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage me I really want to be triaged.
Projects
None yet
Development

No branches or pull requests

3 participants