alamb commented on code in PR #17491:
URL: https://github.com/apache/datafusion/pull/17491#discussion_r2337733508


##########
datafusion/functions/src/datetime/to_local_time.rs:
##########
@@ -119,6 +119,7 @@ impl ToLocalTimeFunc {
 
         let arg_type = time_value.data_type();
         match arg_type {
+            DataType::Null => Ok(ColumnarValue::Scalar(ScalarValue::Null)),

Review Comment:
   > @alamb what needs to happen for existing tests to catch situations where 
type of data returned from a function doesn't match the promised type?
   
   that is interesting -- maybe we could add some sort of debug only assertion 
to `ScalarUDFImpl::invoke_with_args` that verifies the return 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]

Reply via email to