python-openapi/openapi-schema-validator

Subclassing JSONSchema validator class with OAS30Validator

p1c2u opened this issue · 1 comments

p1c2u commented

OAS 3.0 is incompatible with JSON Schema because it assumes context-sensitive validation (readOnly and writeOnly for request and response), which JSON Schema doesn't support.

Subclassing jsonschema validator classes is not intended to be part of their public API but it's the only way to add context-sensitive validation support.

p1c2u commented

With new OAS30ReadValidator and OAS30WriteValidator this is no longer the case hence closing.