File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
vortex-array/src/arrow/compute/to_arrow Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ use std::sync::LazyLock;
1212use arcref:: ArcRef ;
1313use arrow_array:: ArrayRef as ArrowArrayRef ;
1414use arrow_schema:: DataType ;
15- use vortex_compute:: arrow:: IntoArrow ;
1615use vortex_dtype:: DType ;
1716use vortex_dtype:: arrow:: FromArrowType ;
1817use vortex_error:: VortexError ;
@@ -24,7 +23,7 @@ use vortex_error::vortex_err;
2423use crate :: Array ;
2524use crate :: LEGACY_SESSION ;
2625use crate :: USE_VORTEX_OPERATORS ;
27- use crate :: VectorExecutor ;
26+ use crate :: arrow :: ArrowArrayExecutor ;
2827use crate :: arrow:: array:: ArrowArray ;
2928use crate :: arrow:: array:: ArrowVTable ;
3029use crate :: compute:: ComputeFn ;
@@ -130,10 +129,13 @@ impl ComputeFnVTable for ToArrow {
130129
131130 if !array. is_canonical ( ) {
132131 let arrow_array = if * USE_VORTEX_OPERATORS {
132+ let arrow_type = arrow_type
133+ . cloned ( )
134+ . map ( Ok )
135+ . unwrap_or_else ( || array. dtype ( ) . to_arrow_dtype ( ) ) ?;
133136 array
134137 . to_array ( )
135- . execute_vector ( & LEGACY_SESSION ) ?
136- . into_arrow ( ) ?
138+ . execute_arrow ( & arrow_type, & LEGACY_SESSION ) ?
137139 } else {
138140 // Fall back to canonicalizing and then converting.
139141 let canonical_array = array. to_canonical ( ) ;
You can’t perform that action at this time.
0 commit comments