summaryzb commented on code in PR #50573:
URL: https://github.com/apache/spark/pull/50573#discussion_r2048184406


##########
core/src/main/scala/org/apache/spark/serializer/SerializationDebugger.scala:
##########
@@ -112,11 +112,11 @@ private[spark] object SerializationDebugger extends 
Logging {
             val elem = s"externalizable object (class ${e.getClass.getName}, 
$e)"
             visitExternalizable(e, elem :: stack)
 
-          case s: Object with java.io.Serializable if Utils.isTesting =>
+          case s: Object with java.io.Serializable =>
             val str = try {
               s.toString
             } catch {
-              case _: SparkRuntimeException => "exception in toString"
+              case _: SparkRuntimeException if Utils.isTesting => "exception 
in toString"

Review Comment:
   @mridulm Appreciate your time to review
   1.NPE have been checked in line#94
   2.[SPARK-51691](https://github.com/apache/spark/pull/50489) and this follow 
main resolve the problem, that toString implementation of TreeNode may throw 
exception since SQLConf.get check during unit test.
   
   Actually non testing case will not encounter similar problem



-- 
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: reviews-unsubscr...@spark.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to