james-willis commented on code in PR #3312:
URL: https://github.com/apache/sedona/pull/3312#discussion_r3926865132
##########
spark/common/src/main/scala/org/apache/spark/sql/sedona_sql/expressions/raster/RasterBandEditors.scala:
##########
@@ -22,13 +22,15 @@ import org.apache.sedona.common.raster.RasterBandEditors
import org.apache.spark.sql.catalyst.expressions.Expression
import
org.apache.spark.sql.sedona_sql.expressions.InferrableFunctionConverter._
import org.apache.spark.sql.sedona_sql.expressions.InferrableRasterTypes._
-import org.apache.spark.sql.sedona_sql.expressions.InferredExpression
+import org.apache.spark.sql.sedona_sql.expressions.{InferrableFunction,
InferredExpression}
private[apache] case class RS_SetBandNoDataValue(inputExpressions:
Seq[Expression])
extends InferredExpression(
inferrableFunction4(RasterBandEditors.setBandNoDataValue),
- inferrableFunction3(RasterBandEditors.setBandNoDataValue),
- inferrableFunction2(RasterBandEditors.setBandNoDataValue)) {
+ // A null noDataValue removes the band's no-data value, so let it
through instead of
+ // null-propagating the whole expression.
+ InferrableFunction.allowRightNull3(RasterBandEditors.setBandNoDataValue),
Review Comment:
fixed. preexisting bug that was latent because this whole case was
unreachable before.
--
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]