Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Into arrow with hint #1730

Merged
merged 10 commits into from
Jan 3, 2025
Merged

Into arrow with hint #1730

merged 10 commits into from
Jan 3, 2025

Conversation

joseph-isaacs
Copy link
Member

No description provided.

@joseph-isaacs joseph-isaacs force-pushed the ji/into-arrow-with-hint branch from 603142b to b0de02d Compare December 20, 2024 15:43
@joseph-isaacs joseph-isaacs requested a review from gatesn December 20, 2024 16:18
# Conflicts:
#	vortex-array/src/arrow/record_batch.rs
#	vortex-array/src/canonical.rs
// Note, arrow::cast clones the array, so don't use it if unnecessary.
Ok(match data_type {
DataType::Binary | DataType::LargeBinary | DataType::Utf8 | DataType::LargeUtf8 => {
array_ref
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't make much sense to me. You switch on the requested data type, then you return whatever into_arrow returns without checking the data_type actually matches?

Shouldn't it be more like if array_ref.data_type() != data_type { array_ref = cast(...) }

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agreed

# Conflicts:
#	vortex-array/src/arrow/record_batch.rs
#	vortex-array/src/canonical.rs
@joseph-isaacs joseph-isaacs requested a review from gatesn January 3, 2025 13:18
fn into_arrow(self) -> VortexResult<ArrayRef> {
fn into_arrow(self) -> VortexResult<ArrayRef>
where
Self: Sized,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this need Self: Sized but into_canonical doesn't?

@joseph-isaacs joseph-isaacs enabled auto-merge (squash) January 3, 2025 14:41
@joseph-isaacs joseph-isaacs merged commit 3617e6c into develop Jan 3, 2025
21 checks passed
@joseph-isaacs joseph-isaacs deleted the ji/into-arrow-with-hint branch January 3, 2025 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants