Github user HyukjinKwon commented on a diff in the pull request:
https://github.com/apache/spark/pull/18906#discussion_r163238156
--- Diff: python/pyspark/sql/udf.py ---
@@ -180,17 +182,29 @@ def wrapper(*args):
wrapper.deterministic = self.deterministic
wrapper.asNondeterministic = functools.wraps(
self.asNondeterministic)(lambda:
self.asNondeterministic()._wrapped())
+ wrapper.asNonNullable = functools.wraps(
+ self.asNonNullable)(lambda: self.asNonNullable()._wrapped())
+ wrapper.nullable = self.nullable
return wrapper
def asNondeterministic(self):
"""
- Updates UserDefinedFunction to nondeterministic.
+ Updates :class:`UserDefinedFunction` to nondeterministic.
.. versionadded:: 2.3
"""
self.deterministic = False
return self
+ def asNonNullable(self):
+ """
+ Updates :class:`UserDefinedFunction` to non-nullable.
+
+ .. versionadded:: 2.3
--- End diff --
I am sorry @ptkool. I think I thought this wrongly. Let's do this 2.4. I
think it's too late ...
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]