Skip to content
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

test(rust): Make assumption about column name to index conversion having occurred explicit #14894

Conversation

mickvangelderen
Copy link
Contributor

Alternatively, we could do the conversion again if it has not occurred yet.

The column name to indices conversion happens in multiple places in the code base.

In those places we use only the column names if provided and ignore the column indices (projection) without warning. We could take the union instead, print a warning about ignoring the indices when the names are provided, or do nothing.

Depending on this choice, we may be able to represent the projection with a better data structure and deduplicate the conversion code.

@github-actions github-actions bot added fix Bug fix rust Related to Rust Polars labels Mar 7, 2024
Copy link

codecov bot commented Mar 7, 2024

Codecov Report

Attention: Patch coverage is 0% with 3 lines in your changes are missing coverage. Please review.

Project coverage is 81.01%. Comparing base (3cf4897) to head (335cf05).
Report is 1 commits behind head on main.

❗ Current head 335cf05 differs from pull request most recent head be0ae58. Consider uploading reports for the commit be0ae58 to get more accurate results

Files Patch % Lines
crates/polars-io/src/ipc/ipc_file.rs 0.00% 3 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main   #14894   +/-   ##
=======================================
  Coverage   81.01%   81.01%           
=======================================
  Files        1331     1331           
  Lines      172773   172776    +3     
  Branches     2455     2455           
=======================================
+ Hits       139966   139972    +6     
+ Misses      32339    32337    -2     
+ Partials      468      467    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Co-authored-by: Ritchie Vink <ritchie46@gmail.com>
@mickvangelderen mickvangelderen changed the title fix(rust): Make assumption about column name to index conversion having occurred explicit test(rust): Make assumption about column name to index conversion having occurred explicit Mar 7, 2024
@github-actions github-actions bot added the internal An internal refactor or improvement label Mar 7, 2024
@mickvangelderen mickvangelderen marked this pull request as ready for review March 7, 2024 14:40
@mickvangelderen mickvangelderen removed the fix Bug fix label Mar 7, 2024
@ritchie46 ritchie46 merged commit e1a4179 into pola-rs:main Mar 7, 2024
19 checks passed
@mickvangelderen mickvangelderen deleted the make-column-processing-assumption-explicit-in-ipc-file branch March 7, 2024 18:37
@c-peters c-peters added the accepted Ready for implementation label Mar 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted Ready for implementation internal An internal refactor or improvement rust Related to Rust Polars
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants