jiayuasu commented on code in PR #937:
URL: https://github.com/apache/sedona-db/pull/937#discussion_r3385865185
##########
python/sedonadb/src/udf.rs:
##########
@@ -21,16 +21,20 @@ use arrow_array::{
ffi::{FFI_ArrowArray, FFI_ArrowSchema},
ArrayRef,
};
-use arrow_schema::Field;
+use arrow_schema::{Field, FieldRef};
use datafusion_common::config::ConfigOptions;
use datafusion_common::{Result, ScalarValue};
-use datafusion_expr::{AggregateUDF, ColumnarValue, ScalarUDF, ScalarUDFImpl,
Volatility};
+use datafusion_expr::{
+ Accumulator, AggregateUDF, AggregateUDFImpl, ColumnarValue, ScalarUDF,
ScalarUDFImpl,
+ Volatility,
+};
Review Comment:
False positive — `AggregateUDFImpl` is a trait import needed to bring the
`.name()` method into scope for `SedonaAggregateUDF`/`AggregateUDF` (which has
no inherent `name()`). Confirmed clean locally with CI's exact setting:
`RUSTFLAGS="-Dwarnings" cargo clippy --lib` passes. No change.
##########
python/sedonadb/src/udf.rs:
##########
@@ -21,16 +21,20 @@ use arrow_array::{
ffi::{FFI_ArrowArray, FFI_ArrowSchema},
ArrayRef,
};
-use arrow_schema::Field;
+use arrow_schema::{Field, FieldRef};
use datafusion_common::config::ConfigOptions;
use datafusion_common::{Result, ScalarValue};
-use datafusion_expr::{AggregateUDF, ColumnarValue, ScalarUDF, ScalarUDFImpl,
Volatility};
+use datafusion_expr::{
+ Accumulator, AggregateUDF, AggregateUDFImpl, ColumnarValue, ScalarUDF,
ScalarUDFImpl,
+ Volatility,
+};
Review Comment:
False positive — `AggregateUDFImpl` is a trait import needed to bring the
`.name()` method into scope for `SedonaAggregateUDF`/`AggregateUDF` (which has
no inherent `name()`). Confirmed clean locally with CI's exact setting:
`RUSTFLAGS="-Dwarnings" cargo clippy --lib` passes. No change.
##########
python/sedonadb/src/context.rs:
##########
@@ -17,7 +17,7 @@
use std::{collections::HashMap, sync::Arc};
use arrow_schema::DataType;
-use datafusion_expr::ScalarUDFImpl;
+use datafusion_expr::{AggregateUDFImpl, ScalarUDFImpl};
Review Comment:
False positive — `ScalarUDFImpl`/`AggregateUDFImpl` are trait imports
required to call `.name()` on the UDF structs (no inherent `name()`).
`RUSTFLAGS="-Dwarnings" cargo clippy --lib` passes locally. No change.
##########
python/sedonadb/src/context.rs:
##########
@@ -17,7 +17,7 @@
use std::{collections::HashMap, sync::Arc};
use arrow_schema::DataType;
-use datafusion_expr::ScalarUDFImpl;
+use datafusion_expr::{AggregateUDFImpl, ScalarUDFImpl};
Review Comment:
False positive — `ScalarUDFImpl`/`AggregateUDFImpl` are trait imports
required to call `.name()` on the UDF structs (no inherent `name()`).
`RUSTFLAGS="-Dwarnings" cargo clippy --lib` passes locally. No change.
--
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]