AngersZhuuuu commented on a change in pull request #33934:
URL: https://github.com/apache/spark/pull/33934#discussion_r704107765
##########
File path: core/src/main/scala/org/apache/spark/deploy/PythonRunner.scala
##########
@@ -92,15 +92,19 @@ object PythonRunner {
// see https://github.com/numpy/numpy/issues/10455
sparkConf.getOption("spark.driver.cores").foreach(env.put("OMP_NUM_THREADS", _))
}
- builder.redirectErrorStream(true) // Ugly but needed for stdout and stderr
to synchronize
try {
val process = builder.start()
+ val stderrBuffer = new CircularBuffer(2048)
+ new RedirectThread(
+ process.getErrorStream,
+ stderrBuffer,
+ "Thread-ScriptTransformation-STDERR-Consumer").start()
new RedirectThread(process.getInputStream, System.out, "redirect
output").start()
Review comment:
> Looks like now it won't show the stderr in stdout anymore?
It's a problem. If we reserve `builder.redirectErrorStream(true)`
We need to split message in inputStream and got error message after
`Traceback` as error message?
--
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]