feichai0017 commented on code in PR #20945:
URL: https://github.com/apache/datafusion/pull/20945#discussion_r3310829576


##########
datafusion/sqllogictest/test_files/spark/array/array.slt:
##########
@@ -85,3 +85,43 @@ query ?
 SELECT array(arrow_cast(array(1,2), 'LargeList(Int64)'), array(3));
 ----
 [[1, 2], [3]]
+
+query TT

Review Comment:
   Sry fot this part. Those SLT cases were not exercising the actual bug, so I 
removed that approach.
   
   The coverage now directly targets the real failure mode:
   - a unit test for `get_valid_types(..., Signature::array_and_index(...))`
   - a focused analyzer regression for a parquet-style `List(Field("element", 
...))` input



##########
datafusion/expr/src/type_coercion/functions.rs:
##########
@@ -236,7 +236,7 @@ pub fn data_types(
         get_valid_types(function_name.as_ref(), type_signature, 
current_types)?;
     if valid_types
         .iter()
-        .any(|data_type| data_type == current_types)
+        .any(|data_type| data_types_match(data_type, current_types))

Review Comment:
   Agreed, thanks. I removed the change to the deprecated `data_types(...)` 
path and kept the fix only on the path that is actually used by the analyzer.



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