Skip to content
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 vc-json-schema to vocab and context #1178

Merged
merged 3 commits into from
Jul 11, 2023
Merged

add vc-json-schema to vocab and context #1178

merged 3 commits into from
Jul 11, 2023

Conversation

decentralgabe
Copy link
Contributor

@decentralgabe decentralgabe commented Jun 30, 2023

fix #1134

@@ -92,6 +92,28 @@
}
},

"JsonSchema2023": {
"@id":
"https://www.w3.org/ns/credentials#JsonSchema2023",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@iherman vocab URL or the 2018 one?

@decentralgabe decentralgabe marked this pull request as ready for review June 30, 2023 16:13
Co-authored-by: Ted Thibodeau Jr <tthibodeau@openlinksw.com>
Copy link
Member

@msporny msporny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 to adding CredentialSchema2023 to the base context, though it probably needs a rename to bring it in line with the "we only talk about verifiable credentials" here direction of the WG. I'm a bit concerned about JsonSchema2023 and the potential conflict with PRs like #1182. I don't think there's anything wrong with JsonSchema2023, but others in the WG might take issue with it.

Approving, while noting concerns with future changes.

Comment on lines 8 to 9
JsonSchema2023,rdfs:Class,,,,,,,A type of validator that can be used to syntactically validate JSON documents using the JSON Schema language.
CredentialSchema2023,rdfs:Class,,,,,,,A type of validator that can be used to syntactically validate JSON documents packaged as Verifiable Credentials using the JSON Schema language.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The distinction here doesn't make sense if the base media type is application/vc+ld+json and given the direction of PRs like #1182. I'm just flagging this as a concern as this might need to be changed in the future.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good flag. simply put, the spec operates on portions of a VC which it always treats as JSON, despite the outer wrapper being vc+ld+json. If there's a way I can make this more clear I'm open to suggestions.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My suggestion is to just define ONE type for the schema validator you're defining in the JSON Schema 2023 specification. My suggestion is we just define "JsonSchema2023" in the v2 vocabulary, and any properties used therein, and call it a day.

If it would be helpful, I could just rework the PR to do that, as I'm pretty sure I know what you're trying to accomplish in this PR. I don't want to make those changes to this PR w/o your permission, though. So, let me know if you want me to clean up this PR and I'll be happy to do so.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have no problem with you making these changes

contexts/credentials/v2 Outdated Show resolved Hide resolved
contexts/credentials/v2 Outdated Show resolved Hide resolved
vocab/credentials/vocab.csv Outdated Show resolved Hide resolved
Copy link
Member

@msporny msporny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm still a +1 for this PR, but caught a few things as I was going to merge it down to main. Just need @decentralgabe to confirm that he's ok w/ the modifications and I can take it from there.

Co-authored-by: Manu Sporny <msporny@digitalbazaar.com>
Copy link
Member

@msporny msporny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving noting that one of the schema types might need to be removed in the future: w3c/vc-json-schema#172 (but we have the latitude to do that during CR based on the at risk issue markers).

@msporny msporny merged commit 85724de into main Jul 11, 2023
2 checks passed
@msporny msporny deleted the issue-1134 branch July 11, 2023 01:43
@msporny
Copy link
Member

msporny commented Jul 11, 2023

Normative, multiple reviews, changes requested and made, no objections, merging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Should we bundle contexts for credentialSchema and credentialStatus int he v2 core context?
4 participants