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): Error on invalid schema input in DataFrame constructor #14483

Merged
merged 5 commits into from
Feb 14, 2024

Conversation

stinodego
Copy link
Member

@stinodego stinodego commented Feb 14, 2024

Closes #12178

Supersedes #12209

I did some refactoring of the _unpack_schema utility. This also closes the linked issue.

Changes

  • Error when the elements of the schema input cannot be unpacked into two variables (column, dtype).
  • Allow non-tuple elements (list and other sequences are now also allowed, but MyPy will still complain).

@stinodego stinodego changed the title Remove unused param fix(python): Error in invalid schema input Feb 14, 2024
@github-actions github-actions bot added fix Bug fix python Related to Python Polars labels Feb 14, 2024
@stinodego stinodego changed the title fix(python): Error in invalid schema input fix(python): Error on invalid schema input in DataFrame constructor Feb 14, 2024
@stinodego stinodego marked this pull request as ready for review February 14, 2024 13:06
@stinodego stinodego merged commit 11c6f9b into main Feb 14, 2024
15 checks passed
@stinodego stinodego deleted the schema-parsing branch February 14, 2024 19:36
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.

Using 2-lists instead of 2-tuples as schema definition fails silently
1 participant