-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add sh:closed to the main SHACL shapes #41
Comments
Where would we use this and what do you mean by the "main" shapes? I'm wondering if we should be concerned about restricting fields, say for a someone using the registry standards and adding their own custom fields on top, but maybe we don't want to support within this repository in that case. Do you see any potential negative outcomes of doing this? |
I think what I had in mind here, is that for each of main components of our data model (credit classes, credit batches and projects) that are specific to a certain credit (C01-04) we could lock down the "shape" so that if a new field is somehow added to the "ops folder" (the on-chain data) then our SHACL CI check will throw an error. that just means that if someone wants to update the on-chain metadata, they would also have to update the SHACL. i.e. suppose i wanted to add a new field to the C01 credit class. i would need to edit these two files:
if i didn't update the SHACL schema, the PR i open would be blocked by the SHACL CI check.
i can't see any negative outcomes here. because what i'm thinking here is like a restriction on the credit classes (and other metadata) where we're sort of already the steward of. and i guess we're not saying we're not open to modifying these. and also if there was somehow a community credit that wanted to add their own standard here, we're not forcing them to use our schema's. ASIDE from the fact that there are benefits of using our schema's (like pretty credit class pages etc) |
Thanks for the explanation. Yea, maybe we should further discuss on our next architecture call or when @blushi is back. Would also be curious to hear thoughts from @clevinson and/or @S4mmyb. The restriction seems to be a positive for data integrity but a potential negative for flexibility and efficiency. |
We should add this snippet to the main SHACL shapes we use for validating classes, batches and projects:
This says that the only properties allowed in the data graph/JSON-LD are the properties defined in the SHACL shape.
By default, SHACL does not check for extra fields in data graphs.
This will keep our data graphs only containing what is needed.
The text was updated successfully, but these errors were encountered: