Skip to content

Commit 1a58987

Browse files
feat!: arrow 57, MSRV 1.85+ (#1424)
## What changes are proposed in this pull request? add `arrow-57` feature flag, remove `arrow-55`. also, since arrow 57 MSRV is 1.85 now, we bump from MSRV 1.84 to 1.85 ### This PR affects the following public APIs `arrow` flag now defaults to arrow 57 instead of arrow 56, MSRV now rustc 1.85 ## How was this change tested? existing
1 parent 8589aa5 commit 1a58987

File tree

13 files changed

+44
-44
lines changed

13 files changed

+44
-44
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,5 +26,5 @@ keywords = ["deltalake", "delta", "datalake"]
2626
license = "Apache-2.0"
2727
repository = "https://github.com/delta-io/delta-kernel-rs"
2828
readme = "README.md"
29-
rust-version = "1.84"
29+
rust-version = "1.85"
3030
version = "0.16.0"

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
# Delta Kernel (rust)   [![build-status]][actions] [![latest-version]][crates.io] [![docs]][docs.rs] [![rustc-version-1.84+]][rustc]
1+
# Delta Kernel (rust)   [![build-status]][actions] [![latest-version]][crates.io] [![docs]][docs.rs] [![rustc-version-1.85+]][rustc]
22

33
[build-status]: https://img.shields.io/github/actions/workflow/status/delta-io/delta-kernel-rs/build.yml?branch=main
44
[actions]: https://github.com/delta-io/delta-kernel-rs/actions/workflows/build.yml?query=branch%3Amain
55
[latest-version]: https://img.shields.io/crates/v/delta_kernel.svg
66
[crates.io]: https://crates.io/crates/delta\_kernel
7-
[rustc-version-1.84+]: https://img.shields.io/badge/rustc-1.84+-lightgray.svg
8-
[rustc]: https://blog.rust-lang.org/2025/01/09/Rust-1.84.0/
7+
[rustc-version-1.85+]: https://img.shields.io/badge/rustc-1.85+-lightgray.svg
8+
[rustc]: https://blog.rust-lang.org/2025/02/20/Rust-1.85.0/
99
[docs]: https://img.shields.io/docsrs/delta_kernel
1010
[docs.rs]: https://docs.rs/delta_kernel/latest/delta_kernel/
1111

@@ -85,8 +85,8 @@ arrow versions as we can.
8585
We allow selecting the version of arrow to use via feature flags. Currently we support the following
8686
flags:
8787

88-
- `arrow-55`: Use arrow version 55
8988
- `arrow-56`: Use arrow version 56
89+
- `arrow-57`: Use arrow version 57
9090
- `arrow`: Use the latest arrow version. Note that this is an _unstable_ flag: we will bump this to
9191
the latest arrow version at every arrow version release. Only removing old arrow versions will
9292
cause a breaking change for kernel. If you require a specific version N of arrow, you should

ffi/src/transaction/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ mod tests {
241241
// writer must be closed to write footer
242242
let res = writer.close().unwrap();
243243

244-
create_file_metadata(file_path, res.num_rows, metadata_schema)
244+
create_file_metadata(file_path, res.file_metadata().num_rows(), metadata_schema)
245245
}
246246

247247
#[tokio::test]

kernel/Cargo.toml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -67,27 +67,27 @@ object_store = { version = "0.12.3", optional = true, features = ["aws", "azure"
6767
# TODO: Remove this once https://github.com/apache/arrow-rs/pull/8244 ships
6868
comfy-table = { version = "~7.1", optional = true }
6969

70-
# arrow 55
71-
[dependencies.arrow_55]
70+
# arrow 56
71+
[dependencies.arrow_56]
7272
package = "arrow"
73-
version = "55"
73+
version = "56"
7474
features = ["chrono-tz", "ffi", "json", "prettyprint"]
7575
optional = true
76-
[dependencies.parquet_55]
76+
[dependencies.parquet_56]
7777
package = "parquet"
78-
version = "55"
78+
version = "56"
7979
features = ["async", "object_store"]
8080
optional = true
8181

82-
# arrow 56
83-
[dependencies.arrow_56]
82+
# arrow 57
83+
[dependencies.arrow_57]
8484
package = "arrow"
85-
version = "56"
85+
version = "57"
8686
features = ["chrono-tz", "ffi", "json", "prettyprint"]
8787
optional = true
88-
[dependencies.parquet_56]
88+
[dependencies.parquet_57]
8989
package = "parquet"
90-
version = "56"
90+
version = "57"
9191
features = ["async", "object_store"]
9292
optional = true
9393

@@ -100,11 +100,11 @@ internal-api = []
100100
integration-test = ["hdfs-native-object-store/integration-test"]
101101

102102
# The default versions for arrow/parquet/object_store
103-
arrow = ["arrow-56"] # latest arrow version
103+
arrow = ["arrow-57"] # latest arrow version
104104
need-arrow = [] # need-arrow is a marker that the feature needs arrow dep
105105

106-
arrow-55 = ["dep:arrow_55", "dep:parquet_55", "object_store", "comfy-table"]
107106
arrow-56 = ["dep:arrow_56", "dep:parquet_56", "object_store", "comfy-table"]
107+
arrow-57 = ["dep:arrow_57", "dep:parquet_57", "object_store", "comfy-table"]
108108
arrow-conversion = ["need-arrow"]
109109
arrow-expression = ["need-arrow"]
110110

kernel/examples/read-table-multi-threaded/Cargo.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@ edition = "2021"
55
publish = false
66

77
[dependencies]
8-
arrow = { version = "56", features = ["prettyprint", "chrono-tz"] }
8+
arrow = { version = "57", features = ["prettyprint", "chrono-tz"] }
99
clap = { version = "4.5", features = ["derive"] }
10+
# common pulls in arrow latest so we have to keep all these in sync here
1011
common = { path = "../common" }
1112
delta_kernel = { path = "../../../kernel", features = [
12-
"arrow-56",
13+
"arrow",
1314
"default-engine-rustls",
1415
"internal-api",
1516
] }

kernel/examples/read-table-single-threaded/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ edition = "2021"
55
publish = false
66

77
[dependencies]
8-
arrow = { version = "56", features = ["prettyprint", "chrono-tz"] }
8+
arrow = { version = "57", features = ["prettyprint", "chrono-tz"] }
99
clap = { version = "4.5", features = ["derive"] }
1010
common = { path = "../common" }
1111
delta_kernel = { path = "../../../kernel", features = [
12-
"arrow-56",
12+
"arrow",
1313
"default-engine-rustls",
1414
"internal-api",
1515
] }

kernel/examples/write-table/Cargo.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@ edition = "2021"
55
publish = false
66

77
[dependencies]
8-
arrow = { version = "56", features = ["prettyprint", "chrono-tz"] }
8+
arrow = { version = "57", features = ["prettyprint", "chrono-tz"] }
99
clap = { version = "4.5", features = ["derive"] }
10+
# NB: common depends on 'arrow' (latest) so have to match here
1011
common = { path = "../common" }
1112
delta_kernel = { path = "../../../kernel", features = [
12-
"arrow-56",
13+
"arrow",
1314
"default-engine-rustls",
1415
"internal-api",
1516
] }

kernel/src/arrow_compat.rs

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
11
//! This module re-exports the different versions of arrow, parquet, and object_store we support.
22
3-
#[cfg(feature = "arrow-56")]
3+
#[cfg(feature = "arrow-57")]
44
mod arrow_compat_shims {
5-
pub use arrow_56 as arrow;
6-
pub use parquet_56 as parquet;
5+
pub use arrow_57 as arrow;
6+
pub use parquet_57 as parquet;
77
}
88

9-
#[cfg(all(feature = "arrow-55", not(feature = "arrow-56")))]
9+
#[cfg(all(feature = "arrow-56", not(feature = "arrow-57")))]
1010
mod arrow_compat_shims {
11-
pub use arrow_55 as arrow;
12-
pub use parquet_55 as parquet;
11+
pub use arrow_56 as arrow;
12+
pub use parquet_56 as parquet;
1313
}
1414

1515
// if nothing is enabled but we need arrow because of some other feature flag, throw compile-time
1616
// error
1717
#[cfg(all(
1818
feature = "need-arrow",
19-
not(feature = "arrow-55"),
20-
not(feature = "arrow-56")
19+
not(feature = "arrow-56"),
20+
not(feature = "arrow-57")
2121
))]
22-
compile_error!("Requested a feature that needs arrow without enabling arrow. Please enable the `arrow-55` or `arrow-56` feature");
22+
compile_error!("Requested a feature that needs arrow without enabling arrow. Please enable the `arrow-56` or `arrow-57` feature");
2323

