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

Move core examples/best practices to appendixes #791

Merged
merged 6 commits into from
Sep 14, 2019

Conversation

handrews
Copy link
Contributor

NOTE: The first commit is just a move, the second changes the RFC 2119 terms. They should be examined separately.

These sections are not normative, and moving them to an
appendix reduces the length of the sizable normative
portion of the spec. And also improves flow, I think.

The examples within core tend to rely on understanding more
of the core keywords than have necessarily been introduced,
so they work better after the entire vocabulary has been
introduced.

Vocabulary authorship is not part of the JSON Schema specification,
so this guidance should not use RFC 2119 terms.

@handrews handrews added this to the draft-08 milestone Aug 25, 2019
@handrews handrews requested a review from a team August 25, 2019 05:36
@Relequestual
Copy link
Member

RFC NNNN - Keyword definitions for normative sections of RFC documents... 😉

@handrews
Copy link
Contributor Author

handrews commented Sep 3, 2019

@Relequestual

RFC NNNN - Keyword definitions for normative sections of RFC documents... 😉

I feel like I'm missing something or not getting the joke? Am I supposed to do something with this?

@handrews
Copy link
Contributor Author

handrews commented Sep 5, 2019

The two commits I just added are:

So all of this PR has still been approved, although additional feedback is welcome and it can't be merged until after #780 is merged.

@handrews
Copy link
Contributor Author

handrews commented Sep 8, 2019

Now also includes the commits from #792, which were approved by @Relequestual and @philsturgeon. I'm just trying to tidy up the stacked PRs while we wait for the final reviews.

@Relequestual
Copy link
Member

@Relequestual

RFC NNNN - Keyword definitions for normative sections of RFC documents... 😉

I feel like I'm missing something or not getting the joke? Am I supposed to do something with this?

Sorry, just a joke. Should have included emoji =]

@handrews handrews changed the base branch from base-for-ref to master September 14, 2019 03:25
@handrews handrews changed the base branch from master to base-for-ref September 14, 2019 03:27
handrews and others added 6 commits September 13, 2019 20:30
These sections are not normative (RFC 2119 terms will be
removed in a subsequent commit), and moving them to an
appendix reduces the length of the sizable normative
portion of the spec.  And also improves flow, I think.

The examples within core tend to rely on understanding more
of the core keywords than have necessarily been introduced,
so they work better after the entire vocabulary has been
introduced.
Vocabulary authorship is not part of the JSON Schema specification,
so this guidance should not use RFC 2119 terms.
This is going to be a powerful technique for generative use
cases, which have been observed either requiring references
(as opposed to subschemas) in certain places, or implementing
various sorts of inferencing around references on their own
or in conjunction with other keywords.

For example, one OpenAPI documentation tool assumes that
in an "allOf" of several references, the first is a base
class of some sort. While this is not correct behavior
by either JSON Schema or OpenAPI, it demonstrates a feature
built by making implicit assumptions about certain references.

This section provides a recommendation for making such
behavior explicit, and also guides writers of such tools
to the concept of extension vocabularies and annotations.
This should make clear what use cases are considered valid
and safe, vs when someone is on their own in terms of figuring
that out.
Co-Authored-By: Phil Sturgeon <[email protected]>
@handrews handrews changed the base branch from base-for-ref to master September 14, 2019 03:31
@handrews handrews merged commit a9924a7 into json-schema-org:master Sep 14, 2019
@handrews handrews deleted the examp-best branch April 26, 2020 16:49
@gregsdennis gregsdennis added clarification Items that need to be clarified in the specification and removed Type: Maintenance labels Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clarification Items that need to be clarified in the specification core
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants