yutannihilation commented on PR #275:
URL: https://github.com/apache/sedona-db/pull/275#issuecomment-3505570113

   Okay, I think I figured out. I see two problems.
   
   First, `ScalarUdfTester::invoke()` calls `ScalarUdfTester::return_type()`, 
which doesn't consider scalar arguments. So, we need some hatch to specify the 
return type calculated from the scalar arguments. Fortunately, we have the 
actual scalar arguments in these `invoke_*()` variants, so this is easy to fix, 
but a code looks a bit complicated.
   
   
https://github.com/apache/sedona-db/blob/964c4dd867f72b723417f63e1660462e0015d497/rust/sedona-testing/src/testers.rs#L406
   
   Second, `ScalarUdfTester::assert_scalar_result_equals()` also calls 
`return_type()`. In this case, we don't have clue to infer the result type, so 
probably it needs to be provided from outside.
   
   
https://github.com/apache/sedona-db/blob/964c4dd867f72b723417f63e1660462e0015d497/rust/sedona-testing/src/testers.rs#L187


-- 
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]

Reply via email to