diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f2b84619..ecdce75b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -64,6 +64,9 @@ jobs: components: clippy cache: "true" - run: cargo clippy --workspace --locked --all-targets -- -D warnings + # Ensure the library builds without DataFusion features unified in by + # workspace dev-dependencies or tooling crates. + - run: cargo check --locked -p iceberg-datafusion --lib test: name: Test diff --git a/Cargo.toml b/Cargo.toml index 3bf3e3a5..3b0cf0b7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -34,7 +34,7 @@ version = "0.12.0" [workspace.dependencies] anyhow = "1.0.72" async-trait = "0.1.89" -datafusion = "56.0.0" +datafusion = { version = "56.0.0", default-features = false } datafusion-cli = "56.0.0" iceberg-datafusion = { path = "crates/datafusion" } iceberg-datafusion-test-tools = { path = "crates/test-tools" } diff --git a/crates/datafusion/Cargo.toml b/crates/datafusion/Cargo.toml index 950d9a6a..cbaf140c 100644 --- a/crates/datafusion/Cargo.toml +++ b/crates/datafusion/Cargo.toml @@ -47,6 +47,7 @@ harness = false [dev-dependencies] criterion = "0.8" +datafusion = { workspace = true, features = ["parquet", "sql"] } iceberg-datafusion-test-tools = { workspace = true } insta = "1" parquet = "60" diff --git a/crates/datafusion/src/table_provider/factory.rs b/crates/datafusion/src/table_provider/factory.rs index 0c5b381e..e424a1e0 100644 --- a/crates/datafusion/src/table_provider/factory.rs +++ b/crates/datafusion/src/table_provider/factory.rs @@ -190,7 +190,7 @@ fn check_cmd(cmd: &CreateExternalTable) -> Result<&str> { /// /// # See also /// - [`iceberg::NamespaceIdent`] -/// - [`datafusion::sql::planner::SqlToRel::external_table_to_plan`] +/// - `datafusion::sql::planner::SqlToRel::external_table_to_plan` fn complement_namespace_if_necessary( table_name: &TableReference, ) -> Cow<'_, TableReference> { diff --git a/crates/test-tools/Cargo.toml b/crates/test-tools/Cargo.toml index 5d6d41e5..564c2b02 100644 --- a/crates/test-tools/Cargo.toml +++ b/crates/test-tools/Cargo.toml @@ -28,9 +28,9 @@ version = { workspace = true } [dependencies] async-trait = { workspace = true } bytes = "1" -# Only for its Arrow and Parquet re-exports, which keep this crate on the -# versions the rest of the workspace resolves to. -datafusion = { workspace = true } +# For its Arrow and Parquet re-exports, which keep this crate on the versions the +# rest of the workspace resolves to, and for `SessionContext::sql` in the harness. +datafusion = { workspace = true, features = ["parquet", "sql"] } futures = "0.3" iceberg = { workspace = true } rand = { version = "0.10", default-features = false, features = ["alloc"] }