Repository navigation
Conversation
skip_records looped forever on a page that declares more values than it has repetition levels. read_records already returns an error for such a page; the skip path now returns the same one. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
|
Thanks for fixing this! I hit the same hang, and this PR fixes it for me. One regression: skipping over an empty data page (num_values = 0) in a repeated column now returns an error. With an empty V1 page followed by a valid 10-value page, skip_records(5) returns Ok(5) on main, but "Insufficient repetition levels read from column" with this change. Adding (Found and tested with AI assistance.) |
This branch has not been deployed
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.
Which issue does this PR close?
skip_recordsloops forever when a page has fewer repetition levels than it declares #12495.Rationale for this change
GenericColumnReader::skip_recordsdoes not return when a data page of a repeated column declares more values than it has repetition levels.skip_rep_levelsreturns(0, 0)once the levels run out, and nothing else in the loop advances.read_recordsreturns an error for the same page since #6232.What changes are included in this PR?
skip_recordsreturnsInsufficient repetition levels read from columnwhenskip_rep_levelsreads no record and no level, the same check and message as inread_records.Are these changes tested?
Yes.
test_skip_records_insufficient_rep_levelsreads and skips a page with two repetition levels that declares four values, and expects the same error from both. Without the fix the skip does not return.Are there any significant user-facing changes?
No. A skip that did not terminate now returns an error.
AI usage disclosure
Claude Code found the problem while fuzzing the reader with corrupted files, and generated the fix, the test and this description. The test was run on
mainwith and without the fix.🤖 Generated with Claude Code