You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by ru...@apache.org on 2023/08/24 06:56:30 UTC
[spark] branch branch-3.5 updated: [SPARK-43943][FOLLOWUP] Correct a function alias
This is an automated email from the ASF dual-hosted git repository.
ruifengz pushed a commit to branch branch-3.5
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/branch-3.5 by this push:
new af5a24ca116 [SPARK-43943][FOLLOWUP] Correct a function alias
af5a24ca116 is described below
commit af5a24ca116eaa46f58c456ffe71d5f9b02417c7
Author: Ruifeng Zheng <ru...@apache.org>
AuthorDate: Thu Aug 24 14:56:01 2023 +0800
[SPARK-43943][FOLLOWUP] Correct a function alias
### What changes were proposed in this pull request?
Correct a function alias
### Why are the changes needed?
it should be `sign`
### Does this PR introduce _any_ user-facing change?
actually no, since `pyspark.sql.connect.function` shares the same namespace with `pyspark.sql.function`
also manually check (before this PR)
```
Welcome to
____ __
/ __/__ ___ _____/ /__
_\ \/ _ \/ _ `/ __/ '_/
/__ / .__/\_,_/_/ /_/\_\ version 4.0.0.dev0
/_/
Using Python version 3.10.11 (main, May 17 2023 14:30:36)
Client connected to the Spark Connect server at localhost
SparkSession available as 'spark'.
In [1]: from pyspark.sql import functions as sf
In [2]: sf.sign
Out[2]: <function pyspark.sql.functions.signum(col: 'ColumnOrName') -> pyspark.sql.column.Column>
In [3]: sf.sigh
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
Cell In[3], line 1
----> 1 sf.sigh
AttributeError: module 'pyspark.sql.functions' has no attribute 'sigh'
```
### How was this patch tested?
CI
### Was this patch authored or co-authored using generative AI tooling?
NO
Closes #42642 from zhengruifeng/spark_43943_followup.
Authored-by: Ruifeng Zheng <ru...@apache.org>
Signed-off-by: Ruifeng Zheng <ru...@apache.org>
(cherry picked from commit c660eb367c0b1447230025bb9165a1bbc00b6fc3)
Signed-off-by: Ruifeng Zheng <ru...@apache.org>
---
python/pyspark/sql/connect/functions.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/python/pyspark/sql/connect/functions.py b/python/pyspark/sql/connect/functions.py
index 9d01073e5da..0c511d6c07c 100644
--- a/python/pyspark/sql/connect/functions.py
+++ b/python/pyspark/sql/connect/functions.py
@@ -823,7 +823,7 @@ def signum(col: "ColumnOrName") -> Column:
signum.__doc__ = pysparkfuncs.signum.__doc__
-sigh = signum
+sign = signum
def sin(col: "ColumnOrName") -> Column:
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org