Philip Kahn created SPARK-39142:
-----------------------------------

             Summary: Type overloads in `pandas_udf` 
                 Key: SPARK-39142
                 URL: https://issues.apache.org/jira/browse/SPARK-39142
             Project: Spark
          Issue Type: Bug
          Components: PySpark
    Affects Versions: 3.2.1
            Reporter: Philip Kahn


It seems that the `returnType` in the type overloads for `pandas_udf` never 
specify a generic for PySpark SQL types or explicitly list those types:

 

[https://github.com/apache/spark/blob/f84018a4810867afa84658fec76494aaae6d57fc/python/pyspark/sql/pandas/functions.pyi]

 

This results in static type checkers flagging the type of the decorated 
functions (and their parameters) as incorrect, see 
[https://github.com/microsoft/pylance-release/issues/2789] as an example.

 

For someone familiar with the code base, this should be a very fast patch.



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to