You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by "jrmccluskey (via GitHub)" <gi...@apache.org> on 2026/09/30 15:59:06 UTC
[PR] [Claude] Produce Beam-specific representation of BQ resources, rework compat shims [beam]
jrmccluskey opened a new pull request, #40359:
URL: https://github.com/apache/beam/pull/40359
Implements Beam-specific representations of BQ resource types to act as intermediaries between Beam and BigQuery types. Also reworks bigquery_compat.py to provide methods that convert between the legacy apitools types and these new type representations.
Part of #37261
------------------------
Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:
- [ ] Mention the appropriate issue in your description (for example: `addresses #123`), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, comment `fixes #<ISSUE NUMBER>` instead.
- [ ] Update `CHANGES.md` with noteworthy changes.
- [ ] If this contribution is large, please file an Apache [Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
See the [Contributor Guide](https://beam.apache.org/contribute) for more tips on [how to make review process smoother](https://github.com/apache/beam/blob/master/CONTRIBUTING.md#make-the-reviewers-job-easier).
To check the build health, please visit [https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md](https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md)
GitHub Actions Tests Status (on master branch)
------------------------------------------------------------------------------------------------
[](https://github.com/apache/beam/actions?query=workflow%3A%22Build+python+source+distribution+and+wheels%22+branch%3Amaster+event%3Aschedule)
[](https://github.com/apache/beam/actions?query=workflow%3A%22Python+Tests%22+branch%3Amaster+event%3Aschedule)
[](https://github.com/apache/beam/actions?query=workflow%3A%22Java+Tests%22+branch%3Amaster+event%3Aschedule)
[](https://github.com/apache/beam/actions?query=workflow%3A%22Go+tests%22+branch%3Amaster+event%3Aschedule)
See [CI.md](https://github.com/apache/beam/blob/master/CI.md) for more information about GitHub Actions CI or the [workflows README](https://github.com/apache/beam/blob/master/.github/workflows/README.md) to see a list of phrases to trigger workflows.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Claude] Produce Beam-specific representation of BQ resources, rework compat shims [beam]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #40359:
URL: https://github.com/apache/beam/pull/40359#issuecomment-6130066409
Assigning reviewers:
R: @damccorm for label python.
Note: If you would like to opt out of this review, comment `assign to next reviewer`.
Available commands:
- `stop reviewer notifications` - opt out of the automated review tooling
- `remind me after tests pass` - tag the comment author after tests pass
- `waiting on author` - shift the attention set back to the author (any comment or push by the author will return the attention set to the reviewers)
The PR bot will only process comments in the main thread (not review comments).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Claude] Produce Beam-specific representation of BQ resources, rework compat shims [beam]
Posted by "jrmccluskey (via GitHub)" <gi...@apache.org>.
jrmccluskey commented on code in PR #40359:
URL: https://github.com/apache/beam/pull/40359#discussion_r4251930611
##########
sdks/python/apache_beam/io/gcp/bigquery_compat.py:
##########
@@ -15,1440 +15,152 @@
# limitations under the License.
#
-"""Compatibility shims and legacy client emulation for BigQuery.
+"""Bridge for legacy apitools BigQuery message inputs.
Review Comment:
There were a number of problems once I tried to actually move BQ interactions over to the new client while maintaining the old routing which led to a really tangled web of failing test cases and mismatched behavior, along with a lot of branches in the code based on the client being used. A second iteration of the idea (partially represented here) is to have Beam maintain its own representations of BQ resources that get passed to a specific backend at runtime (either the modern or legacy client) that converts the beam-specific implementation to the framework specific types as needed. Then the backend implementations either route to the new client or the old one.
Coming back to this particular approach after not looking at it for a few weeks, I'm not stoked with all of the scaffolding that goes into temporarily supporting multiple approaches when the end goal is to only support one at the end anyway. I think I'm waiving the white flag on the AI driven approach to this one, it's well past time to just write a doc instead.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Claude] Produce Beam-specific representation of BQ resources, rework compat shims [beam]
Posted by "damccorm (via GitHub)" <gi...@apache.org>.
damccorm commented on code in PR #40359:
URL: https://github.com/apache/beam/pull/40359#discussion_r4251709791
##########
sdks/python/apache_beam/io/gcp/bigquery_compat.py:
##########
@@ -15,1440 +15,152 @@
# limitations under the License.
#
-"""Compatibility shims and legacy client emulation for BigQuery.
+"""Bridge for legacy apitools BigQuery message inputs.
Review Comment:
I'm having a hard time orienting myself in this PR. Could you help me with a few things before I fully jump in:
1) Could you give an overarching summary of what the PR is trying to accomplish? Is the idea basically that instead of emulating the old client, we convert the type to just use the new client (isn't this still basically emulating the client?)?
2) Any recommendations on how to review this? Or are there ways to split it up? Should I review this file as a diff or just a replacement?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Claude] Produce Beam-specific representation of BQ resources, rework compat shims [beam]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #40359:
URL: https://github.com/apache/beam/pull/40359#issuecomment-5916130468
Checks are failing. Will not request review until checks are succeeding. If you'd like to override that behavior, comment `assign set of reviewers`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [Claude] Produce Beam-specific representation of BQ resources, rework compat shims [beam]
Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #40359:
URL: https://github.com/apache/beam/pull/40359#issuecomment-6129832117
## [Codecov](https://app.codecov.io/gh/apache/beam/pull/40359?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
:x: Patch coverage is `99.06250%` with `3 lines` in your changes missing coverage. Please review.
:white_check_mark: Project coverage is 79.94%. Comparing base ([`76f6e6d`](https://app.codecov.io/gh/apache/beam/commit/76f6e6d7c0c1b2ce582c73d068ad9260cf15c5f3?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`9e22fa5`](https://app.codecov.io/gh/apache/beam/commit/9e22fa5f939b75a70e5145e3506bb97001f24b50?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 133 commits behind head on master.
| [Files with missing lines](https://app.codecov.io/gh/apache/beam/pull/40359?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines |
|---|---|---|
| [...ks/python/apache\_beam/io/gcp/bigquery\_resources.py](https://app.codecov.io/gh/apache/beam/pull/40359?src=pr&el=tree&filepath=sdks%2Fpython%2Fapache_beam%2Fio%2Fgcp%2Fbigquery_resources.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c2Rrcy9weXRob24vYXBhY2hlX2JlYW0vaW8vZ2NwL2JpZ3F1ZXJ5X3Jlc291cmNlcy5weQ==) | 98.89% | [3 Missing :warning: ](https://app.codecov.io/gh/apache/beam/pull/40359?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## master #40359 +/- ##
=============================================
+ Coverage 56.16% 79.94% +23.77%
=============================================
Files 1124 488 -636
Lines 178336 81734 -96602
Branches 1489 0 -1489
=============================================
- Hits 100170 65339 -34831
+ Misses 75645 16395 -59250
+ Partials 2521 0 -2521
```
| [Flag](https://app.codecov.io/gh/apache/beam/pull/40359/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
|---|---|---|
| [go](https://app.codecov.io/gh/apache/beam/pull/40359/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [java](https://app.codecov.io/gh/apache/beam/pull/40359/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `?` | |
| [python](https://app.codecov.io/gh/apache/beam/pull/40359/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `79.94% <99.06%> (+0.38%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
</details>
[:umbrella: View full report in Codecov by Harness](https://app.codecov.io/gh/apache/beam/pull/40359?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
- :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@beam.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org