fix: preserve JSON Schema 2020-12 keywords (#1018)
This commit is contained in:
parent
7044ccfe7b
commit
9bf459962e
2 changed files with 15 additions and 5 deletions
|
|
@ -9,11 +9,7 @@
|
||||||
# When bumping DRAFT_CONFORMANCE_VERSION, diff
|
# When bumping DRAFT_CONFORMANCE_VERSION, diff
|
||||||
# `conformance list --spec-version 2026-07-28` and update #977.
|
# `conformance list --spec-version 2026-07-28` and update #977.
|
||||||
|
|
||||||
server:
|
server: []
|
||||||
# SEP-2106: composition/conditional/$anchor keywords are stripped from
|
|
||||||
# published tool input schemas.
|
|
||||||
# tracked in #1003
|
|
||||||
- json-schema-2020-12
|
|
||||||
|
|
||||||
client:
|
client:
|
||||||
# Client does not yet send MCP-Protocol-Version header pre-initialize as
|
# Client does not yet send MCP-Protocol-Version header pre-initialize as
|
||||||
|
|
|
||||||
|
|
@ -556,6 +556,7 @@ impl ServerHandler for ConformanceServer {
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"$defs": {
|
"$defs": {
|
||||||
"address": {
|
"address": {
|
||||||
|
"$anchor": "address",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"street": { "type": "string" },
|
"street": { "type": "string" },
|
||||||
|
|
@ -567,6 +568,19 @@ impl ServerHandler for ConformanceServer {
|
||||||
"name": { "type": "string" },
|
"name": { "type": "string" },
|
||||||
"address": { "$ref": "#/$defs/address" }
|
"address": { "$ref": "#/$defs/address" }
|
||||||
},
|
},
|
||||||
|
"allOf": [{
|
||||||
|
"anyOf": [
|
||||||
|
{ "required": ["name"] },
|
||||||
|
{ "required": ["address"] }
|
||||||
|
]
|
||||||
|
}],
|
||||||
|
"if": { "required": ["address"] },
|
||||||
|
"then": {
|
||||||
|
"properties": {
|
||||||
|
"address": { "required": ["street"] }
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"else": { "required": ["name"] },
|
||||||
"additionalProperties": false
|
"additionalProperties": false
|
||||||
})),
|
})),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue