Github user HyukjinKwon commented on a diff in the pull request:

    https://github.com/apache/spark/pull/18906#discussion_r159349251
  
    --- Diff: python/pyspark/sql/udf.py ---
    @@ -174,3 +178,12 @@ def asNondeterministic(self):
             """
             self._deterministic = False
             return self
    +
    +    def asNonNullable(self):
    +        """
    +        Updates UserDefinedFunction to non-nonullable.
    +
    +        .. versionadded:: 2.4
    +        """
    +        self.nullable = False
    +        return self._wrapped()
    --- End diff --
    
    So, this way then seems always returning the wrapped function now? Can we 
make a wrapper function for `asNondeterministic` returning the wrapped func 
when we assign this function to the wrapped function above (and here 
`UserDefinedFunction` returns `self`)?
    
    I think the wrapped func returns a wrapped func and `UserDefinedFunction` 
returns `UserDefinedFunction` always.
      


---

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

Reply via email to