You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/07/26 18:37:22 UTC

[GitHub] [spark] planga82 opened a new pull request #33525: [SPARK-35320][SQL] Improve error message for unsuported key types in Map type in from_json expression

planga82 opened a new pull request #33525:
URL: https://github.com/apache/spark/pull/33525


   <!--
   Thanks for sending a pull request!  Here are some tips for you:
     1. If this is your first time, please read our contributor guidelines: https://spark.apache.org/contributing.html
     2. Ensure you have added or run the appropriate tests for your PR: https://spark.apache.org/developer-tools.html
     3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][SPARK-XXXX] Your PR title ...'.
     4. Be sure to keep the PR description updated to reflect all changes.
     5. Please write your PR title to summarize what this PR proposes.
     6. If possible, provide a concise example to reproduce the issue for a faster review.
     7. If you want to add a new configuration, please read the guideline first for naming configurations in
        'core/src/main/scala/org/apache/spark/internal/config/ConfigEntry.scala'.
     8. If you want to add or modify an error type or message, please read the guideline first in
        'core/src/main/resources/error/README.md'.
   -->
   
   ### What changes were proposed in this pull request?
   <!--
   Please clarify what changes you are proposing. The purpose of this section is to outline the changes and how this PR fixes the issue. 
   If possible, please consider writing useful notes for better and faster reviews in your PR. See the examples below.
     1. If you refactor some codes with changing classes, showing the class hierarchy will help reviewers.
     2. If you fix some SQL features, you can provide some references of other DBMSes.
     3. If there is design documentation, please add the link.
     4. If there is a discussion in the mailing list, please add the link.
   -->
   Currently, when a map is parsed in a from_json function, only StringType key is supported. If you try to parse other type, it results on a cast exception.
   For example:
   ```scala
   Seq((s"""{"2021-05-05T20:05:08": "sampleValue"}"""))
     .toDF("value")
     .withColumn("value1", from_json(col("value"),  MapType(TimestampType, StringType)))
     .show
   ```
   ```
   Exception in thread "main" java.lang.ClassCastException: class org.apache.spark.unsafe.types.UTF8String cannot be cast to class java.lang.Long (org.apache.spark.unsafe.types.UTF8String is in unnamed module of loader 'app'; java.lang.Long is in module java.base of loader 'bootstrap')
   	at scala.runtime.BoxesRunTime.unboxToLong(BoxesRunTime.java:107)
   	at org.apache.spark.sql.catalyst.expressions.CastBase.$anonfun$castToString$8$adapted(Cast.scala:297)
   	at org.apache.spark.sql.catalyst.expressions.CastBase.buildCast(Cast.scala:285)
   	at org.apache.spark.sql.catalyst.expressions.CastBase.$anonfun$castToString$7(Cast.scala:297)
   ```
   This PR proposes to improve the error message.
   ```
   org.apache.spark.sql.AnalysisException: cannot resolve 'entries' due to data type mismatch: Input schema map<timestamp,string> can only contain StringType as a key type for a MapType.;
   'Project [unresolvedalias(from_json(MapType(TimestampType,StringType,true), value#1, Some(America/Los_Angeles)), Some(org.apache.spark.sql.Column$$Lambda$1496/546936087@10e5bf9c))]
   +- LocalRelation [value#1]
   	at org.apache.spark.sql.catalyst.analysis.package$AnalysisErrorAt.failAnalysis(package.scala:42)
   	at org.apache.spark.sql.catalyst.analysis.CheckAnalysis$$anonfun$$nestedInanonfun$checkAnalysis$1$2.applyOrElse(CheckAnalysis.scala:197)
   	at org.apache.spark.sql.catalyst.analysis.CheckAnalysis$$anonfun$$nestedInanonfun$checkAnalysis$1$2.applyOrElse(CheckAnalysis.scala:182)
   	at org.apache.spark.sql.catalyst.trees.TreeNode.$anonfun$transformUpWithPruning$2(TreeNode.scala:535)
   	at org.apache.spark.sql.catalyst.trees.CurrentOrigin$.withOrigin(TreeNode.scala:82)
   ...
   ```
   In https://github.com/apache/spark/pull/32599 we decide to improve the error message instead of support this.
   
   ### Why are the changes needed?
   <!--
   Please clarify why the changes are needed. For instance,
     1. If you propose a new API, clarify the use case for a new API.
     2. If you fix a bug, you can clarify why it is a bug.
   -->
   Avoid confusion in the interpretation of the error
   
   ### Does this PR introduce _any_ user-facing change?
   <!--
   Note that it means *any* user-facing change including all aspects such as the documentation fix.
   If yes, please clarify the previous behavior and the change this PR proposes - provide the console output, description and/or an example to show the behavior difference if possible.
   If possible, please also clarify if this is a user-facing change compared to the released Spark versions or within the unreleased branches such as master.
   If no, write 'No'.
   -->
   Yes, the error message returned in this case
   
   ### How was this patch tested?
   <!--
   If tests were added, say they were added here. Please make sure to add some test cases that check the changes thoroughly including negative and positive cases if possible.
   If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future.
   If tests were not added, please describe why they were not added and/or why it was difficult to add.
   -->
   Unit testing and manual testing


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887555169


   Can one of the admins verify this patch?


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsuported key types in Map type in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-886962058


   Can one of the admins verify this patch?


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887393961


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/46205/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887393961


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/46205/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] cloud-fan closed pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
cloud-fan closed pull request #33525:
URL: https://github.com/apache/spark/pull/33525


   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887314862


   **[Test build #141691 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/141691/testReport)** for PR 33525 at commit [`b2ed6b9`](https://github.com/apache/spark/commit/b2ed6b9607cb3ba0c907969c9af4cb0efacebbf1).


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] planga82 commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
planga82 commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r677004457



