diff --git a/spark/src/main/spark-3.x/org/apache/comet/shims/ShimCometSparkSessionExtensions.scala b/spark/src/main/spark-3.x/org/apache/comet/shims/ShimCometSparkSessionExtensions.scala index 22c567bb4..eb04c68ab 100644 --- a/spark/src/main/spark-3.x/org/apache/comet/shims/ShimCometSparkSessionExtensions.scala +++ b/spark/src/main/spark-3.x/org/apache/comet/shims/ShimCometSparkSessionExtensions.scala @@ -40,6 +40,11 @@ trait ShimCometSparkSessionExtensions { */ def getOffset(limit: LimitExec): Int = getOffsetOpt(limit).getOrElse(0) + /** + * TODO: delete after dropping Spark 3.x support and directly call + * SQLConf.EXTENDED_EXPLAIN_PROVIDERS.key + */ + protected val EXTENDED_EXPLAIN_PROVIDERS_KEY = "spark.sql.extendedExplainProviders" } object ShimCometSparkSessionExtensions { @@ -64,6 +69,4 @@ object ShimCometSparkSessionExtensions { } true } - - protected val EXTENDED_EXPLAIN_PROVIDERS_KEY = "spark.sql.extendedExplainProviders" } diff --git a/spark/src/test/scala/org/apache/spark/sql/CometTestBase.scala b/spark/src/test/scala/org/apache/spark/sql/CometTestBase.scala index 68905ac34..112d35b13 100644 --- a/spark/src/test/scala/org/apache/spark/sql/CometTestBase.scala +++ b/spark/src/test/scala/org/apache/spark/sql/CometTestBase.scala @@ -247,9 +247,7 @@ abstract class CometTestBase expectedInfo: Set[String]): Unit = { var expected: Array[Row] = Array.empty var dfSpark: Dataset[Row] = null - withSQLConf( - CometConf.COMET_ENABLED.key -> "false", - EXTENDED_EXPLAIN_PROVIDERS_KEY -> "") { + withSQLConf(CometConf.COMET_ENABLED.key -> "false", EXTENDED_EXPLAIN_PROVIDERS_KEY -> "") { dfSpark = Dataset.ofRows(spark, df.logicalPlan) expected = dfSpark.collect() }