alamb commented on code in PR #16732: URL: https://github.com/apache/datafusion/pull/16732#discussion_r2197504180
########## datafusion/physical-plan/src/filter.rs: ########## @@ -481,32 +481,29 @@ impl ExecutionPlan for FilterExec { _config: &ConfigOptions, ) -> Result<FilterPushdownPropagation<Arc<dyn ExecutionPlan>>> { if !matches!(phase, FilterPushdownPhase::Pre) { - return Ok(FilterPushdownPropagation::transparent( - child_pushdown_result, - )); + return Ok(FilterPushdownPropagation::all(child_pushdown_result)); } // We absorb any parent filters that were not handled by our children - let mut unhandled_filters = child_pushdown_result - .parent_filters - .iter() - .filter_map(|f| match f { - PredicateSupport::Unsupported(expr) => Some(Arc::clone(expr)), - PredicateSupport::Supported(_) => None, - }) - .collect_vec(); - assert_eq!( - child_pushdown_result.self_filters.len(), - 1, - "FilterExec should only have one child" - ); - let unsupported_self_filters = child_pushdown_result.self_filters[0] + let unsupported_parent_filters = + child_pushdown_result.parent_filters.iter().filter_map(|f| { + matches!(f.all(), PredicateSupportDiscriminant::Unsupported) Review Comment: As a minor readability thing, I would find something like this easier to read: ```suggestion f.all().is_unsupported() ``` Something similar to `is_some()` and `is_none()` for `Option` Maybe I'll try and make a PR to see what that looks like ########## datafusion/physical-plan/src/repartition/mod.rs: ########## @@ -821,9 +821,7 @@ impl ExecutionPlan for RepartitionExec { child_pushdown_result: ChildPushdownResult, _config: &ConfigOptions, ) -> Result<FilterPushdownPropagation<Arc<dyn ExecutionPlan>>> { - Ok(FilterPushdownPropagation::transparent( - child_pushdown_result, - )) + Ok(FilterPushdownPropagation::all(child_pushdown_result)) Review Comment: Maybe `if_all`? -- 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