File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -233,7 +233,18 @@ fn partitioned_files(
233233 columns,
234234 ..
235235 } = file;
236- partitioned_files[ index] . push ( PartitionedFile :: new ( file_path, file. file_size ) ) ;
236+
237+ // object_store::path::Path doesn't automatically deal with Windows path separators
238+ // to do that, we are using from_absolute_path() which takes into consideration the underlying filesystem
239+ // before sending the file path to PartitionedFile
240+ let pf = if CONFIG . storage_name . eq ( "drive" ) {
241+ let file_path = object_store:: path:: Path :: from_absolute_path ( file_path) . unwrap ( ) ;
242+ PartitionedFile :: new ( file_path, file. file_size )
243+ } else {
244+ PartitionedFile :: new ( file_path, file. file_size )
245+ } ;
246+
247+ partitioned_files[ index] . push ( pf) ;
237248 columns. into_iter ( ) . for_each ( |col| {
238249 column_statistics
239250 . entry ( col. name )
You can’t perform that action at this time.
0 commit comments