Skip to content

Commit eb3e236

Browse files
authored
Move Arrow dtype conversion into vortex-dtype (#2588)
Also bring datetime extension types in
1 parent 66efa9c commit eb3e236

File tree

47 files changed

+416
-442
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+416
-442
lines changed

Cargo.lock

Lines changed: 3 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ members = [
99
"vortex-btrblocks",
1010
"vortex-buffer",
1111
"vortex-datafusion",
12-
"vortex-datetime-dtype",
1312
"vortex-dtype",
1413
"vortex-error",
1514
"vortex-expr",
@@ -171,7 +170,6 @@ vortex-btrblocks = { version = "0.25.2", path = "./vortex-btrblocks" }
171170
vortex-buffer = { version = "0.25.2", path = "./vortex-buffer" }
172171
vortex-bytebool = { version = "0.25.2", path = "./encodings/bytebool" }
173172
vortex-datafusion = { version = "0.25.2", path = "./vortex-datafusion" }
174-
vortex-datetime-dtype = { version = "0.25.2", path = "./vortex-datetime-dtype" }
175173
vortex-datetime-parts = { version = "0.25.2", path = "./encodings/datetime-parts" }
176174
vortex-dict = { version = "0.25.2", path = "./encodings/dict" }
177175
vortex-dtype = { version = "0.25.2", path = "./vortex-dtype", default-features = false }

bench-vortex/src/bin/notimplemented.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ use vortex::arrays::{
1010
VarBinViewArray,
1111
};
1212
use vortex::buffer::buffer;
13-
use vortex::datetime_dtype::{TIME_ID, TemporalMetadata, TimeUnit};
13+
use vortex::dtype::datetime::{TIME_ID, TemporalMetadata, TimeUnit};
1414
use vortex::dtype::{DType, ExtDType, Nullability, PType};
1515
use vortex::encodings::alp::{ALPArray, Exponents, RDEncoder};
1616
use vortex::encodings::bytebool::ByteBoolArray;

bench-vortex/src/clickbench.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ use futures::{StreamExt, TryStreamExt, stream};
1111
use tokio::fs::{OpenOptions, create_dir_all};
1212
use tracing::info;
1313
use vortex::TryIntoArray;
14-
use vortex::arrow::FromArrowType;
1514
use vortex::dtype::DType;
15+
use vortex::dtype::arrow::FromArrowType;
1616
use vortex::error::{VortexError, vortex_err};
1717
use vortex::file::{DEFAULT_REGISTRY, VORTEX_FILE_EXTENSION, VortexWriteOptions};
1818
use vortex::layout::{LayoutRegistry, LayoutRegistryExt};

bench-vortex/src/parquet_reader.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ use std::path::PathBuf;
44
use arrow_array::RecordBatchReader;
55
use parquet::arrow::arrow_reader::ParquetRecordBatchReaderBuilder;
66
use vortex::TryIntoArray;
7-
use vortex::arrow::FromArrowType;
87
use vortex::dtype::DType;
8+
use vortex::dtype::arrow::FromArrowType;
99
use vortex::error::{VortexError, VortexResult};
1010
use vortex::iter::{ArrayIteratorAdapter, ArrayIteratorExt};
1111
use vortex::stream::ArrayStream;

bench-vortex/src/tpch/mod.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ use object_store::path::Path as ObjectStorePath;
2121
use tokio::fs::OpenOptions;
2222
use url::Url;
2323
use vortex::arrays::ChunkedArray;
24-
use vortex::arrow::{FromArrowArray, FromArrowType};
24+
use vortex::arrow::FromArrowArray;
2525
use vortex::dtype::DType;
2626
use vortex::error::VortexExpect as _;
2727
use vortex::file::{DEFAULT_REGISTRY, VORTEX_FILE_EXTENSION, VortexWriteOptions};
@@ -38,6 +38,7 @@ mod execute;
3838
pub mod schema;
3939

4040
pub use execute::*;
41+
use vortex::dtype::arrow::FromArrowType;
4142
use vortex::error::VortexError;
4243
use vortex::stream::ArrayStreamAdapter;
4344

encodings/datetime-parts/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ getrandom_v02 = { workspace = true }
2121
rkyv = { workspace = true }
2222
vortex-array = { workspace = true }
2323
vortex-buffer = { workspace = true }
24-
vortex-datetime-dtype = { workspace = true }
2524
vortex-dtype = { workspace = true }
2625
vortex-error = { workspace = true }
2726
vortex-mask = { workspace = true }

encodings/datetime-parts/src/canonical.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ use vortex_array::compute::try_cast;
33
use vortex_array::validity::Validity;
44
use vortex_array::{Array, ArrayCanonicalImpl, Canonical, ToCanonical};
55
use vortex_buffer::BufferMut;
6-
use vortex_datetime_dtype::{TemporalMetadata, TimeUnit};
76
use vortex_dtype::Nullability::NonNullable;
7+
use vortex_dtype::datetime::{TemporalMetadata, TimeUnit};
88
use vortex_dtype::{DType, PType};
99
use vortex_error::{VortexExpect as _, VortexResult, vortex_bail};
1010
use vortex_scalar::PrimitiveScalar;
@@ -103,7 +103,7 @@ mod test {
103103
use vortex_array::validity::Validity;
104104
use vortex_array::{Array, ToCanonical};
105105
use vortex_buffer::buffer;
106-
use vortex_datetime_dtype::TimeUnit;
106+
use vortex_dtype::datetime::TimeUnit;
107107

108108
use crate::DateTimePartsArray;
109109
use crate::canonical::decode_to_temporal;

encodings/datetime-parts/src/compress.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ mod tests {
6868
use vortex_array::validity::Validity;
6969
use vortex_array::{Array, ToCanonical};
7070
use vortex_buffer::buffer;
71-
use vortex_datetime_dtype::TimeUnit;
71+
use vortex_dtype::datetime::TimeUnit;
7272

7373
use crate::{TemporalParts, split_temporal};
7474

encodings/datetime-parts/src/compute/cast.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ mod tests {
3232
use vortex_array::validity::Validity;
3333
use vortex_array::{Array, ArrayRef};
3434
use vortex_buffer::buffer;
35-
use vortex_datetime_dtype::TimeUnit;
35+
use vortex_dtype::datetime::TimeUnit;
3636
use vortex_dtype::{DType, Nullability};
3737

3838
use crate::DateTimePartsArray;

0 commit comments

Comments
 (0)