fix: align file_id with DataFusion UInt16 dictionary#4167
Merged
roeap merged 4 commits intodelta-io:mainfrom Feb 5, 2026
Merged
fix: align file_id with DataFusion UInt16 dictionary#4167roeap merged 4 commits intodelta-io:mainfrom
roeap merged 4 commits intodelta-io:mainfrom
Conversation
Centralize synthetic file-id type/value construction as Dictionary<UInt16, Utf8> and use it across next/legacy providers, meta-only scans, and matched-file DML planning. Track file-group chunking required to stay within the UInt16 dictionary keyspace. Signed-off-by: Ethan Urbanski <[email protected]>
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #4167 +/- ##
==========================================
- Coverage 76.36% 76.35% -0.02%
==========================================
Files 165 166 +1
Lines 46274 46286 +12
Branches 46274 46286 +12
==========================================
+ Hits 35337 35341 +4
- Misses 9262 9265 +3
- Partials 1675 1680 +5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
roeap
reviewed
Feb 5, 2026
Collaborator
roeap
left a comment
There was a problem hiding this comment.
just some small comments.
roeap
reviewed
Feb 5, 2026
roeap
reviewed
Feb 5, 2026
Signed-off-by: Ethan Urbanski <[email protected]>
Signed-off-by: Ethan Urbanski <[email protected]>
roeap
approved these changes
Feb 5, 2026
roeap
pushed a commit
to roeap/delta-rs
that referenced
this pull request
Feb 6, 2026
The synthetic `file_id` column type was defined independently allowing silent drift between `Int32` and `UInt16`. This causes type coercion failures in DML paths that build `file_id IN (...)` predicates. **Changes:** Adds `file_id.rs` as single source of truth for the column name, data type, field constructor, and dictionary aligned literal wrapper. All call sites now go through these helpers. Adds a guard to chunk `FileGroup`s so the per-group partition dictionary cannot exceed the `UInt16` keyspace, with two counters (`count_file_groups_planned`, `count_file_group_chunks`) to observe when chunking triggers. `file_id` remains an internal correlation mechanism. This reduces its surface area and makes removal easier once `ParquetAccessPlan` based scan filtering lands. Related: - delta-io#4113 - delta-io#4115 <!--- For example: - closes #106 ---> <!--- Share links to useful documentation ---> --------- Signed-off-by: Ethan Urbanski <[email protected]>
27 tasks
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.
Description
The synthetic
file_idcolumn type was defined independently allowing silent drift betweenInt32andUInt16. This causes type coercion failures in DML paths that buildfile_id IN (...)predicates.Changes:
Adds
file_id.rsas single source of truth for the column name, data type,field constructor, and dictionary aligned literal wrapper. All call sites now go
through these helpers.
Adds a guard to chunk
FileGroups so the per-group partition dictionarycannot exceed the
UInt16keyspace, with two counters(
count_file_groups_planned,count_file_group_chunks) to observe whenchunking triggers.
file_idremains an internal correlation mechanism. This reduces its surfacearea and makes removal easier once
ParquetAccessPlanbased scan filteringlands.
Related Issue(s)
Related:
Documentation