linkml / linkml

Linked Open Data Modeling Language
https://linkml.io/linkml
Other
311 stars 97 forks source link

support stable id resolution of deprecated elements as well as validation without deprecated elements #1850

Open sierra-moxon opened 7 months ago

sierra-moxon commented 7 months ago

By deprecating, rather than deleting, schema elements, we ensure backward compatibility, extend user trust, and provide a valuable historical record, aiding in understanding the model's evolution.

But we also want to be able to use standard LinkML toolchains to validate, generate serializations, etc. without the deprecated elements (except in cases where we want to preserve deprecated elements for use by stable identifiers).

If we were to take the general approach of creating a 'deprecation.yaml' that sits in the schema directory and holds all the deprecated elements of a schema, it would be easy to import that into the main schema file (and use standard toolchains for making serializations that include the deprecated elements -- e.g. in docgen where we produce IRIs). But, at some point, we won't want data generated using deprecated elements to validate, nor will we want to produce JSONSchema or SQL with deprecated elements.

A couple of options (looking for feedback):

• Medium - can do work without it; but it's important (e.g. to save time or for convenience) • Short-term - 2-4 weeks

sierra-moxon commented 7 months ago