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

Improve error for invalid kwarg in Struct.__init__ #273

Merged
merged 1 commit into from
Jan 21, 2023

Conversation

jcrist
Copy link
Owner

@jcrist jcrist commented Jan 21, 2023

We now include the name of the first invalid keyword argument, which should make it easier to debug keyword arg typos.

This request came as feedback over email:

when providing an incorrect kwarg, it would be great if the error message could tell you which kwarg was incorrect, e.g. right now its just 'Extra keyword arguments provided'.

We now include the name of the first invalid keyword argument, which
should make it easier to debug keyword arg typos.
@jcrist jcrist merged commit c712614 into main Jan 21, 2023
@jcrist jcrist deleted the better-error-unexpected-kwarg branch January 21, 2023 04:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant