microbiomedata / nmdc-schema

National Microbiome Data Collaborative (NMDC) unified data model
https://microbiomedata.github.io/nmdc-schema/
Creative Commons Zero v1.0 Universal
27 stars 8 forks source link

`Study.slot_usage.protocol_link` should not assert `multivalued: true` #1892

Open turbomam opened 4 months ago

turbomam commented 4 months ago

The global definition for protocol_link doesn't assert multivalued: true but Study.slot_usage.protocol_link does.

I can't figure out who added that slot_usage

That's an example of unacceptable non-monotonicity. slot_usage can refine a slots behavior in a given class, but it shouldn't switch between states that are mutually incompatible.

cc @sierra-moxon @cmungall

turbomam commented 4 months ago

In an un-published branch of berkeley-schema-fy24, linkml-validate of the exhaustive Study example file works, but linkml-convert to YAML doesn't. I think slot_usage problems with protocol_link and study_image are to blame.

turbomam commented 4 months ago

Actually, the linkml-convert problem could be solved by specifying inlined_as_list

But this issue stands as a matter of principle (and unknown problems in other cases)