-
Notifications
You must be signed in to change notification settings - Fork 309
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
Breaking Change: update model.py classes to use proto-plus instead of _pb #319
Comments
@tswast After getting a bit more work done here, I saw that routine also uses https://github.com/googleapis/python-bigquery/blob/master/google/cloud/bigquery/routine.py#L202 When the line above runs, resource is equal to This is an example of the kind of under the hood name and type conversion that I'm working on this still, but I wanted to describe this issue that has complicated the work a bit. |
Alternatively, we could switch to returning dictionaries for these BigQuery ML classes. The proto definitions aren't republished as often as I first anticipated, as it's a manual process. |
Dictionaries would be a worse experience from an IDE and docs perspective, though. |
Closing in favor of #814 |
Currently the classes in
model.py
use the underlying protobuf_pb
object for read-only properties instead of the proto-plus object.python-bigquery/google/cloud/bigquery/model.py
Line 58 in b8f502b
This avoided some possible breaking changes, but was mostly done to expedite the transition to the microgenerator.
There are some benefits to using proto-plus that would be worth taking advantage of. Most importantly, timestamp well-known types are properly translated into a datetime-like object with proto-plus.
Why now?
There are some breaking changes in the latest generated clients due to googleapis/gapic-generator-python#595
If we need to make a breaking change for these changes, we might as well update the classes to support the latest versions.
The text was updated successfully, but these errors were encountered: