Open jpmckinney opened 3 years ago
To upgrade between draft versions, see https://github.com/ajv-validator/json-schema-migrate
Edit: BODS experience of upgrading: https://github.com/openownership/data-standard/issues/469 https://github.com/openownership/data-standard/pull/485
Discussion
The Draft-04 we're using matches draft-zyp-json-schema-04 / draft-fge-json-schema-validation-00.
http://json-schema.org/draft-06/json-schema-release-notes.html matches draft-wright-json-schema-00, draft-wright-json-schema-01 / draft-wright-json-schema-validation-00, draft-wright-json-schema-validation-01
examples
in the schema, if we wanted to. (It would just be ignored in Draft 04.)http://json-schema.org/draft-07/json-schema-release-notes.html matches draft-handrews-json-schema-00, draft-handrews-json-schema-01 / draft-handrews-json-schema-validation-00, draft-handrews-json-schema-validation-01
"if", "then", "else"
validation, which is quite powerful, allowing conditionally required fields, for exampledate
format, which we don't presently need, but which could be a good addition"$comment"
, if we want to include notes for schema maintainers in the schema itselfhttp://json-schema.org/draft/2019-09/release-notes.html matches draft-handrews-json-schema-02
duration
format, which could serve to replacedurationInDays
deprecated
boolean keyword, which we had implemented ourselves as an objectChangelogs
Proposal
No action. This issue just serves to document relevant changes to JSON Schema. Any further work should consider the effort to update OCDS validators, especially with respect to maintaining clarity in error messages.