-
Notifications
You must be signed in to change notification settings - Fork 28.5k
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
[SPARK-50909][PYTHON][4.0] Setup faulthandler in PythonPlannerRunners #49635
[SPARK-50909][PYTHON][4.0] Setup faulthandler in PythonPlannerRunners #49635
Conversation
### What changes were proposed in this pull request? Setups `faulthandler` in `PythonPlannerRunner`s. It can be enabled by the same config as UDFs. - SQL conf: `spark.sql.execution.pyspark.udf.faulthandler.enabled` - It fallback to Spark conf: `spark.python.worker.faulthandler.enabled` - `False` by default ### Why are the changes needed? The `faulthandler` is not set up in `PythonPlannerRunner`s. ### Does this PR introduce _any_ user-facing change? When enabled, if Python worker crashes, it may generate thread-dump in the error message on the best-effort basis of Python process. ### How was this patch tested? Added the related tests. ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#49592 from ueshin/issues/SPARK-50909/faulthandler. Authored-by: Takuya Ueshin <[email protected]> Signed-off-by: Takuya Ueshin <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since one of the failures is Python part, could you re-trigger once more, @ueshin ?
Oh, according to the log,
|
@dongjoon-hyun Actually the ml related tests can't pass on the GHA in my repo for some reason, as I also mentioned before. |
Oh, for me, it works fine until now, even in my Today's PR.
I also don't have a special configuration. It's a simple fork like the other contributors. Do you happen to know someone who has the same symptom? |
Trying on master with an empty commit at #49664. I remember @HyukjinKwon said it sometimes doesn't pass in his repo as well. sometimes he said vs. always in my repo, though. |
yeah. it's known. I have seen those test failures ONLY in fork repos.. |
Let's merge this in first. I will monitor the build. |
### What changes were proposed in this pull request? This is a backport of #49592. Setups `faulthandler` in `PythonPlannerRunner`s. It can be enabled by the same config as UDFs. - SQL conf: `spark.sql.execution.pyspark.udf.faulthandler.enabled` - It fallback to Spark conf: `spark.python.worker.faulthandler.enabled` - `False` by default ### Why are the changes needed? The `faulthandler` is not set up in `PythonPlannerRunner`s. ### Does this PR introduce _any_ user-facing change? When enabled, if Python worker crashes, it may generate thread-dump in the error message on the best-effort basis of Python process. ### How was this patch tested? Added the related tests. ### Was this patch authored or co-authored using generative AI tooling? No. Closes #49635 from ueshin/issues/SPARK-50909/4.0/faulthandler. Lead-authored-by: Takuya Ueshin <[email protected]> Co-authored-by: Takuya UESHIN <[email protected]> Signed-off-by: Hyukjin Kwon <[email protected]>
What changes were proposed in this pull request?
This is a backport of #49592.
Setups
faulthandler
inPythonPlannerRunner
s.It can be enabled by the same config as UDFs.
spark.sql.execution.pyspark.udf.faulthandler.enabled
spark.python.worker.faulthandler.enabled
False
by defaultWhy are the changes needed?
The
faulthandler
is not set up inPythonPlannerRunner
s.Does this PR introduce any user-facing change?
When enabled, if Python worker crashes, it may generate thread-dump in the error message on the best-effort basis of Python process.
How was this patch tested?
Added the related tests.
Was this patch authored or co-authored using generative AI tooling?
No.