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

In error JSON, dataPath field prefixed by a full stop (period) #18

Closed
gavin-grypp opened this issue Nov 25, 2019 · 1 comment
Closed

Comments

@gavin-grypp
Copy link
Contributor

gavin-grypp commented Nov 25, 2019

While testing using the sample JSON and schema given at https://json-schema.org/learn/getting-started-step-by-step.html and deliberately changing 'productId' in the JSON from an integer value to a string to get an error returned, I noticed that the value associated with dataPath was prefixed with a full stop (American: period, i.e. a dot):

"dataPath": ".productId"

I believe that this should not be the case.

I presume this have been processed from ajv output, the error message of which starts "data.productId".

@gavin-grypp
Copy link
Contributor Author

Just realised that the issue is present in ajv, so closing this and filing upstream.

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

No branches or pull requests

1 participant