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

[BEAM-6158] Temporarily remove super() calls in Beam examples. #9513

Merged
merged 1 commit into from Sep 10, 2019

Conversation

tvalentyn
Copy link
Contributor

@tvalentyn tvalentyn commented Sep 7, 2019

Several Beam examples define custom transforms and DoFns with customized __init__, that calls superclass constructor.
Due to BEAM-6158 super() in main session calls currently don't pickle on Python 3. In this PR we replace these calls with invocation of parent constructor (DoFn, or PTransform). Strictly speaking, it is not the same as invoking super(), since super delegates the calls to next class parent in __mro__ chain, however this change would make it easier for users to experiment and try Beam examples on Python 3 until BEAM-6158 is addressed, and in simple class hierarchies it results in the same behavior.


Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Choose reviewer(s) and mention them in a comment (R: @username).
  • Format the pull request title like [BEAM-XXX] Fixes bug in ApproximateQuantiles, where you replace BEAM-XXX with the appropriate JIRA issue, if applicable. This will automatically link the pull request to the issue.
  • If this contribution is large, please file an Apache Individual Contributor License Agreement.

Post-Commit Tests Status (on master branch)

Lang SDK Apex Dataflow Flink Gearpump Samza Spark
Go Build Status --- --- Build Status --- --- Build Status
Java Build Status Build Status Build Status Build Status
Build Status
Build Status
Build Status Build Status Build Status
Build Status
Python Build Status
Build Status
Build Status
Build Status
--- Build Status
Build Status
Build Status --- --- Build Status
XLang --- --- --- Build Status --- --- ---

Pre-Commit Tests Status (on master branch)

--- Java Python Go Website
Non-portable Build Status Build Status Build Status Build Status
Portable --- Build Status --- ---

See .test-infra/jenkins/README for trigger phrase, status and link of all Jenkins jobs.

@tvalentyn
Copy link
Contributor Author

Run Portable_Python PreCommit

@tvalentyn tvalentyn changed the title [BEAM-6158] Remove super() calls in Beam examples. [BEAM-6158] Temporarily remove super() calls in Beam examples. Sep 10, 2019
@tvalentyn
Copy link
Contributor Author

Thanks for review, @aaltay . I also verified batch mobile gaming examples on Python 3 with Dataflow runner.

@tvalentyn tvalentyn merged commit 740ddc6 into apache:master Sep 10, 2019
@tvalentyn tvalentyn deleted the dofn_ptransform_super_cleanup branch October 23, 2019 00:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants