From ed30ad93f680ced3e878cb6fce01cd5ed4622189 Mon Sep 17 00:00:00 2001 From: lancedb automation Date: Fri, 12 Dec 2025 06:32:28 +0000 Subject: [PATCH] chore: update lance dependency to v2.0.0-beta.2 --- Cargo.lock | 75 +++++++++++++------------- Cargo.toml | 28 +++++----- python/src/connection.rs | 18 +++---- rust/lancedb/src/database/namespace.rs | 2 + rust/lancedb/src/table.rs | 30 ++++++++--- 5 files changed, 88 insertions(+), 65 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 576d2692..a254ff8c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3086,8 +3086,8 @@ checksum = "42703706b716c37f96a77aea830392ad231f44c9e9a67872fa5548707e11b11c" [[package]] name = "fsst" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow-array", "rand 0.9.2", @@ -4422,8 +4422,8 @@ dependencies = [ [[package]] name = "lance" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "arrow-arith", @@ -4488,13 +4488,14 @@ dependencies = [ [[package]] name = "lance-arrow" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow-array", "arrow-buffer", "arrow-cast", "arrow-data", + "arrow-ord", "arrow-schema", "arrow-select", "bytes", @@ -4507,8 +4508,8 @@ dependencies = [ [[package]] name = "lance-bitpacking" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrayref", "paste", @@ -4517,8 +4518,8 @@ dependencies = [ [[package]] name = "lance-core" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow-array", "arrow-buffer", @@ -4531,6 +4532,7 @@ dependencies = [ "datafusion-sql", "deepsize", "futures", + "itertools 0.13.0", "lance-arrow", "libc", "log", @@ -4554,8 +4556,8 @@ dependencies = [ [[package]] name = "lance-datafusion" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "arrow-array", @@ -4585,8 +4587,8 @@ dependencies = [ [[package]] name = "lance-datagen" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "arrow-array", @@ -4603,8 +4605,8 @@ dependencies = [ [[package]] name = "lance-encoding" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow-arith", "arrow-array", @@ -4641,8 +4643,8 @@ dependencies = [ [[package]] name = "lance-file" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow-arith", "arrow-array", @@ -4674,8 +4676,8 @@ dependencies = [ [[package]] name = "lance-geo" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "datafusion", "geo-types", @@ -4686,8 +4688,8 @@ dependencies = [ [[package]] name = "lance-index" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "arrow-arith", @@ -4733,6 +4735,7 @@ dependencies = [ "prost-types", "rand 0.9.2", "rand_distr 0.5.1", + "rangemap", "rayon", "roaring", "serde", @@ -4748,8 +4751,8 @@ dependencies = [ [[package]] name = "lance-io" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "arrow-arith", @@ -4789,8 +4792,8 @@ dependencies = [ [[package]] name = "lance-linalg" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow-array", "arrow-buffer", @@ -4806,8 +4809,8 @@ dependencies = [ [[package]] name = "lance-namespace" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "async-trait", @@ -4819,8 +4822,8 @@ dependencies = [ [[package]] name = "lance-namespace-impls" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "arrow-ipc", @@ -4845,9 +4848,9 @@ dependencies = [ [[package]] name = "lance-namespace-reqwest-client" -version = "0.0.18" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ea349999bcda4eea53fc05d334b3775ec314761e6a706555c777d7a29b18d19" +checksum = "b748e89a3a0e5d9fb1b51e4382f783f8aa6b620d755012d4856180968014e619" dependencies = [ "reqwest", "serde", @@ -4858,8 +4861,8 @@ dependencies = [ [[package]] name = "lance-table" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow", "arrow-array", @@ -4898,8 +4901,8 @@ dependencies = [ [[package]] name = "lance-testing" -version = "1.1.0-beta.1" -source = "git+https://github.com/lance-format/lance.git?tag=v1.1.0-beta.1#ddea38f049e64df8b893e1c8ecca7878ea373d1e" +version = "2.0.0-beta.2" +source = "git+https://github.com/lance-format/lance.git?tag=v2.0.0-beta.2#92aa361099f42a40e9aa9f9915d041fe1dd30671" dependencies = [ "arrow-array", "arrow-schema", diff --git a/Cargo.toml b/Cargo.toml index b3778574..8b85ced8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -15,20 +15,20 @@ categories = ["database-implementations"] rust-version = "1.78.0" [workspace.dependencies] -lance = { "version" = "=1.1.0-beta.1", default-features = false, "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-core = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-datagen = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-file = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-io = { "version" = "=1.1.0-beta.1", default-features = false, "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-index = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-linalg = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-namespace = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-namespace-impls = { "version" = "=1.1.0-beta.1", default-features = false, "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-table = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-testing = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-datafusion = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-encoding = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } -lance-arrow = { "version" = "=1.1.0-beta.1", "tag" = "v1.1.0-beta.1", "git" = "https://github.com/lance-format/lance.git" } +lance = { "version" = "=2.0.0-beta.2", default-features = false, "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-core = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-datagen = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-file = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-io = { "version" = "=2.0.0-beta.2", default-features = false, "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-index = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-linalg = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-namespace = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-namespace-impls = { "version" = "=2.0.0-beta.2", default-features = false, "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-table = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-testing = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-datafusion = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-encoding = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } +lance-arrow = { "version" = "=2.0.0-beta.2", "tag" = "v2.0.0-beta.2", "git" = "https://github.com/lance-format/lance.git" } ahash = "0.8" # Note that this one does not include pyarrow arrow = { version = "56.2", optional = false } diff --git a/python/src/connection.rs b/python/src/connection.rs index 92b77f55..52196a1f 100644 --- a/python/src/connection.rs +++ b/python/src/connection.rs @@ -325,11 +325,11 @@ impl Connection { let inner = self_.get_inner()?.clone(); let py = self_.py(); future_into_py(py, async move { - use lance_namespace::models::{create_namespace_request, CreateNamespaceRequest}; + use lance_namespace::models::CreateNamespaceRequest; let mode_enum = mode.and_then(|m| match m.to_lowercase().as_str() { - "create" => Some(create_namespace_request::Mode::Create), - "exist_ok" => Some(create_namespace_request::Mode::ExistOk), - "overwrite" => Some(create_namespace_request::Mode::Overwrite), + "create" => Some("Create".to_string()), + "exist_ok" => Some("ExistOk".to_string()), + "overwrite" => Some("Overwrite".to_string()), _ => None, }); let request = CreateNamespaceRequest { @@ -360,15 +360,15 @@ impl Connection { let inner = self_.get_inner()?.clone(); let py = self_.py(); future_into_py(py, async move { - use lance_namespace::models::{drop_namespace_request, DropNamespaceRequest}; + use lance_namespace::models::DropNamespaceRequest; let mode_enum = mode.and_then(|m| match m.to_uppercase().as_str() { - "SKIP" => Some(drop_namespace_request::Mode::Skip), - "FAIL" => Some(drop_namespace_request::Mode::Fail), + "SKIP" => Some("Skip".to_string()), + "FAIL" => Some("Fail".to_string()), _ => None, }); let behavior_enum = behavior.and_then(|b| match b.to_uppercase().as_str() { - "RESTRICT" => Some(drop_namespace_request::Behavior::Restrict), - "CASCADE" => Some(drop_namespace_request::Behavior::Cascade), + "RESTRICT" => Some("Restrict".to_string()), + "CASCADE" => Some("Cascade".to_string()), _ => None, }); let request = DropNamespaceRequest { diff --git a/rust/lancedb/src/database/namespace.rs b/rust/lancedb/src/database/namespace.rs index 176dc4bb..c4ffb23f 100644 --- a/rust/lancedb/src/database/namespace.rs +++ b/rust/lancedb/src/database/namespace.rs @@ -208,6 +208,7 @@ impl Database for LanceNamespaceDatabase { let describe_request = DescribeTableRequest { id: Some(table_id.clone()), version: None, + with_table_uri: Some(true), }; let describe_result = self.namespace.describe_table(describe_request).await; @@ -334,6 +335,7 @@ impl Database for LanceNamespaceDatabase { let describe_request = DescribeTableRequest { id: Some(table_id.clone()), version: None, + with_table_uri: Some(true), }; let response = self .namespace diff --git a/rust/lancedb/src/table.rs b/rust/lancedb/src/table.rs index 14e04714..a397bfd6 100644 --- a/rust/lancedb/src/table.rs +++ b/rust/lancedb/src/table.rs @@ -41,8 +41,8 @@ use lance_index::vector::sq::builder::SQBuildParams; use lance_index::DatasetIndexExt; use lance_index::IndexType; use lance_namespace::models::{ - QueryTableRequest as NsQueryTableRequest, QueryTableRequestFullTextQuery, - QueryTableRequestVector, StringFtsQuery, + QueryTableRequest as NsQueryTableRequest, QueryTableRequestColumns, + QueryTableRequestFullTextQuery, QueryTableRequestVector, StringFtsQuery, }; use lance_namespace::LanceNamespace; use lance_table::format::Manifest; @@ -2152,7 +2152,10 @@ impl NativeTable { // Convert select to columns list let columns = match &vq.base.select { Select::All => None, - Select::Columns(cols) => Some(cols.clone()), + Select::Columns(cols) => Some(Box::new(QueryTableRequestColumns { + column_names: Some(cols.clone()), + column_aliases: None, + })), Select::Dynamic(_) => { return Err(Error::NotSupported { message: @@ -2225,7 +2228,10 @@ impl NativeTable { let columns = match &q.select { Select::All => None, - Select::Columns(cols) => Some(cols.clone()), + Select::Columns(cols) => Some(Box::new(QueryTableRequestColumns { + column_names: Some(cols.clone()), + column_aliases: None, + })), Select::Dynamic(_) => { return Err(Error::NotSupported { message: "Dynamic columns are not supported for server-side query" @@ -4950,7 +4956,13 @@ mod tests { assert_eq!(ns_request.k, 10); assert_eq!(ns_request.offset, Some(5)); assert_eq!(ns_request.filter, Some("id > 0".to_string())); - assert_eq!(ns_request.columns, Some(vec!["id".to_string()])); + assert_eq!( + ns_request.columns, + Some(Box::new(QueryTableRequestColumns { + column_names: Some(vec!["id".to_string()]), + column_aliases: None, + })) + ); assert_eq!(ns_request.vector_column, Some("vector".to_string())); assert_eq!(ns_request.distance_type, Some("l2".to_string())); assert!(ns_request.vector.single_vector.is_some()); @@ -4991,7 +5003,13 @@ mod tests { assert_eq!(ns_request.k, 20); assert_eq!(ns_request.offset, Some(5)); assert_eq!(ns_request.filter, Some("id > 5".to_string())); - assert_eq!(ns_request.columns, Some(vec!["id".to_string()])); + assert_eq!( + ns_request.columns, + Some(Box::new(QueryTableRequestColumns { + column_names: Some(vec!["id".to_string()]), + column_aliases: None, + })) + ); assert_eq!(ns_request.with_row_id, Some(true)); assert_eq!(ns_request.bypass_vector_index, Some(true)); assert!(ns_request.vector_column.is_none()); // No vector column for plain queries