@@ -19,11 +19,12 @@ use std::any::Any;
19
19
use std:: fmt:: { Debug , Formatter } ;
20
20
use std:: sync:: Arc ;
21
21
22
- use datafusion:: arrow:: array:: { ArrayRef , RecordBatch , StringArray , StructArray , UInt64Array } ;
22
+ use datafusion:: arrow:: array:: { ArrayRef , RecordBatch , StringArray , UInt64Array } ;
23
23
use datafusion:: arrow:: datatypes:: {
24
24
DataType , Field , Schema as ArrowSchema , SchemaRef as ArrowSchemaRef ,
25
25
} ;
26
26
use datafusion:: common:: Result as DFResult ;
27
+ use datafusion:: error:: DataFusionError ;
27
28
use datafusion:: execution:: { SendableRecordBatchStream , TaskContext } ;
28
29
use datafusion:: physical_expr:: { EquivalenceProperties , Partitioning } ;
29
30
use datafusion:: physical_plan:: execution_plan:: { Boundedness , EmissionType } ;
@@ -82,6 +83,9 @@ impl IcebergWriteExec {
82
83
( "count" , count_array, false ) ,
83
84
( "data_files" , files_array, false ) ,
84
85
] )
86
+ . map_err ( |e| {
87
+ DataFusionError :: ArrowError ( e, Some ( "Failed to make result batch" . to_string ( ) ) )
88
+ } )
85
89
}
86
90
87
91
fn make_result_schema ( ) -> ArrowSchemaRef {
0 commit comments