Skip to content

fix: adapt the iam binding update logic to the latest constraints #1838

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

shobsi
Copy link
Contributor

@shobsi shobsi commented Jun 20, 2025

This is needed as some recent updates to a dependency (google-cloud-resource-manager or its dependencies) broke the existing logic, and we are seeing the error like this:
--> policy.bindings.append(new_binding)
TypeError: Expected a message object, but got {'role': 'roles/run.invoker', 'members': [...]}

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 internal issues 419589974, 425442503 🦕

This is needed as some recent updates to a dependency (google-cloud-resource-manager or its dependencies) broke the existing logic, and we are seeing the
error like this:
--> policy.bindings.append(new_binding)
TypeError: Expected a message object, but got {'role': 'roles/run.invoker', 'members': [...]}
@shobsi shobsi requested a review from tswast June 20, 2025 20:18
@shobsi shobsi requested review from a team as code owners June 20, 2025 20:18
@product-auto-label product-auto-label bot added size: xs Pull request size is extra small. api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. labels Jun 20, 2025
@shobsi
Copy link
Contributor Author

shobsi commented Jun 21, 2025

@tswast looks like the google.iam usage was done away with in #1611, so this change is effectively reverting that. Let's discuss how should we keep things working in both external and internal environments.

@tswast
Copy link
Collaborator

tswast commented Jun 21, 2025

Let's try to update google3 first. That google.iam namespace is indeed problematic

@tswast
Copy link
Collaborator

tswast commented Jun 21, 2025

CC @parthea Did the gapic generator make a breaking change to no longer allow dictionary inputs?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. size: xs Pull request size is extra small.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants