Copilot commented on code in PR #1744: URL: https://github.com/apache/datafusion-comet/pull/1744#discussion_r2093225482
########## spark/src/main/scala/org/apache/spark/sql/comet/CometNativeScanExec.scala: ########## @@ -237,8 +235,9 @@ object CometNativeScanExec extends DataTypeSupport { name: String, fallbackReasons: ListBuffer[String]): Boolean = { dt match { - case ByteType | ShortType if usingDataSourceExecWithIncompatTypes(SQLConf.get) => - fallbackReasons += s"${CometConf.COMET_SCAN_ALLOW_INCOMPATIBLE.key} is false" + case ByteType | ShortType if !CometConf.COMET_SCAN_ALLOW_INCOMPATIBLE.get() => + fallbackReasons += s"${CometConf.SCAN_NATIVE_DATAFUSION} scan cannot read $dt when " + + s"${CometConf.COMET_SCAN_ALLOW_INCOMPATIBLE.key} is false. ${CometConf.COMPAT_GUIDE}." false Review Comment: [nitpick] The configuration check in CometNativeScanExec differs from that in CometScanExec, potentially leading to inconsistent behavior for ByteType and ShortType. Consider aligning these checks for consistency. ```suggestion case ByteType | ShortType => if (!CometConf.COMET_SCAN_ALLOW_INCOMPATIBLE.get()) { fallbackReasons += s"${CometConf.SCAN_NATIVE_DATAFUSION} scan cannot read $dt when " + s"${CometConf.COMET_SCAN_ALLOW_INCOMPATIBLE.key} is false. ${CometConf.COMPAT_GUIDE}." false } else { super.isTypeSupported(dt, name, fallbackReasons) } ``` -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org