-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
[Task]: Enable to set timeout for Python TestPipeline #29646
Comments
.take-issue |
@Abacn As far as I understand we have to add Timeout for TestPipeline. So I plan to pass this parameter while creation of TestPipeline class by initializing a varible |
.take-issue |
Hello @Abacn, I looked around the Python code to get hints about the Java SDK component. I think someone has ticked the Python SDK component, but I suspect it is not solved. Could you please clarify whether the Python SDK component is actually solved or just a mistake? |
.take-issue |
.take-issue |
hey @Abacn I think we just have to add timeout parameter as someone mentioned before and pass it to wait until finish. But the timeout time should be in seconds or milliseconds? |
What needs to happen?
Currently TestPipeline run indefinitely:
beam/sdks/python/apache_beam/testing/test_pipeline.py
Line 116 in aef2195
In the case the test timeout, it does not print useful information, just a pytest timeout message and the stacktrace where it gets interrupted (e.g. https://github.com/apache/beam/runs/19275621816)
However, DataflowRunner.wait_until_finish() indeed supports duration:
beam/sdks/python/apache_beam/runners/dataflow/dataflow_runner.py
Line 746 in aef2195
and when timeout, it prints the job id so one can find the Dataflow job to investigate:
beam/sdks/python/apache_beam/runners/dataflow/dataflow_runner.py
Lines 769 to 771 in aef2195
We should be able to use this functionality for TestPipeline, for example,
Issue Priority
Priority: 3 (nice-to-have improvement)
Issue Components
The text was updated successfully, but these errors were encountered: