CX-39170: Arrow-rs v57.0.0-cx.0 - #83
Closed
avantgardnerio wants to merge 6 commits into
Closed
Conversation
Adds with_predicate_coop() to ReadPlanBuilder, an async version of with_predicate() that cooperatively yields after decoding 2MB of data, preventing long predicate evaluations from blocking the async runtime. Co-Authored-By: Dan Harris <dan@coralogix.com>
avantgardnerio
force-pushed
the
brent/arrow57
branch
from
April 28, 2026 20:45
4fb474a to
2ce02e9
Compare
…he#8715 v57) Adds RowId support to ParquetRecordBatchReader and the async stream builder. When enabled via with_row_id(), a UInt64 column is prepended to each RecordBatch containing the file-level row offset for each row. Co-Authored-By: Thomas Peiselt <pi@kulturguerilla.org>
avantgardnerio
force-pushed
the
brent/arrow57
branch
from
April 29, 2026 11:28
55e6d13 to
9ef74ed
Compare
## Summary - Fix `MutableArrayData::extend_nulls` which previously panicked unconditionally for both sparse and dense Union arrays - For sparse unions: append the first type_id and extend nulls in all children - For dense unions: append the first type_id, compute offsets into the first child, and extend nulls in that child only ## Background This bug was discovered via DataFusion. `CaseExpr` uses `MutableArrayData` via `scatter()` to build result arrays. When a `CASE` expression returns a Union type (e.g., from `json_get` which returns a JSON union) and there are rows where no `WHEN` branch matches (implicit `ELSE NULL`), `scatter` calls `extend_nulls` which panics with "cannot call extend_nulls on UnionArray as cannot infer type". Any query like: ```sql SELECT CASE WHEN condition THEN returns_union(col, 'key') END FROM table ``` would panic if `condition` is false for any row. ## Root Cause The `extend_nulls` implementation for Union arrays unconditionally panicked because it claimed it "cannot infer type". However, the Union's field definitions (child types and type IDs) are available in the `MutableArrayData`'s data type — there's enough information to produce valid null entries by picking the first declared type_id. ## Test plan - [x] Added test for sparse union `extend_nulls` - [x] Added test for dense union `extend_nulls` - [x] Existing `test_union_dense` continues to pass - [x] All `array_transform` tests pass 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Adrian Garcia Badaracco <1755071+adriangb@users.noreply.github.com> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Co-authored-by: Jeffrey Vo <jeffrey.vo.australia@gmail.com>
avantgardnerio
force-pushed
the
brent/arrow57
branch
4 times, most recently
from
May 5, 2026 20:01
b14a2d1 to
7d5c1c9
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
CX-39170
Description
Rebase Coralogix patches from v56.0.0-cx.0 onto upstream Arrow 57.0.0.
Patches to cherry-pick:
DictionaryArrays inStructArray/ListArrayapache/arrow-rs#7627 - likely upstream already)Checklist