dongjoon-hyun commented on code in PR #60540:
URL: https://github.com/apache/spark/pull/60540#discussion_r4593477535
##########
core/src/main/scala/org/apache/spark/api/python/PythonRunner.scala:
##########
@@ -1743,7 +1834,7 @@ private[spark] abstract class BasePythonRunner[IN, OUT](
// InterruptedException and ClosedByInterruptException are matched
above; what
// remains here is genuine failure that needs to be propagated to the
// reader through writer.exception + a socket EOF.
- writer.setException(t)
+ writer.setException(t, whileWritingToWorker = failedInSocketWrite)
Review Comment:
**[3] Follow-up for the `open()` failure.**
As discussed in
https://github.com/apache/spark/pull/60540#discussion_r4591856971, `run()`
still goes on after `writer.open(dataOut)` (L1806) recorded a failure in
`_exception`, and the `ClosedChannelException` of the next `flushToSocket` that
has data replaces it here. So the root cause (e.g. from `writeBroadcasts` or
`writeCommand`) is lost. I agree that it can be fixed separately. Could you
file a JIRA for it and link it here so that it is tracked? Returning right
after `open` when `writer.exception` is set looks enough.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]