You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "HyukjinKwon (via GitHub)" <gi...@apache.org> on 2023/07/19 10:25:50 UTC

[GitHub] [spark] HyukjinKwon opened a new pull request, #42072: [SPARK-44481][CONNECT][PYTHON] Make pyspark.sql.is_remote an API

HyukjinKwon opened a new pull request, #42072:
URL: https://github.com/apache/spark/pull/42072

   ### What changes were proposed in this pull request?
   
   ### Why are the changes needed?
   
   For the end users to be able to do if-else, e.g., for dispatching the code path to the legacy mode or connect mode.
   
   ### Does this PR introduce _any_ user-facing change?
   
   Yes, it exposes a method as an API.
   
   ### How was this patch tested?
   
   Manually built and checked the documentation.


-- 
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 diff in pull request #42072: [SPARK-44481][CONNECT][PYTHON] Make pyspark.sql.is_remote an API

Posted by "HyukjinKwon (via GitHub)" <gi...@apache.org>.
HyukjinKwon commented on code in PR #42072:
URL: https://github.com/apache/spark/pull/42072#discussion_r1268791343


##########
python/pyspark/sql/__init__.py:
##########
@@ -72,4 +73,5 @@
     "DataFrameWriter",
     "DataFrameWriterV2",
     "PandasCogroupedOps",
+    "is_remote",

Review Comment:
   I think we should just expose it under `pyspark.sql` because APIs are usually exposed under that namespace. I think you can use it as:
   
   ```python
   is_remote = getattr(pyspark.sql, "is_remote", getattr(pyspark.sql.utils, "is_remote", None))()
   ```



-- 
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 closed pull request #42072: [SPARK-44481][CONNECT][PYTHON] Make pyspark.sql.is_remote an API

Posted by "HyukjinKwon (via GitHub)" <gi...@apache.org>.
HyukjinKwon closed pull request #42072: [SPARK-44481][CONNECT][PYTHON] Make pyspark.sql.is_remote an API
URL: https://github.com/apache/spark/pull/42072


-- 
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 #42072: [SPARK-44481][CONNECT][PYTHON] Make pyspark.sql.is_remote an API

Posted by "HyukjinKwon (via GitHub)" <gi...@apache.org>.
HyukjinKwon commented on PR #42072:
URL: https://github.com/apache/spark/pull/42072#issuecomment-1642913899

   Merged 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] harupy commented on a diff in pull request #42072: [SPARK-44481][CONNECT][PYTHON] Make pyspark.sql.is_remote an API

Posted by "harupy (via GitHub)" <gi...@apache.org>.
harupy commented on code in PR #42072:
URL: https://github.com/apache/spark/pull/42072#discussion_r1267980107


##########
python/pyspark/sql/__init__.py:
##########
@@ -72,4 +73,5 @@
     "DataFrameWriter",
     "DataFrameWriterV2",
     "PandasCogroupedOps",
+    "is_remote",

Review Comment:
   Can we expose this as `pyspark.sql.utils.is_remote`?



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