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

feat: add fields parameter to set_iam_policy for consistency with update methods #1872

Merged
merged 2 commits into from
Mar 27, 2024

Conversation

tswast
Copy link
Contributor

@tswast tswast commented Mar 26, 2024

Also:

  • Add docstrings for get_iam_policy and set_iam_policy
  • Add code sample for get_iam_policy and set_iam_policy

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 #1871 🦕

@tswast tswast requested review from a team as code owners March 26, 2024 15:46
Copy link

snippet-bot bot commented Mar 26, 2024

Here is the summary of changes.

You are about to add 1 region tag.

This comment is generated by snippet-bot.
If you find problems with this result, please file an issue at:
https://github.com/googleapis/repo-automation-bots/issues.
To update this comment, add snippet-bot:force-run label or use the checkbox below:

  • Refresh this comment

@product-auto-label product-auto-label bot added size: m Pull request size is medium. api: bigquery Issues related to the googleapis/python-bigquery API. labels Mar 26, 2024
@tswast tswast requested a review from Linchin March 26, 2024 15:46
def test_create_iam_policy(table_id: str):
your_table_id = table_id

# [START bigquery_create_iam_policy]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@@ -1485,33 +1484,6 @@ def test_copy_table(self):
got_rows = self._fetch_single_page(dest_table)
self.assertTrue(len(got_rows) > 0)

def test_get_set_iam_policy(self):
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This test is now redundant with a code sample which serves the same purpose with regards to testing.

Copy link
Collaborator

@chalmerlowe chalmerlowe left a comment

Choose a reason for hiding this comment

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

LGTM

@tswast tswast enabled auto-merge (squash) March 27, 2024 14:59
@tswast tswast merged commit 08b1e6f into main Mar 27, 2024
19 checks passed
@tswast tswast deleted the issue1871-get_iam_policy-set_iam_policy branch March 27, 2024 15:28
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 API. size: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

get_iam_policy and set_iam_policy are missing doc strings
2 participants