Skip to content

Merge draft-next to master #1251

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 21 commits into from
Jul 8, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
2bf8f62
Allow contains to apply to objects as well as arrays
jdesrosiers Apr 19, 2021
bd68d1b
Move contains to "other" applicator section
jdesrosiers Apr 20, 2021
ccb8e04
Clarify that "length" applies to objects as well as arrays
jdesrosiers Apr 20, 2021
364b4b8
Add change log for bhutton-next
jdesrosiers May 14, 2021
1e18deb
Add to change log "contains" applies to objects
jdesrosiers May 14, 2021
86e0504
Document new branching process (#1115)
handrews Aug 11, 2021
daf73dd
Add Code of Conduct badge
Relequestual Aug 27, 2021
1fc9d6b
Add "contains" to keywords that effect "unevaluatedProperties"
jdesrosiers Oct 14, 2021
907d7f7
Support for IRI references (#1137)
jakubklimek Nov 5, 2021
d651307
update schema identifiers to "draft/next" everywhere, so implementati…
karenetheridge Nov 19, 2021
47c6d33
Remove bookending requirement for dynamicRef (#1139)
jdesrosiers Dec 3, 2021
ec88920
Add repo status
Relequestual Dec 20, 2021
e2aa1f6
fix broken reference
karenetheridge Jan 7, 2022
a5b8287
Add README instructions on how to install xml2rfc
jviotti Dec 29, 2021
f9f6e40
Add the "all" target to the list of PHONY targets
jviotti Dec 29, 2021
9d41963
Allow the XML2RFC GNU Make variable to be overridden by the caller
jviotti Dec 29, 2021
73f58fa
Add propertyDependencies keyword
jdesrosiers Oct 21, 2021
7a58f76
output - change property names in declarations
gregsdennis Jun 22, 2022
942158c
output - apply new property names to output examples
gregsdennis Jun 22, 2022
efcfd04
adds cref for further clarification on evaluation path in output node
gregsdennis Jun 27, 2022
29805af
Update CONTRIBUTING.md with the new branching strategy
jdesrosiers Jul 8, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@ If the pull request would solve a particular issue, reference the issue in the p

Changes that would affect implementation behavior should typically be opened as an issue first.

Pull requests should be made to master.
Generally, pull requests should be made to the `main` branch unless it is a
patch update and we are in a patch phase of the
[release process](https://github.com/json-schema-org/community/discussions/7).
In that case there will be a branch named something like `2020-12-patch` that
the PR should target instead.

Most PRs, including all PRs that impact implementation behavior, will be left open for a minimum of 14 days. Minor wording fixes may be merged more quickly once approved by a project member.

Expand Down Expand Up @@ -78,4 +82,4 @@ Support this project with your organization. Your logo will show up here with a
<a href="https://opencollective.com/json-schema/organization/6/website"><img src="https://opencollective.com/json-schema/organization/6/avatar.svg"></a>
<a href="https://opencollective.com/json-schema/organization/7/website"><img src="https://opencollective.com/json-schema/organization/7/avatar.svg"></a>
<a href="https://opencollective.com/json-schema/organization/8/website"><img src="https://opencollective.com/json-schema/organization/8/avatar.svg"></a>
<a href="https://opencollective.com/json-schema/organization/9/website"><img src="https://opencollective.com/json-schema/organization/9/avatar.svg"></a>
<a href="https://opencollective.com/json-schema/organization/9/website"><img src="https://opencollective.com/json-schema/organization/9/avatar.svg"></a>
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
XML2RFC=xml2rfc
XML2RFC ?= xml2rfc

OUT = \
jsonschema-core.html jsonschema-core.txt \
Expand All @@ -24,4 +24,4 @@ json-schema.tar.gz: $(OUT)
clean:
rm -f $(OUT) json-schema.tar.gz

.PHONY: clean
.PHONY: clean all
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Welcome to JSON Schema
[![Financial Contributors on Open Collective](https://opencollective.com/json-schema/all/badge.svg?label=financial+contributors)](https://opencollective.com/json-schema)
[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](https://github.com/json-schema-org/.github/blob/main/CODE_OF_CONDUCT.md) [![Project Status: Active – The project has reached a stable, usable state and is being actively developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active) [![Financial Contributors on Open Collective](https://opencollective.com/json-schema/all/badge.svg?label=financial+contributors)](https://opencollective.com/json-schema)

JSON Schema is a vocabulary that allows you to validate, annotate, and manipulate JSON documents.

Expand Down Expand Up @@ -35,7 +35,7 @@ Labels are assigned based on [Sensible Github Labels](https://github.com/Releque
* links.json - JSON Hyper-Schema's Link Description Object meta-schema
* hyper-schema-output.json - The recommended output format for JSON Hyper-Schema links

Type "make" at a shell to build the .txt and .html spec files.
Install "xml2rfc" using "pip" (https://pypi.org/project/xml2rfc/) and type "make" at a shell to build the .txt and .html spec files.

Descriptions of the xml2rfc, I-D documents, and RFC processes:

Expand Down
607 changes: 326 additions & 281 deletions jsonschema-core.xml

Large diffs are not rendered by default.

79 changes: 42 additions & 37 deletions jsonschema-validation.xml
Original file line number Diff line number Diff line change
Expand Up @@ -177,20 +177,20 @@

<section title="Meta-Schema" anchor="meta-schema">
<t>
The current URI for the default JSON Schema dialect meta-schema is
<eref target="https://json-schema.org/draft/2020-12/schema"/>.
The current IRI for the default JSON Schema dialect meta-schema is
<eref target="https://json-schema.org/draft/next/schema"/>.
For schema author convenience, this meta-schema describes a dialect
consisting of all vocabularies
defined in this specification and the JSON Schema Core specification,
as well as two former keywords which are reserved for a transitional period.
Individual vocabulary and vocabulary meta-schema URIs are given for
Individual vocabulary and vocabulary meta-schema IRIs are given for
each section below. Certain vocabularies are optional to support, which
is explained in detail in the relevant sections.
</t>
<t>
Updated vocabulary and meta-schema URIs MAY be published between
Updated vocabulary and meta-schema IRIs MAY be published between
specification drafts in order to correct errors. Implementations
SHOULD consider URIs dated after this specification draft and
SHOULD consider IRIs dated after this specification draft and
before the next to indicate the same syntax and semantics
as those listed here.
</t>
Expand All @@ -203,15 +203,15 @@
</t>
<t>
Meta-schemas that do not use "$vocabulary" SHOULD be considered to
require this vocabulary as if its URI were present with a value of true.
require this vocabulary as if its IRI were present with a value of true.
</t>
<t>
The current URI for this vocabulary, known as the Validation vocabulary, is:
&lt;https://json-schema.org/draft/2020-12/vocab/validation&gt;.
The current IRI for this vocabulary, known as the Validation vocabulary, is:
&lt;https://json-schema.org/draft/next/vocab/validation&gt;.
</t>
<t>
The current URI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/2020-12/meta/validation"/>.
The current IRI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/next/meta/validation"/>.
</t>

<section title="Validation Keywords for Any Instance Type" anchor="general">
Expand Down Expand Up @@ -414,13 +414,13 @@
then this keyword has no effect.
</t>
<t>
An instance array is valid against "maxContains" in two ways, depending on
the form of the annotation result of an adjacent
An instance array or object is valid against "maxContains" in two ways,
depending on the form of the annotation result of an adjacent
<xref target="json-schema">"contains"</xref> keyword. The first way is if
the annotation result is an array and the length of that array is less than
or equal to the "maxContains" value. The second way is if the annotation
result is a boolean "true" and the instance array length is less than or
equal to the "maxContains" value.
result is a boolean "true" and the instance length (number of items or
properties) is less than or equal to the "maxContains" value.
</t>
</section>

Expand All @@ -433,13 +433,13 @@
then this keyword has no effect.
</t>
<t>
An instance array is valid against "minContains" in two ways, depending on
the form of the annotation result of an adjacent
An instance array or object is valid against "minContains" in two ways,
depending on the form of the annotation result of an adjacent
<xref target="json-schema">"contains"</xref> keyword. The first way is if
the annotation result is an array and the length of that array is greater
than or equal to the "minContains" value. The second way is if the
annotation result is a boolean "true" and the instance array length is
greater than or equal to the "minContains" value.
annotation result is a boolean "true" and the instance length (number of
items or properties) is greater than or equal to the "minContains" value.
</t>
<t>
A value of 0 is allowed, but is only useful for setting a range
Expand Down Expand Up @@ -547,19 +547,19 @@
</t>

<t>
The current URI for this vocabulary, known as the Format-Annotation vocabulary, is:
&lt;https://json-schema.org/draft/2020-12/vocab/format-annotation&gt;. The current
URI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/2020-12/meta/format-annotation"/>.
The current IRI for this vocabulary, known as the Format-Annotation vocabulary, is:
&lt;https://json-schema.org/draft/next/vocab/format-annotation&gt;. The current
IRI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/next/meta/format-annotation"/>.
Implementing support for this vocabulary is REQUIRED.
</t>
<t>
In addition to the Format-Annotation vocabulary, a secondary vocabulary is available
for custom meta-schemas that defines "format" as an assertion. The URI for the
for custom meta-schemas that defines "format" as an assertion. The IRI for the
Format-Assertion vocabulary, is:
&lt;https://json-schema.org/draft/2020-12/vocab/format-assertion&gt;. The current
URI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/2020-12/meta/format-assertion"/>.
&lt;https://json-schema.org/draft/next/vocab/format-assertion&gt;. The current
IRI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/next/meta/format-assertion"/>.
Implementing support for the Format-Assertion vocabulary is OPTIONAL.
</t>
<t>
Expand Down Expand Up @@ -819,7 +819,7 @@
<list style="hanging">
<t hangText="uri:">
A string instance is valid against this attribute if it is
a valid URI, according to <xref target="RFC3986"/>.
a valid IRI, according to <xref target="RFC3987"/>.
</t>
<t hangText="uri-reference:">
A string instance is valid against this attribute if it is a valid URI
Expand Down Expand Up @@ -920,15 +920,15 @@
</t>
<t>
Meta-schemas that do not use "$vocabulary" SHOULD be considered to
require this vocabulary as if its URI were present with a value of true.
require this vocabulary as if its IRI were present with a value of true.
</t>
<t>
The current URI for this vocabulary, known as the Content vocabulary, is:
&lt;https://json-schema.org/draft/2020-12/vocab/content&gt;.
The current IRI for this vocabulary, known as the Content vocabulary, is:
&lt;https://json-schema.org/draft/next/vocab/content&gt;.
</t>
<t>
The current URI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/2020-12/meta/content"/>.
The current IRI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/next/meta/content"/>.
</t>
</section>

Expand Down Expand Up @@ -1127,15 +1127,15 @@
</t>
<t>
Meta-schemas that do not use "$vocabulary" SHOULD be considered to
require this vocabulary as if its URI were present with a value of true.
require this vocabulary as if its IRI were present with a value of true.
</t>
<t>
The current URI for this vocabulary, known as the Meta-Data vocabulary, is:
&lt;https://json-schema.org/draft/2020-12/vocab/meta-data&gt;.
The current IRI for this vocabulary, known as the Meta-Data vocabulary, is:
&lt;https://json-schema.org/draft/next/vocab/meta-data&gt;.
</t>
<t>
The current URI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/2020-12/meta/meta-data"/>.
The current IRI for the corresponding meta-schema is:
<eref target="https://json-schema.org/draft/next/meta/meta-data"/>.
</t>

<section title='"title" and "description"'>
Expand Down Expand Up @@ -1442,6 +1442,11 @@
</t>
<t>
<list style="hanging">
<t hangText="draft-next">
<list style="symbols">
<t>Use IRIs instead of URIs</t>
</list>
</t>
<t hangText="draft-bhutton-json-schema-validation-01">
<list style="symbols">
<t>Improve and clarify the "minContains" keyword explanation</t>
Expand Down
15 changes: 12 additions & 3 deletions meta/applicator.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/applicator",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/applicator",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/applicator": true
"https://json-schema.org/draft/next/vocab/applicator": true
},
"$dynamicAnchor": "meta",

Expand All @@ -29,6 +29,15 @@
"additionalProperties": { "$dynamicRef": "#meta" },
"default": {}
},
"propertyDependencies": {
"type": "object",
"additionalProperties": {
"type": "object",
"additionalProperties": { "$dynamicRef": "#meta" },
"default": {}
},
"default": {}
},
"propertyNames": { "$dynamicRef": "#meta" },
"if": { "$dynamicRef": "#meta" },
"then": { "$dynamicRef": "#meta" },
Expand Down
6 changes: 3 additions & 3 deletions meta/content.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/content",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/content",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/content": true
"https://json-schema.org/draft/next/vocab/content": true
},
"$dynamicAnchor": "meta",

Expand Down
24 changes: 12 additions & 12 deletions meta/core.json
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/core",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/core",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/core": true
"https://json-schema.org/draft/next/vocab/core": true
},
"$dynamicAnchor": "meta",

"title": "Core vocabulary meta-schema",
"type": ["object", "boolean"],
"properties": {
"$id": {
"$ref": "#/$defs/uriReferenceString",
"$ref": "#/$defs/iriReferenceString",
"$comment": "Non-empty fragments not allowed.",
"pattern": "^[^#]*#?$"
},
"$schema": { "$ref": "#/$defs/uriString" },
"$ref": { "$ref": "#/$defs/uriReferenceString" },
"$schema": { "$ref": "#/$defs/iriString" },
"$ref": { "$ref": "#/$defs/iriReferenceString" },
"$anchor": { "$ref": "#/$defs/anchorString" },
"$dynamicRef": { "$ref": "#/$defs/uriReferenceString" },
"$dynamicRef": { "$ref": "#/$defs/iriReferenceString" },
"$dynamicAnchor": { "$ref": "#/$defs/anchorString" },
"$vocabulary": {
"type": "object",
"propertyNames": { "$ref": "#/$defs/uriString" },
"propertyNames": { "$ref": "#/$defs/iriString" },
"additionalProperties": {
"type": "boolean"
}
Expand All @@ -39,13 +39,13 @@
"type": "string",
"pattern": "^[A-Za-z_][-A-Za-z0-9._]*$"
},
"uriString": {
"iriString": {
"type": "string",
"format": "uri"
"format": "iri"
},
"uriReferenceString": {
"iriReferenceString": {
"type": "string",
"format": "uri-reference"
"format": "iri-reference"
}
}
}
6 changes: 3 additions & 3 deletions meta/format-annotation.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/format-annotation",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/format-annotation",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/format-annotation": true
"https://json-schema.org/draft/next/vocab/format-annotation": true
},
"$dynamicAnchor": "meta",

Expand Down
6 changes: 3 additions & 3 deletions meta/format-assertion.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/format-assertion",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/format-assertion",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/format-assertion": true
"https://json-schema.org/draft/next/vocab/format-assertion": true
},
"$dynamicAnchor": "meta",

Expand Down
6 changes: 3 additions & 3 deletions meta/meta-data.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/meta-data",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/meta-data",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/meta-data": true
"https://json-schema.org/draft/next/vocab/meta-data": true
},
"$dynamicAnchor": "meta",

Expand Down
6 changes: 3 additions & 3 deletions meta/unevaluated.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/unevaluated",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/unevaluated",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/unevaluated": true
"https://json-schema.org/draft/next/vocab/unevaluated": true
},
"$dynamicAnchor": "meta",

Expand Down
6 changes: 3 additions & 3 deletions meta/validation.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/meta/validation",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/meta/validation",
"$vocabulary": {
"https://json-schema.org/draft/2020-12/vocab/validation": true
"https://json-schema.org/draft/next/vocab/validation": true
},
"$dynamicAnchor": "meta",

Expand Down
4 changes: 2 additions & 2 deletions output/schema.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://json-schema.org/draft/2020-12/output/schema",
"$schema": "https://json-schema.org/draft/next/schema",
"$id": "https://json-schema.org/draft/next/output/schema",
"description": "A schema that validates the minimum requirements for validation output",

"anyOf": [
Expand Down
Loading