itholic commented on code in PR #40722:
URL: https://github.com/apache/spark/pull/40722#discussion_r1168282551
##########
python/pyspark/pandas/numpy_compat.py:
##########
@@ -223,11 +223,16 @@ def maybe_dispatch_ufunc_to_spark_func(
op_name
)
+ if is_remote():
+ from pyspark.sql.connect.column import Column as ConnectColumn
+
+ Column = ConnectColumn
+ else:
+ Column = PySparkColumn # type: ignore[assignment]
+
@no_type_check
def convert_arguments(*args):
- args = [
- F.lit(inp) if not isinstance(inp, (Column, ConnectColumn))
else inp for inp in args
- ]
+ args = [F.lit(inp) if not isinstance(inp, Column) else inp for inp
in args]
Review Comment:
Yes, we can
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]