Skip to content

Move applicability keywords from Validation to Core #572

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

Merged
merged 8 commits into from
Apr 4, 2018

Conversation

handrews
Copy link
Contributor

@handrews handrews commented Mar 23, 2018

This primarily addresses #513, although a fair amount of groundwork was needed for the moved keywords to make sense. The move itself is pretty trivial. The commits are organized to make this feasible to review.

  • First commit: Reworks most of the front matter about assertions and annotations, and updates wording elsewhere in the specs to match. See the commit message for details. Some text about applicators drops out and is restored in a later commit.
  • Second commit: Changes the discussion of schema types and values to fit better now that more of the context is in Core.
  • Third commit: Promotes vocabularies to a top-level section, and moves a lot of the text from the overview to interoperability concerns, which already discussed schema extensions. This makes things flow a lot better and consolidates the extension discussion
  • Fourth commit: Cut-paste from validation to core, no significant text changes
  • Fifth commit: Update text that was moved in the fourth commit
  • Sixth commit: Change log and "moved keywords" appendix update

This reworks both Overview sections in preparation for
moving the applicators to Core.

The Core overview now covers the generic capabilities
(assertion, annotation, and vocabularies), leaving
the Validation overview to simply reference the concepts.

Rather than noting the standard vocabularies in the
top-level Core overview, they are moved in with the
overview of vocabularies.

Validation and basic meta-data are listed as separate
vocabularies, which is consistent with how they have
been described to date.  Exactly how "format" and
the "content*" keywords are classified into vocabularies
will be finalized in future commits.

The applicators are mentioned as a separate vocabulary in
the core spec, although they are not moved over yet in
this commit.  The descriptive text about applicators which
is removed from the Validation overview in this commit will
be restored to the Core spec when the vocabulary is moved.

There is some duplications as well as the above-mentioned
ommission as a result of this change, which will be addressed
in subsequent commits.
This adds applicators to the list of keyword types,
splits the boolean schemas into their own section,
and promotes the "MUST be an object or a boolean" paragraph
to the containing section's introduction.
A bit of it moves into the vocabulary section of the Overview,
while the rest moves into "Extending JSON Schema" which already
covered individual keyword extensions.

There will befurther work in this area before the next publication
as we formalize the vocabulary concept.
This just moves text, with the bare minimum title, link target,
and indentation changes necessary to make it fit in the core spec.

The Applicability overview section becomes the intro to the
applicability vocabulary, which is followed by the keywords.

Further commits will rework the wording for the new arrangement
and probably further re-organize the applicability overview.

Note that "dependencies" is left in the validation spec, as
splitting it is more complex and will be done entirely
separately after the basic applicability move is complete.
The prior commits just moved this text over, this commit
updates the text to make sense for the new location and
structure.

In particular, this removes the focus on validation as the
applicator vocabulary is more fundamental.
@handrews handrews added this to the draft-08 milestone Mar 23, 2018
@handrews handrews changed the title Applic Move applicability keywords from Validation to Core Mar 23, 2018
...for the move of applicators to core.
Copy link
Member

@dlax dlax left a comment

Choose a reason for hiding this comment

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

Great job!
I could only find one typo.
Also tried to check that nothing disappeared in the process, this seems fine.

<t>
An instance can only fail an assertion that is present in the schema.
In some cases, this no-op behavior is identical to a keyword that exists with
certain values, and keyword defintions SHOULD note such values where known.
Copy link
Member

Choose a reason for hiding this comment

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

typo "defintions"

<section title="Subschema Application">
<t>
This vocabulary provides keywords for applying subschemas to the
instance in various ways. It is defined in this document, and
Copy link
Member

Choose a reason for hiding this comment

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

It might be helpful to insert an xref pointing to "A Vocabulary for Applying Subschemas" section in this document here.

@handrews
Copy link
Contributor Author

handrews commented Apr 4, 2018

Fixed both comments. @dlax since you approved this and the fixes were trivial, I'm going to go ahead and merge assuming the build checks pass.

Move the main text into core, and just reference it from
validation.
@handrews
Copy link
Contributor Author

handrews commented Apr 4, 2018

...and I realized I forgot to update regular expression concerns. @dlax and/or @Relequestual, please review the last commit and re-approve.

@handrews handrews merged commit dfefbba into json-schema-org:applic-base Apr 4, 2018
@handrews handrews deleted the applic branch May 27, 2018 06:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants