hanyuzheng7 commented on code in PR #22922:
URL: https://github.com/apache/flink/pull/22922#discussion_r1252435539
##########
flink-table/flink-table-common/src/main/java/org/apache/flink/table/types/inference/strategies/ArrayComparableElementTypeStrategy.java:
##########
@@ -67,6 +67,9 @@ public ArgumentCount getArgumentCount() {
public Optional<List<DataType>> inferInputTypes(
CallContext callContext, boolean throwOnFailure) {
final List<DataType> argumentDataTypes =
callContext.getArgumentDataTypes();
+ if (argumentDataTypes.size() < 1) {
+ return Optional.empty();
+ }
Review Comment:
@dawidwys Is this OK?
I think we can use
` if (argumentDataTypes.size() < 1) {
return Optional.empty();
}`
first to handle empty input situation, because Calcite's stack inference
logic and the argument count check can work except empty argument input. Once
the bug in the Calcite's stack inference logic and the argument count check
solved, we can remove this if statement.
https://github.com/apache/flink/pull/22922/files#r1252434610
--
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]