Is it possible to detect the oldest compatible draft version? #1048
Replies: 1 comment 1 reply
-
I'm not sure it's the case that the older the version, the more tools support a schema. There are (thankfully) lots of modern JSON Schema tooling which only supports later drafts and not early ones (for good evidence, there are nearly no maintained tools remaining which support draft 3, and very few still support draft 4). But in general (i.e. separate from this library) doing this in general is probably a hard™ problem -- versions change lots of things from one to the next, and being able to tell whether such a thing is relied upon in a schema is going to be difficult. Perhaps doing something like running a schema through alterschema and checking whether the resulting updated schema looks any different gives a right first approximation. (Certainly nothing in this library tries to do anything like this though). |
Beta Was this translation helpful? Give feedback.
-
This would be useful for schemastore.org where some draft may have a version specified which is not the oldest compatible.
If an older one is available it would be replaced.
As the older the draft version the more tools supports it.
Beta Was this translation helpful? Give feedback.
All reactions