heyihong commented on code in PR #52342: URL: https://github.com/apache/spark/pull/52342#discussion_r2355262809
########## sql/connect/common/src/main/protobuf/spark/connect/expressions.proto: ########## @@ -207,6 +207,10 @@ message Expression { Time time = 26; } + // The data type information of the literal. + // This field is only required for the root literal message. + DataType data_type = 100; Review Comment: In proto3, fields that are message types are always optional. If the data_type field is not set, we fall back to inferring the data type or using the deprecated data type fields. I will update the comment. In my opinion, it is better to always set the data_type field, because avoiding data type inference simplifies both the protocol and its implementation across different languages. -- 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: reviews-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org