Skip to content

Commit 6297d45

Browse files
committed
Pick up delta-rs DF upgrade and fix a couple of tests
1 parent 9259bf1 commit 6297d45

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

Cargo.lock

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ datafusion-functions-nested = { workspace = true }
9696

9797
datafusion-remote-tables = { path = "./datafusion_remote_tables", optional = true }
9898

99-
deltalake = { git = "https://github.com/ion-elgreco/delta-rs", rev = "e363ee6a41f2c0b12a748b8fcbd45faf6f29dc93", features = ["datafusion"] }
99+
deltalake = { git = "https://github.com/splitgraph/delta-rs", branch = "fix-decimal-stat-overflow", features = ["datafusion"] }
100100

101101
futures = "0.3"
102102
hex = ">=0.4.0"

src/context/physical.rs

+7-1
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ use datafusion::{
3737
physical_plan::{ExecutionPlan, SendableRecordBatchStream},
3838
sql::TableReference,
3939
};
40+
use datafusion_common::config::TableParquetOptions;
4041
use datafusion_common::tree_node::{Transformed, TransformedResult, TreeNode};
4142
use datafusion_common::{Column as ColumnExpr, ResolvedTableReference, SchemaReference};
4243
use datafusion_expr::logical_plan::{
@@ -941,7 +942,12 @@ impl SeafowlContext {
941942
let table_path = ListingTableUrl::parse(file_path)?;
942943
let file_format: Arc<dyn FileFormat> = match file_type {
943944
"csv" => Arc::new(CsvFormat::default().with_has_header(has_header)),
944-
"parquet" => Arc::new(ParquetFormat::default()),
945+
"parquet" => {
946+
// TODO: We can remove this once delta-rs supports Utf8View
947+
let mut options = TableParquetOptions::default();
948+
options.global.schema_force_view_types = false;
949+
Arc::new(ParquetFormat::default().with_options(options))
950+
}
945951
_ => {
946952
return Err(Error::Plan(format!(
947953
"File type {file_type:?} not supported!"

src/sync/planner.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -985,7 +985,7 @@ mod tests {
985985
" ProjectionExec: expr=[c1@0 as c1, c2@1 as c2, true as __lower_rel]",
986986
" DeltaScan",
987987
" RepartitionExec: partitioning=RoundRobinBatch",
988-
" ParquetExec: file_groups={0 groups: []}, projection=[c1, c2]",
988+
" ParquetExec: file_groups={1 group: [[]]}, projection=[c1, c2]",
989989
" CoalesceBatchesExec: target_batch_size=8192",
990990
" RepartitionExec: partitioning=Hash",
991991
" UnnestExec",

0 commit comments

Comments
 (0)