Hey,
here is my code:
data1 = {
"environ_impact" : 10
}
schema1 = {
"type": "object",
"required": [
"environ_impact",
"bla"
],
"properties": {
"environ_impact": {
"type": "number"
},
"bla": {
"type": "number"
}
}
}
Clearly the property "bla" is missing in the schema, and I want to know that bla is missing.
I am looking for an error message which just returns me "bla", or the path to bla + "bla", if bla would be nested.
Error.validator just returns me the whole list of required properties which isn't that useful imo.
Error.message has this information, so why isnt it returned in its own error message? For me right now stripping this information out of error message seems like the only possible workaround
Thanks for your help!