vscode-yaml
vscode-yaml copied to clipboard
Broken completion for allof inside ref
Describe the bug
Expected Behavior
Completion returns key:\n\t
Current Behavior
Completion returns key
Steps to Reproduce
- Insert
# yaml-language-server: $schema=example.schema.jsonas file header - Try a working example and observe expected behavior:
{
"title": "Values",
"type": "object",
"$schema": "http://json-schema.org/schema#",
"$ref": "#/$defs/instance",
"required": [
"thisinstance"
],
"$defs": {
"union": {
"type": "object",
"properties": {
"config0": {
"type": "string"
}
}
},
"instance": {
"type": "object",
"properties": {
"thisinstance": {
"$ref": "#/$defs/union"
}
}
}
}
}
- Try a broken example and observe undesired behavior
{
"title": "Values",
"type": "object",
"$schema": "http://json-schema.org/schema#",
"$ref": "#/$defs/instance",
"required": [
"thisinstance"
],
"$defs": {
"union": {
"allOf": [
{
"type": "object",
"properties": {
"config0": {
"type": "string"
}
}
},
{
"type": "object",
"properties": {
"config1": {
"type": "string"
}
}
}
]
},
"instance": {
"type": "object",
"properties": {
"thisinstance": {
"$ref": "#/$defs/union"
}
}
}
}
}
Environment
- [ ] Linux