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

Provide example of keyword/type applicability. #1

Closed
wants to merge 1 commit into from

Conversation

handrews
Copy link
Owner

The word "applicability" is a good name for the key concept of this
section. The title feels rather vague otherwise.

Make clear that this is a natural consequence of keyword independence,
which is explained in the immediately previous section. Otherwise,
having a section about this makes it sound like its own special case.

Use "multipleOf" to show why this is an essential behavior. When you
need to use a type-specific keyword, and the negation of a keyword
specific to the same type, it only works because type is not automatically
constrained.

I used "multipleOf" because (unlike "maxLength"), you cannot eliminate
the use of "not" by changing keywords (to "minLength"). There is no
other way in JSON schema to express not being a multiple of something.

The word "applicability" is a good name for the key concept of this
section.  The title feels rather vague otherwise.

Make clear that this is a natural consequence of keyword independence,
which is explained in the immediately previous section.  Otherwise,
having a section about this makes it sound like its own special case.

Use "multipleOf" to show why this is an essential behavior.  When you
need to use a type-specific keyword, and the negation of a keyword
specific to the same type, it only works because type is not automatically
constrained.

I used "multipleOf" because (unlike "maxLength"), you cannot eliminate
the use of "not" by changing keywords (to "minLength").  There is no
other way in JSON schema to express not being a multiple of something.
@handrews
Copy link
Owner Author

After discussion, it's clear that this is not the right approach.

@handrews handrews closed this Nov 21, 2016
@handrews handrews deleted the applicability branch November 21, 2016 18:22
handrews added a commit that referenced this pull request Nov 1, 2017
Better explanation of the concerns around and possible future
direction of $schema usage.

Also add an XML comment to remind us of the most notable concern,
so we can skip the whole thing where we forget about it and then
argue about it until we work it out again.  Which of course has
never happened...
handrews pushed a commit that referenced this pull request Jul 9, 2019
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.

1 participant