##########
File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/JsonExpressionsSuite.scala
##########
@@ -853,4 +854,32 @@ class JsonExpressionsSuite extends SparkFunSuite with ExpressionEvalHelper with
         checkEvaluation(JsonObjectKeys(Literal(input)), expected)
     }
   }
+
+  def checkMapTypeKeyError(schema: DataType, jsonData: String): Unit = {
+    assert( JsonToStructs(schema, Map.empty, Literal(jsonData)).checkInputDataTypes() match {
+      case TypeCheckFailure(_) => true
+      case _ => false
+    })
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType") {
+    checkMapTypeKeyError(MapType(IntegerType, StringType), """{"1": "test"}""")
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType " +
+    "anidated in a StructType") {
+    checkMapTypeKeyError(StructType(Seq(StructField("test", MapType(IntegerType, StringType)))),
+      """"test": {"1": "test"}""")
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType " +
+    "anidated in a ArrayType") {
+    checkMapTypeKeyError(ArrayType(MapType(IntegerType, StringType)), """[{"1": "test"}]""")
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType " +
+    "anidated in a MapType") {
+    checkMapTypeKeyError(MapType(StringType, MapType(IntegerType, StringType)),
+    """{"key": {"1" : "test"}}""")
+  }

Review comment:
       Yes you are right, I'm going to put it in only one test to simplify it




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] cloud-fan commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r677228668



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/JsonFunctionsSuite.scala
##########
@@ -390,11 +390,15 @@ class JsonFunctionsSuite extends QueryTest with SharedSparkSession {
 
   test("SPARK-24027: from_json of a map with unsupported key type") {
     val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
-
-    checkAnswer(Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)),
-      Row(null))

Review comment:
       do you know why this returns null before instead of a cast exception?




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887555169


   Can one of the admins verify this patch?


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887465676


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/141691/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] planga82 commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
planga82 commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r683045344



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/JsonFunctionsSuite.scala
##########
@@ -390,11 +390,15 @@ class JsonFunctionsSuite extends QueryTest with SharedSparkSession {
 
   test("SPARK-24027: from_json of a map with unsupported key type") {
     val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
-
-    checkAnswer(Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)),
-      Row(null))

Review comment:
       Thanks @HyukjinKwon, you are right, I'm going to rise a new PR to fix this part.




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] cloud-fan commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r677228668



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/JsonFunctionsSuite.scala
##########
@@ -390,11 +390,15 @@ class JsonFunctionsSuite extends QueryTest with SharedSparkSession {
 
   test("SPARK-24027: from_json of a map with unsupported key type") {
     val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
-
-    checkAnswer(Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)),
-      Row(null))

Review comment:
       do you why this returns null before instead of a cast exception?




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887880390


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/46246/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] planga82 commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
planga82 commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r683045344



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/JsonFunctionsSuite.scala
##########
@@ -390,11 +390,15 @@ class JsonFunctionsSuite extends QueryTest with SharedSparkSession {
 
   test("SPARK-24027: from_json of a map with unsupported key type") {
     val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
-
-    checkAnswer(Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)),
-      Row(null))

Review comment:
       Thanks @HyukjinKwon, you are right, I'm going to rise a new PR to fix this part.




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887852187


   **[Test build #141733 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/141733/testReport)** for PR 33525 at commit [`496b869`](https://github.com/apache/spark/commit/496b86989bbeecae24cfb820de2f99f918d0f5ff).


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887901404


   Kubernetes integration test status failure
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/46246/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887342935


   Kubernetes integration test starting
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/46205/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887465676


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/141691/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887960603


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/141733/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] cloud-fan commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
cloud-fan commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887312158


   ok to test


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] planga82 commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsuported key types in Map type in from_json expression

