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

errors for missing required properties #175

Closed
davidszotten opened this issue Jul 13, 2023 · 0 comments · Fixed by #176
Closed

errors for missing required properties #175

davidszotten opened this issue Jul 13, 2023 · 0 comments · Fixed by #176

Comments

@davidszotten
Copy link
Contributor

currently, if a required property is missing, the error message lists _all the required properties. could we consider listing only the missing ones?

>>> fastjsonschema.validate({'required': ['foo', 'bar']}, {'foo': 1})
JsonSchemaValueException: data must contain ['foo', 'bar'] properties

this is particularly useful with a large number of required properties where eg only one may be missing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants