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 2022/02/11 06:03:18 UTC

[GitHub] [spark] viirya commented on a change in pull request #35410: [SPARK-38121][PYTHON][SQL] Use SparkSession instead of SQLContext inside PySpark

viirya commented on a change in pull request #35410:
URL: https://github.com/apache/spark/pull/35410#discussion_r804375073



##########
File path: python/pyspark/sql/context.py
##########
@@ -164,17 +158,20 @@ def getOrCreate(cls: Type["SQLContext"], sc: SparkContext) -> "SQLContext":
             "Deprecated in 3.0.0. Use SparkSession.builder.getOrCreate() instead.",
             FutureWarning,
         )
+        return cls._get_or_create(sc)
+
+    @classmethod
+    def _get_or_create(cls: Type["SQLContext"], sc: SparkContext) -> "SQLContext":

Review comment:
       Hmm, the above `getOrCreate` is deprecated for a while, why adding a new `_get_or_create`?




-- 
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