HyukjinKwon commented on code in PR #39974:
URL: https://github.com/apache/spark/pull/39974#discussion_r1103910747
##########
python/pyspark/sql/pandas/functions.pyi:
##########
@@ -46,13 +46,21 @@ class PandasUDFType:
GROUPED_MAP: PandasGroupedMapUDFType
GROUPED_AGG: PandasGroupedAggUDFType
+@overload
+def pandas_udf(
+ f: PandasScalarToScalarFunction, returnType: Union[AtomicDataTypeOrString,
ArrayType]
+) -> UserDefinedFunctionLike: ...
@overload
def pandas_udf(
f: PandasScalarToScalarFunction,
returnType: Union[AtomicDataTypeOrString, ArrayType],
functionType: PandasScalarUDFType,
) -> UserDefinedFunctionLike: ...
@overload
+def pandas_udf(
+ f: Union[AtomicDataTypeOrString, ArrayType]
Review Comment:
While we're here, let's just add all data type instead of only Atomic type.
--
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]