Skip to content
This repository was archived by the owner on Apr 1, 2026. It is now read-only.

fix: Ensure message fields are copied when building retry request - #533

Merged
igorbernstein2 merged 5 commits into
mainfrom
retry-request-fix
Mar 17, 2022
Merged

fix: Ensure message fields are copied when building retry request#533
igorbernstein2 merged 5 commits into
mainfrom
retry-request-fix

Conversation

@Mariatta

@Mariatta Mariatta commented Mar 10, 2022

Copy link
Copy Markdown
Contributor

Use the copy_from() function when building the ReadRowsRequest arguments.

Fixes internal bug #214449800

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)

Fixes #214449800 🦕

Use the to_dict() function when building the ReadRowsRequest arguments.

This way, all available fields in the message will get copied over.
The `message.filter` field needed a special handling, since the to_dict() function doesn't seem to parse the value the way we want it to be.

Fixes internal bug #214449800
@Mariatta
Mariatta requested review from a team March 10, 2022 00:06
@product-auto-label product-auto-label Bot added the api: bigtable Issues related to the googleapis/python-bigtable API. label Mar 10, 2022
@Mariatta Mariatta added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Mar 10, 2022
@yoshi-kokoro yoshi-kokoro removed kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Mar 10, 2022
copy_from doesn't copy over "empty" fields, so had to adjust the test case expected values.

@igorbernstein2 igorbernstein2 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It looks like unit tests are broken. Please fix

Comment thread google/cloud/bigtable/row_data.py Outdated
Comment thread google/cloud/bigtable/row_data.py
@Mariatta
Mariatta requested a review from igorbernstein2 March 14, 2022 22:46

@igorbernstein2 igorbernstein2 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

lgtm

@igorbernstein2
igorbernstein2 merged commit ff7f190 into main Mar 17, 2022
@igorbernstein2
igorbernstein2 deleted the retry-request-fix branch March 17, 2022 20:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

api: bigtable Issues related to the googleapis/python-bigtable API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants