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/10/14 14:43:05 UTC
[PR] Update Trivial Inference for Python 3.15 [beam]
jrmccluskey opened a new pull request, #40578:
URL: https://github.com/apache/beam/pull/40578
Updates the trivial inference state machine for Python 3.15 opcodes. Tested locally; will not be exercised on-repo until 3.15 support is added outright.
Part of #40249
<!--
Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:
- [ ] If this contribution is large, please file an Apache [Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
- [ ] Replace these instructions with a description of your change and why you have made it.
- [ ] Mention the appropriate issue in your description (for example: `addresses #123` or `fixes #456`).
- [ ] Update `CHANGES.md` with noteworthy changes.
See [CONTRIBUTING.md]() for more 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
Re: [PR] Update Trivial Inference for Python 3.15 [beam]
Posted by "jrmccluskey (via GitHub)" <gi...@apache.org>.
jrmccluskey commented on code in PR #40578:
URL: https://github.com/apache/beam/pull/40578#discussion_r4283652970
##########
sdks/python/apache_beam/typehints/opcodes.py:
##########
@@ -506,6 +523,13 @@ def load_small_int(state, arg):
state.stack.append(Const(arg))
+def load_common_constant(state, arg):
Review Comment:
It doesn't have a direct call but will be used when the typehint tests run on 3.15. The functions defined in opcodes.py get imported in [infer_return_type_func()](https://github.com/apache/beam/blob/1a017df4529bc6b005eaa2a4d12ddb63fa2569f5/sdks/python/apache_beam/typehints/trivial_inference.py#L364) and placed into a dictionary, then [invoked through that dict entry](https://github.com/apache/beam/blob/1a017df4529bc6b005eaa2a4d12ddb63fa2569f5/sdks/python/apache_beam/typehints/trivial_inference.py#L631) rather than calling the function directly. This is the general convention for any operation that doesn't do more complex behavior like modifying the program counter
--
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] Update Trivial Inference for Python 3.15 [beam]
Posted by "damccorm (via GitHub)" <gi...@apache.org>.
damccorm commented on code in PR #40578:
URL: https://github.com/apache/beam/pull/40578#discussion_r4283538750
##########
sdks/python/apache_beam/typehints/opcodes.py:
##########
@@ -506,6 +523,13 @@ def load_small_int(state, arg):
state.stack.append(Const(arg))
+def load_common_constant(state, arg):
Review Comment:
Is this called anywhere?
--
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] Update Trivial Inference for Python 3.15 [beam]
Posted by "damccorm (via GitHub)" <gi...@apache.org>.
damccorm commented on code in PR #40578:
URL: https://github.com/apache/beam/pull/40578#discussion_r4283813757
##########
sdks/python/apache_beam/typehints/opcodes.py:
##########
@@ -506,6 +523,13 @@ def load_small_int(state, arg):
state.stack.append(Const(arg))
+def load_common_constant(state, arg):
Review Comment:
Got it, thanks
--
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] Update Trivial Inference for Python 3.15 [beam]
Posted by "jrmccluskey (via GitHub)" <gi...@apache.org>.
jrmccluskey merged PR #40578:
URL: https://github.com/apache/beam/pull/40578
--
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] Update Trivial Inference for Python 3.15 [beam]
Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #40578:
URL: https://github.com/apache/beam/pull/40578#issuecomment-6172704713
## [Codecov](https://app.codecov.io/gh/apache/beam/pull/40578?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 `35.00000%` with `13 lines` in your changes missing coverage. Please review.
:white_check_mark: Project coverage is 79.92%. 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 ([`2319e42`](https://app.codecov.io/gh/apache/beam/commit/2319e42b4766b8d91e4c85f333fbefe2c9311326?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 164 commits behind head on master.
| [Files with missing lines](https://app.codecov.io/gh/apache/beam/pull/40578?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines |
|---|---|---|
| [sdks/python/apache\_beam/typehints/opcodes.py](https://app.codecov.io/gh/apache/beam/pull/40578?src=pr&el=tree&filepath=sdks%2Fpython%2Fapache_beam%2Ftypehints%2Fopcodes.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c2Rrcy9weXRob24vYXBhY2hlX2JlYW0vdHlwZWhpbnRzL29wY29kZXMucHk=) | 27.27% | [8 Missing :warning: ](https://app.codecov.io/gh/apache/beam/pull/40578?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [.../python/apache\_beam/typehints/trivial\_inference.py](https://app.codecov.io/gh/apache/beam/pull/40578?src=pr&el=tree&filepath=sdks%2Fpython%2Fapache_beam%2Ftypehints%2Ftrivial_inference.py&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c2Rrcy9weXRob24vYXBhY2hlX2JlYW0vdHlwZWhpbnRzL3RyaXZpYWxfaW5mZXJlbmNlLnB5) | 44.44% | [5 Missing :warning: ](https://app.codecov.io/gh/apache/beam/pull/40578?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 #40578 +/- ##
=============================================
+ Coverage 56.16% 79.92% +23.75%
=============================================
Files 1124 488 -636
Lines 178336 82362 -95974
Branches 1489 0 -1489
=============================================
- Hits 100170 65831 -34339
+ Misses 75645 16531 -59114
+ Partials 2521 0 -2521
```
| [Flag](https://app.codecov.io/gh/apache/beam/pull/40578/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/40578/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/40578/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/40578/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `79.92% <35.00%> (+0.37%)` | :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/40578?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
Re: [PR] Update Trivial Inference for Python 3.15 [beam]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #40578:
URL: https://github.com/apache/beam/pull/40578#issuecomment-6172232013
Assigning reviewers:
R: @damccorm for label python.
Backup reviewer: shunping (if the main reviewer is unresponsive, you can escalate to them by tagging their username)
This pull request likely touches a core component ("core" label). Please review with scrutiny.
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