24-
#[cfg(any(feature = "arrow-55", feature = "arrow-56"))]
24+
#[cfg(any(feature = "arrow-56", feature = "arrow-57"))]
2525
pub use arrow_compat_shims::*;

kernel/src/checkpoint/tests.rs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ use crate::action_reconciliation::{
66
use crate::actions::{Add, Metadata, Protocol, Remove};
77
use crate::arrow::array::{ArrayRef, StructArray};
88
use crate::arrow::datatypes::{DataType, Schema};
9+
use crate::arrow::{
10+
array::{create_array, RecordBatch},
11+
datatypes::Field,
12+
};
913
use crate::checkpoint::create_last_checkpoint_data;
1014
use crate::engine::arrow_data::ArrowEngineData;
1115
use crate::engine::default::{executor::tokio::TokioBackgroundExecutor, DefaultEngine};
@@ -14,11 +18,6 @@ use crate::schema::{DataType as KernelDataType, StructField, StructType};
1418
use crate::utils::test_utils::Action;
1519
use crate::{DeltaResult, FileMeta, LogPath, Snapshot};
1620

17-
use arrow_56::{
18-
array::{create_array, RecordBatch},
19-
datatypes::Field,
20-
};
21-
2221
use object_store::{memory::InMemory, path::Path, ObjectStore};
2322
use serde_json::{from_slice, json, Value};
2423
use test_utils::delta_path_for_version;

kernel/src/engine/ensure_data_types.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ mod tests {
352352
&incorrect_variant_arrow_type(),
353353
true,
354354
),
355-
"Invalid argument error: Incorrect datatype. Expected Struct(metadata Binary, value Binary), got Struct(field_1 Binary, field_2 Binary)",
355+
"Invalid argument error: Incorrect datatype. Expected Struct(\"metadata\": Binary, \"value\": Binary), got Struct(\"field_1\": nullable Binary, \"field_2\": nullable Binary)",
356356
)
357357
}
358358

0 commit comments

Comments
 (0)