This is an automated email from the ASF dual-hosted git repository.

zjffdu pushed a commit to branch branch-0.9
in repository https://gitbox.apache.org/repos/asf/zeppelin.git


The following commit(s) were added to refs/heads/branch-0.9 by this push:
     new d114b11  [ZEPPELIN-4704]. NPE in SparkSqlInterpreter cause no 
meaningful error message
d114b11 is described below

commit d114b11c89956ac57039ba49406101b58380a45f
Author: Jeff Zhang <zjf...@apache.org>
AuthorDate: Mon Mar 30 17:54:21 2020 +0800

    [ZEPPELIN-4704]. NPE in SparkSqlInterpreter cause no meaningful error 
message
    
    ### What is this PR for?
    
    Trivial PR to fix the NPE in SparkSqlInterpreter.
    
    ### What type of PR is it?
    [Bug Fix]
    
    ### Todos
    * [ ] - Task
    
    ### What is the Jira issue?
    * https://issues.apache.org/jira/browse/ZEPPELIN-4704
    
    ### How should this be tested?
    * CI pass
    
    ### Screenshots (if appropriate)
    
    ### Questions:
    * Does the licenses files need update? No
    * Is there breaking changes for older versions? No
    * Does this needs documentation? No
    
    Author: Jeff Zhang <zjf...@apache.org>
    
    Closes #3706 from zjffdu/ZEPPELIN-4704 and squashes the following commits:
    
    8d68c5f71 [Jeff Zhang] [ZEPPELIN-4704]. NPE in SparkSqlInterpreter cause no 
meaningful error message
    
    (cherry picked from commit fff72d0b2a9d602957000e794c2261b352d55209)
    Signed-off-by: Jeff Zhang <zjf...@apache.org>
---
 .../src/main/java/org/apache/zeppelin/spark/SparkSqlInterpreter.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/spark/interpreter/src/main/java/org/apache/zeppelin/spark/SparkSqlInterpreter.java
 
b/spark/interpreter/src/main/java/org/apache/zeppelin/spark/SparkSqlInterpreter.java
index 96250b5..5b415a2 100644
--- 
a/spark/interpreter/src/main/java/org/apache/zeppelin/spark/SparkSqlInterpreter.java
+++ 
b/spark/interpreter/src/main/java/org/apache/zeppelin/spark/SparkSqlInterpreter.java
@@ -112,7 +112,7 @@ public class SparkSqlInterpreter extends 
AbstractInterpreter {
         builder.append(ExceptionUtils.getStackTrace(e));
       } else {
         logger.error("Invocation target exception", e);
-        String msg = e.getCause().getMessage()
+        String msg = e.getMessage()
                 + "\nset zeppelin.spark.sql.stacktrace = true to see full 
stacktrace";
         builder.append(msg);
       }

Reply via email to