Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5f4efb1

Browse files
authored
Correctly auto-enable prism for some pipelines (#34921)
* Correctly auto-enable prism for any pipelines * CHANGES
1 parent 046b1b2 commit 5f4efb1

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

CHANGES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@
7676
## New Features / Improvements
7777

7878
* X feature added (Java/Python) ([#X](https://github.com/apache/beam/issues/X)).
79+
* [Python] Prism runner now auto-enabled for some Python pipelines using the direct runner ([#34921](https://github.com/apache/beam/pull/34921)).
7980
* [YAML] WriteToTFRecord and ReadFromTFRecord Beam YAML support
8081
* Python: Added JupyterLab 4.x extension compatibility for enhanced notebook integration ([#34495](https://github.com/apache/beam/pull/34495)).
8182

sdks/python/apache_beam/runners/direct/direct_runner.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,8 @@ def visit_transform(self, applied_ptransform):
167167
pr = runner.run_pipeline(pipeline, options)
168168
# This is non-blocking, so if the state is *already* finished, something
169169
# probably failed on job submission.
170-
if pr.state.is_terminal() and pr.state != PipelineState.DONE:
170+
if (PipelineState.is_terminal(pr.state) and
171+
pr.state != PipelineState.DONE):
171172
_LOGGER.info(
172173
'Pipeline failed on PrismRunner, falling back toDirectRunner.')
173174
runner = BundleBasedDirectRunner()

0 commit comments

Comments
 (0)