andygrove opened a new pull request, #4438: URL: https://github.com/apache/datafusion-comet/pull/4438
## Which issue does this PR close? N/A. Autonomous audit pass. ## Rationale for this change Audit of the `any_value` expression against Spark 3.4.3, 3.5.8, and 4.0.1. `AnyValue` is a `RuntimeReplaceableAggregate` whose `replacement` is `First(child, ignoreNulls)`, and the optimizer rule `ReplaceExpressions` rewrites it before physical planning. Comet therefore handles `any_value` transparently through `CometFirst`; no dedicated serde exists. The class is identical across the three Spark versions checked. Coverage in `first_last.sql` is comprehensive for `first`, but no test in the repo exercises the `any_value` name directly. A regression in the analyzer rewrite, in a future `AnyValue.replacement`, or in Comet's plan conversion would silently bypass that coverage. ## What changes are included in this PR? - Audit sub-bullets in `spark_expressions_support.md` for `any_value` across the three Spark versions. - New SQL test file `spark/src/test/resources/sql-tests/expressions/aggregate/any_value.sql` exercising `any_value` directly: basic, with grouping, `isIgnoreNull` literal forms, all-null groups, mixing with other aggregates, and equivalence to `first` on identical inputs. ## How are these changes tested? `./mvnw test -Dsuites="org.apache.comet.CometSqlFileTestSuite any_value" -Dtest=none` passes locally (Spark 3.5 profile, 1 test, 0 failures). Scaffolded by the `audit-comet-expression-autonomous` skill. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
