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

fix(python): No longer error when schema_overrides contains nonexistent columns #15528

Merged
merged 2 commits into from
Apr 8, 2024

Conversation

stinodego
Copy link
Member

Reverts the change in #15290
Closes #15471

As per the discussion in the linked issue, being able to pass nonexistent columns in schema_overrides is actually pretty useful in certain situations. I had not foreseen this, so I am reverting the check I introduced for this.

@github-actions github-actions bot added fix Bug fix python Related to Python Polars labels Apr 7, 2024
Copy link

codecov bot commented Apr 7, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.15%. Comparing base (49e4244) to head (6b4f2e9).

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #15528      +/-   ##
==========================================
- Coverage   81.16%   81.15%   -0.01%     
==========================================
  Files        1362     1362              
  Lines      175001   174999       -2     
  Branches     2532     2532              
==========================================
- Hits       142037   142026      -11     
- Misses      32481    32491      +10     
+ Partials      483      482       -1     

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

@stinodego stinodego marked this pull request as ready for review April 7, 2024 17:41
@Guillermogsjc
Copy link

@stinodego thank you very much for the quick response, the flexibility, the analysis and the final change

@@ -123,9 +124,16 @@ def test_df_init_from_series_strict() -> None:
assert df["a"].dtype == pl.UInt8


# https://github.com/pola-rs/polars/issues/15471
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# https://github.com/pola-rs/polars/issues/15471

@ritchie46 ritchie46 merged commit 38bd8f2 into main Apr 8, 2024
16 checks passed
@ritchie46 ritchie46 deleted the revert-overrides branch April 8, 2024 07:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix Bug fix python Related to Python Polars
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SchemaError: nonexistent column when created from sequence
3 participants