davidhewitt commented on code in PR #15716: URL: https://github.com/apache/datafusion/pull/15716#discussion_r2067195794
########## datafusion/physical-expr/src/intervals/cp_solver.rs: ########## @@ -645,6 +645,17 @@ impl ExprIntervalGraph { .map(|child| self.graph[*child].interval()) .collect::<Vec<_>>(); let node_interval = self.graph[node].interval(); + // Special case: true OR could in principle be propagated by 3 interval sets, + // (i.e. left true, or right true, or both true) however we do not support this yet. + if node_interval == &Interval::CERTAINLY_TRUE + && self.graph[node] + .expr + .as_any() + .downcast_ref::<BinaryExpr>() + .is_some_and(|expr| expr.op() == &Operator::Or) + { + return not_impl_err!("OR operator cannot yet propagate true intervals"); + } Review Comment: I had to add this to keep the invalid-analysis tests failing. I could move this inside the implementation of `PhysicalExpr` for `BinaryExpr`, however that case currently returns `Ok(Some(vec![]))` and it wasn't clear to me if it was ok to change that case to be failing. -- 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