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

Improved error messages for SchemaError #20322

Closed
kszlim opened this issue Dec 16, 2024 · 1 comment
Closed

Improved error messages for SchemaError #20322

kszlim opened this issue Dec 16, 2024 · 1 comment
Labels
enhancement New feature or an improvement of an existing feature

Comments

@kszlim
Copy link
Contributor

kszlim commented Dec 16, 2024

Description

SchemaErrors in polars tends to come out like:

polars.exceptions.SchemaError: type String is incompatible with expected type Float64

or

polars.exceptions.SchemaError: invalid series dtype: expected `FixedSizeList`, got `list[f64]`

It would be very useful if they explained which input expressions were the cause of the failure, and then outline exactly how the underlying schema differs from what is expected and where.

@kszlim kszlim added the enhancement New feature or an improvement of an existing feature label Dec 16, 2024
@ritchie46
Copy link
Member

Merged the proposed improvement. I will close this issue as we are working on better error diagnostics and specific issues are not needed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or an improvement of an existing feature
Projects
None yet
Development

No branches or pull requests

2 participants