GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat: resource tags in dataset by keunsoopark · Pull Request #2090 · googleapis/python-bigquery

This repository was archived by the owner on Mar 6, 2026. It is now read-only.

Conversation

@keunsoopark

@keunsoopark keunsoopark commented Dec 19, 2024 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor
  • 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 #2091 🦕

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Park Keunsoo
feat: resource tags in dataset
66e09af
@keunsoopark
keunsoopark requested review from a team and leahecole December 19, 2024 13:26
@product-auto-label product-auto-label Bot added the size: m Pull request size is medium. label Dec 19, 2024
@blunderbuss-gcf blunderbuss-gcf Bot assigned yirutang Dec 19, 2024
@product-auto-label product-auto-label Bot added the api: bigquery Issues related to the googleapis/python-bigquery API. label Dec 19, 2024
@keunsoopark
keunsoopark marked this pull request as draft December 19, 2024 13:50
@keunsoopark
keunsoopark marked this pull request as ready for review December 19, 2024 13:50
@keunsoopark
keunsoopark marked this pull request as draft December 19, 2024 15:38
Park Keunsoo
fix: fix unittets
120abc8
@keunsoopark
keunsoopark marked this pull request as ready for review December 19, 2024 15:38
@keunsoopark keunsoopark mentioned this pull request Dec 20, 2024
[Feature] Allow for Setting of IAM Tags dbt-labs/dbt-adapters#577
Open
3 tasks done
@Linchin
Delete dataset/pyvenv.cfg
3d03e73
Linchin
Linchin reviewed Dec 20, 2024
View reviewed changes
Comment thread google/cloud/bigquery/dataset.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Linchin
Linchin reviewed Dec 20, 2024
View reviewed changes
Comment thread google/cloud/bigquery/dataset.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

Linchin
Linchin suggested changes Dec 20, 2024
View reviewed changes

@Linchin Linchin left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Thank you so much for adding resource tags in dataset! The PR looks great overall, I just made some minor modifications. I wonder if you could add a system test, as well as a unit test for setter with None? Please let us know if you need any help. Happy holidays!

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Linchin Linchin added kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Dec 20, 2024
@Linchin Linchin assigned Linchin and unassigned yirutang Dec 20, 2024
@yoshi-kokoro yoshi-kokoro removed kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Dec 20, 2024
keunsoopark and others added 5 commits December 23, 2024 09:54
@keunsoopark @Linchin
Update google/cloud/bigquery/dataset.py
c56d005
Co-authored-by: Lingqing Gan <[email protected]>
@keunsoopark @Linchin
Update google/cloud/bigquery/dataset.py
d26539f
Co-authored-by: Lingqing Gan <[email protected]>
Park Keunsoo
added system tests & fix unittest for none
c647485
Park Keunsoo
add missing assert
3d317d1
Park Keunsoo
remove venv
359a9e1
@keunsoopark

keunsoopark commented Dec 23, 2024

Copy link
Copy Markdown
Contributor Author

system test

Hi @Linchin, thanks for the review.

I added system tests in system/test_clients.py

I fixed unittests for None, and added more tests for invalid values. See test_resource_tags_setter_bad_value.

Merry Christmas and happy new year!

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Linchin
Merge branch 'main' into feat/resource_tags_in_dataset
32ce734
@Linchin Linchin added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jan 13, 2025
@yoshi-kokoro yoshi-kokoro removed kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Jan 13, 2025
@Linchin

Linchin commented Jan 13, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

The 3.12 system test is still failing - after trying to create the resource tag and finding that it already exists, the code tries to access it and gets PermissionDenied error, which indicates that the tag either doesn't exist, or the client doesn't have the permission to access it. I suspect there is a race condition where the tag was created by sys test 3.8 when 3.12 was trying to create it, and deleted when 3.12 tries to access it 😂 Let me rerun the tests to see if it's flaky, so we can verify the assumption.

If this is indeed the case, we may need to append the python version to the tags to avoid conflict.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Linchin Linchin added kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Jan 13, 2025
@yoshi-kokoro yoshi-kokoro removed kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Jan 13, 2025
@Linchin Linchin added kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Jan 14, 2025
@yoshi-kokoro yoshi-kokoro removed kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Jan 14, 2025
Park Keunsoo
make tag keys unique
233f276
@keunsoopark

keunsoopark commented Jan 14, 2025

Copy link
Copy Markdown
Contributor Author

The 3.12 system test is still failing - after trying to create the resource tag and finding that it already exists, the code tries to access it and gets PermissionDenied error, which indicates that the tag either doesn't exist, or the client doesn't have the permission to access it. I suspect there is a race condition where the tag was created by sys test 3.8 when 3.12 was trying to create it, and deleted when 3.12 tries to access it 😂 Let me rerun the tests to see if it's flaky, so we can verify the assumption.

If this is indeed the case, we may need to append the python version to the tags to avoid conflict.

Thanks for a good inspiration! I agree that we should make each of test running independent. Instead of postfixing python version, I postfixed random characters to tag keys. I see it works well from my local testing.

In previous run, all tests failed all of sudden, and I could no see logs any longer. Could you check if it happens again in next CI tests?

Linchin reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Linchin

Linchin commented Jan 14, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Thank you for the prompt reply! Adding a prefix lgtm. I think there was something wrong with the test infra, I hope it's just flaky and doesn't happen again.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Linchin Linchin added kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Jan 14, 2025
@yoshi-kokoro yoshi-kokoro removed kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Jan 14, 2025
Park Keunsoo
remove unused import
fed4570
@Linchin Linchin added the kokoro:run Add this label to force Kokoro to re-run the tests. label Jan 14, 2025
@Linchin
Merge branch 'main' into feat/resource_tags_in_dataset
3fd848b
Linchin
Linchin approved these changes Jan 14, 2025
View reviewed changes

@Linchin Linchin left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Thank you for your contribution, now all tests have passed! 🎉

LGTM.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@release-please release-please Bot mentioned this pull request Jan 14, 2025
chore(main): release 3.28.0 #2056
Merged
@keunsoopark

keunsoopark commented Jan 14, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

Thank you for your contribution, now all tests have passed! 🎉

LGTM.

Thank you so much! It was a pleasant review process with you, @Linchin :)
My motivation to this contribution is for making dbt able to attach resource tags - dbt-labs/dbt-adapters#577. As you see in this issue, it requires this functionality on tables as well.
I am looking forward to other PR - #2093 done soon, but if it takes too long time to get response, I can contribute it as well. Now I can fix this feature pretty quickly :)
Just ping me if you want me to be involved.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Linchin

Linchin commented Jan 14, 2025

Copy link
Copy Markdown
Contributor

It was a pleasure working with you! @keunsoopark

Let's first see if the original author of #2093 responses, then we can decide what to do next.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

This was referenced Jan 21, 2025
January 20, 2025 kitta65/bq-extension-vscode#639
Closed
January 20, 2025 kitta65/prettier-plugin-bq#579
Closed
January 20, 2025 kitta65/bq2cst#468
Closed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Reviewers

@leahecole leahecole Awaiting requested review from leahecole
1 more reviewer
@Linchin Linchin Linchin approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@Linchin Linchin

Labels

api: bigquery Issues related to the googleapis/python-bigquery API. size: m Pull request size is medium.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Attach resource tags on datasets

Uh oh!

There was an error while loading. Please reload this page.

4 participants

@keunsoopark @Linchin @yirutang @yoshi-kokoro
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.