-
Notifications
You must be signed in to change notification settings - Fork 91
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
Trouble with conditionals #37
Comments
I have also tried this:
But the error is very similar:
|
use |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I am having a lot of trouble with using conditionals and I am not sure if it is my schema or a bug.
I have the property
actions
which has other properties who's keys are arbitrarily user defined.The behavior I am trying to invoke for objects in
actions
is:action
, meaning if we dont have it validation should fail.action
is present, then I need one of the following:jump
, then require propertyhow_high
sit
, then require propertywhere
This is the JSON I am trying to validate:
However, this is the result I am getting:
Taking these one at a time:
missing_action
does not have propertyaction
this,then
should not be validating itjump
does not matchsit
,oneOf
should only match index 0sit
does not matchjump
,oneOf
should only match index 1This is very baffling.
The text was updated successfully, but these errors were encountered: