You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
but it's impossible to match both types at the same time. We're using https://github.com/opis/json-schema to validate API data responses against API model schema and it reports above issue.
In OAS version 3.0 there's nullable field and it's used properly:
Hello,
I've got an issue in my project (where we're using https://github.com/nelmio/NelmioApiDocBundle with OAS 3.1 version) connected to nullable enums.
Currently for OAS 3.1 version it's rendered to spec as:
but it's impossible to match both types at the same time. We're using https://github.com/opis/json-schema to validate API data responses against API model schema and it reports above issue.
In OAS version 3.0 there's
nullable
field and it's used properly:I think for OAS 3.1 we should wrap such
nullable-allOf
schemas with additionaloneOf
level to be something like:It seems that could be more general issue - not only connected to enums. Also, proposed solution IMO seems to be general as well.
I'll test it shortly and will prepare PR for it.
The text was updated successfully, but these errors were encountered: