Skip to content

refactor: Connect Python assert_series_equal() to Rust back-end #23141

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

Merged

Conversation

Kevin-Patyk
Copy link
Contributor

@coastalwhite

This is the first PR to connect the the new Rust back-end testing functionality to Python. This PR only covers assert_series_equal() since I didn't want the PR to be too large and it was my first time doing something like this. The next PR will cover assert_dataframe_equal().

I didn't want to meddle too much in the existing Python tests since they are robust and well-written, so I only made 2 very minor changes to the tests because of how they were structured. Otherwise, all tests pass without any interference.

Lastly, the now deprecated Python code has still not been removed from the related files. This is because the Python assert_dataframe_equal() functionality in Python still relies on that code, so if I delete it without first connecting it to the Rust back-end, it causes a lot of issues. The code will be removed during the PR for connecting assert_dataframe_equal().

@github-actions github-actions bot added internal An internal refactor or improvement python Related to Python Polars rust Related to Rust Polars labels Jun 10, 2025
@Kevin-Patyk Kevin-Patyk requested a review from orlp as a code owner June 10, 2025 16:07
Copy link

codecov bot commented Jun 10, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 80.61%. Comparing base (911352a) to head (32c42f5).
Report is 7 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #23141      +/-   ##
==========================================
- Coverage   80.85%   80.61%   -0.25%     
==========================================
  Files        1615     1636      +21     
  Lines      217417   219813    +2396     
  Branches     2809     2806       -3     
==========================================
+ Hits       175789   177193    +1404     
- Misses      40964    41955     +991     
- Partials      664      665       +1     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Collaborator

@coastalwhite coastalwhite left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much for this and your other PRs. Polars is not the easiest codebase to get into.

Could you maybe in your next PR remove some of the old Python code that was used here?

@coastalwhite coastalwhite merged commit 97a0433 into pola-rs:main Jun 11, 2025
29 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal An internal refactor or improvement python Related to Python Polars rust Related to Rust Polars
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants