-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Make ArrowReaderOptions::with_virtual_columns error rather than panic on invalid input
#8867
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
Conversation
…ic on invalid input
| /// # } | ||
| /// ``` | ||
| pub fn with_virtual_columns(self, virtual_columns: Vec<FieldRef>) -> Self { | ||
| pub fn with_virtual_columns(self, virtual_columns: Vec<FieldRef>) -> Result<Self> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The point of the PR is to change this API to avoid panic'ing
etseidl
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks @alamb.
scovich
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
vustef
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Which issue does this PR close?
RowNumberReaderwhen not all row groups are selected #8863Rationale for this change
per #8715 (comment), @scovich rightly says
It is much better for a user facing API to return an error on invalid input than painc
What changes are included in this PR?
ArrowReaderOptions::with_virtual_columnserror rather than panic on invalid inputAre these changes tested?
Yes by CI
Are there any user-facing changes?
While this is an API change it was introduced in #8715 which has not yet been released. Therefore, we can make this change without breaking semver.