Posted by GitBox <gi...@apache.org>.
planga82 commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-886938097


   CC @viirya @cloud-fan 
   Thanks!


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887901693


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/46246/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] planga82 commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
planga82 commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887094058


   @viirya Thanks for the comments, I have updated the PR.


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-886962058


   Can one of the admins verify this patch?


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] viirya commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
viirya commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r676909418



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/jsonExpressions.scala
##########
@@ -561,7 +561,17 @@ case class JsonToStructs(
 
   override def checkInputDataTypes(): TypeCheckResult = nullableSchema match {
     case _: StructType | _: ArrayType | _: MapType =>
-      super.checkInputDataTypes()
+      val checkMapKeyType = nullableSchema.existsRecursively( dataType => dataType match {
+        case MapType(keyType, _, _) if (keyType != StringType) => true

Review comment:
       nit: `if (keyType != StringType)` => `if keyType != StringType`

##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/jsonExpressions.scala
##########
@@ -561,7 +561,17 @@ case class JsonToStructs(
 
   override def checkInputDataTypes(): TypeCheckResult = nullableSchema match {
     case _: StructType | _: ArrayType | _: MapType =>
-      super.checkInputDataTypes()
+      val checkMapKeyType = nullableSchema.existsRecursively( dataType => dataType match {

Review comment:
       nit: `checkMapKeyType` => `invalidMapType`?

##########
File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/JsonExpressionsSuite.scala
##########
@@ -853,4 +854,32 @@ class JsonExpressionsSuite extends SparkFunSuite with ExpressionEvalHelper with
         checkEvaluation(JsonObjectKeys(Literal(input)), expected)
     }
   }
+
+  def checkMapTypeKeyError(schema: DataType, jsonData: String): Unit = {
+    assert( JsonToStructs(schema, Map.empty, Literal(jsonData)).checkInputDataTypes() match {
+      case TypeCheckFailure(_) => true
+      case _ => false
+    })
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType") {
+    checkMapTypeKeyError(MapType(IntegerType, StringType), """{"1": "test"}""")
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType " +
+    "anidated in a StructType") {
+    checkMapTypeKeyError(StructType(Seq(StructField("test", MapType(IntegerType, StringType)))),
+      """"test": {"1": "test"}""")
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType " +
+    "anidated in a ArrayType") {
+    checkMapTypeKeyError(ArrayType(MapType(IntegerType, StringType)), """[{"1": "test"}]""")
+  }
+
+  test("SPARK-35320: from_json should fail with a key type different of StringType " +
+    "anidated in a MapType") {
+    checkMapTypeKeyError(MapType(StringType, MapType(IntegerType, StringType)),
+    """{"key": {"1" : "test"}}""")
+  }

Review comment:
       Looks like you can have just one test and run through the combination of map types and json string.

##########
File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/JsonExpressionsSuite.scala
##########
@@ -853,4 +854,32 @@ class JsonExpressionsSuite extends SparkFunSuite with ExpressionEvalHelper with
         checkEvaluation(JsonObjectKeys(Literal(input)), expected)
     }
   }
+
+  def checkMapTypeKeyError(schema: DataType, jsonData: String): Unit = {
+    assert( JsonToStructs(schema, Map.empty, Literal(jsonData)).checkInputDataTypes() match {

Review comment:
       `assert( JsonToStructs(...` => `assert(JsonToStructs(...`

##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/jsonExpressions.scala
##########
@@ -561,7 +561,17 @@ case class JsonToStructs(
 
   override def checkInputDataTypes(): TypeCheckResult = nullableSchema match {
     case _: StructType | _: ArrayType | _: MapType =>
-      super.checkInputDataTypes()
+      val checkMapKeyType = nullableSchema.existsRecursively( dataType => dataType match {

Review comment:
       nit: `nullableSchema.existsRecursively( dataType` => `nullableSchema.existsRecursively(dataType`

##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/jsonExpressions.scala
##########
@@ -561,7 +561,17 @@ case class JsonToStructs(
 
   override def checkInputDataTypes(): TypeCheckResult = nullableSchema match {
     case _: StructType | _: ArrayType | _: MapType =>
-      super.checkInputDataTypes()
+      val checkMapKeyType = nullableSchema.existsRecursively( dataType => dataType match {
+        case MapType(keyType, _, _) if (keyType != StringType) => true
+        case _ => false
+      })
+      if(checkMapKeyType) {

Review comment:
       style: `if(checkMapKeyType)` => `if (checkMapKeyType)`




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887367749


   Kubernetes integration test status success
   URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/46205/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] planga82 commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
planga82 commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r677822350



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/JsonFunctionsSuite.scala
##########
@@ -390,11 +390,15 @@ class JsonFunctionsSuite extends QueryTest with SharedSparkSession {
 
   test("SPARK-24027: from_json of a map with unsupported key type") {
     val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
-
-    checkAnswer(Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)),
-      Row(null))

Review comment:
       @cloud-fan 
   The difference is the type of the key
   ```
   scala> val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
   scala> Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)).show
   +-------+
   |entries|
   +-------+
   |   null|
   +-------+
   
   scala> val schema2 = MapType(TimestampType, StringType)
   scala> Seq("""{"2021-05-05T20:05:08": "a"}""").toDS().select(from_json($"value", schema2)).show
   
   java.lang.ClassCastException: org.apache.spark.unsafe.types.UTF8String cannot be cast to java.lang.Long
     at scala.runtime.BoxesRunTime.unboxToLong(BoxesRunTime.java:107)
     at org.apache.spark.sql.catalyst.expressions.CastBase.$anonfun$castToString$8$adapted(Cast.scala:297)
     at org.apache.spark.sql.catalyst.expressions.CastBase.buildCast(Cast.scala:285)
     ...
   ```
   I think the StructType in the key throws the exception in a different point and it's treated in a different way. Now it's homogeneous so an exception is thrown.




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] HyukjinKwon commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
HyukjinKwon commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r682255897



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/JsonFunctionsSuite.scala
##########
@@ -390,11 +390,15 @@ class JsonFunctionsSuite extends QueryTest with SharedSparkSession {
 
   test("SPARK-24027: from_json of a map with unsupported key type") {
     val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
-
-    checkAnswer(Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)),
-      Row(null))

Review comment:
       hm wait. I realised that `null` behaviour is same in `spark.json.read` too. Can we fix it together?




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887901693


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/46246/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887852187


   **[Test build #141733 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/141733/testReport)** for PR 33525 at commit [`496b869`](https://github.com/apache/spark/commit/496b86989bbeecae24cfb820de2f99f918d0f5ff).


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] AmplabJenkins removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887960603


   
   Refer to this link for build results (access rights to CI server needed): 
   https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/141733/
   


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] cloud-fan commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
cloud-fan commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-888056151


   thanks, merging to master!


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] cloud-fan commented on a change in pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
cloud-fan commented on a change in pull request #33525:
URL: https://github.com/apache/spark/pull/33525#discussion_r678019587



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/JsonFunctionsSuite.scala
##########
@@ -390,11 +390,15 @@ class JsonFunctionsSuite extends QueryTest with SharedSparkSession {
 
   test("SPARK-24027: from_json of a map with unsupported key type") {
     val schema = MapType(StructType(StructField("f", IntegerType) :: Nil), StringType)
-
-    checkAnswer(Seq("""{{"f": 1}: "a"}""").toDS().select(from_json($"value", schema)),
-      Row(null))

Review comment:
       Makes sense. Since it's not only improving error message, I'll merge this PR to master only.




-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887959904


   **[Test build #141733 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/141733/testReport)** for PR 33525 at commit [`496b869`](https://github.com/apache/spark/commit/496b86989bbeecae24cfb820de2f99f918d0f5ff).
    * This patch passes all tests.
    * This patch merges cleanly.
    * This patch adds the following public classes _(experimental)_:
     * `public class RetryingBlockTransferor `
     * `public final class Aggregation implements Serializable `
     * `public final class Count implements AggregateFunc `
     * `public final class CountStar implements AggregateFunc `
     * `public final class Max implements AggregateFunc `
     * `public final class Min implements AggregateFunc `
     * `public final class Sum implements AggregateFunc `
     * `case class CoalescedMapperPartitionSpec(`
     * `trait AQEShuffleReadRule extends Rule[SparkPlan] `
     * `case class CoalesceShufflePartitions(session: SparkSession) extends AQEShuffleReadRule `
     * `case class ScanBuilderHolder(`


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] HyukjinKwon commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
HyukjinKwon commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-888739514


   looks good 👍 


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA removed a comment on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887314862


   **[Test build #141691 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/141691/testReport)** for PR 33525 at commit [`b2ed6b9`](https://github.com/apache/spark/commit/b2ed6b9607cb3ba0c907969c9af4cb0efacebbf1).


-- 
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-unsubscribe@spark.apache.org

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



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


[GitHub] [spark] SparkQA commented on pull request #33525: [SPARK-35320][SQL] Improve error message for unsupported key types in MapType in from_json expression

Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #33525:
URL: https://github.com/apache/spark/pull/33525#issuecomment-887443224


   **[Test build #141691 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/141691/testReport)** for PR 33525 at commit [`b2ed6b9`](https://github.com/apache/spark/commit/b2ed6b9607cb3ba0c907969c9af4cb0efacebbf1).
    * This patch **fails Spark unit tests**.
    * This patch merges cleanly.
    * This patch adds no public classes.


-- 
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-unsubscribe@spark.apache.org

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



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