-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
fix(rust,python): ensure projections containing only hive columns are projected #11803
Merged
Conversation
This file contains 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
github-actions
bot
added
fix
Bug fix
python
Related to Python Polars
rust
Related to Rust Polars
labels
Oct 17, 2023
Nice, can you do a clippy run and undraft? Then it could make the release. 👀 |
on it - my local clippy is broken atm 😅 so have been relying on the CI |
nameexhaustion
requested review from
ritchie46,
stinodego,
alexander-beedie and
orlp
as code owners
October 17, 2023 13:32
I've taken it out of draft - if the CI tests are ok then it can be merged |
btw, when you say making the release... I noticed the py-polars 0.19.9 commit was already merged at #11791 - so hasn't it already been released? or does it work differently? |
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.
Fixes #11796 (regression introduced by #11690).
This adds back the
num_rows
arg and includes some more detail in the comment above the function, as well as a test case.Also did some refactoring around to calculate the
projection_height
upfront, which ended up causing the test from #11578 to fail. This PR also improves on that fix to make it more robust.I'm not actually certain exactly why it fails, but it's likely that the fix done by #11578 was happened to produce the correct results because row groups prior to the last were always calling
column_idx_to_series
with the total number of rows remaining to read from the current row group as well as all subsequent row groups (*remaining_rows
), which would always be> md.num_rows
. However this PR changes that to callcolumn_idx_to_series
withprojection_height
, which is now always<= md.num_rows()
.