meta-schema features in VS Code extension warning in version ^1.68.0

Viewed 489

So basically I have a VS Code extension that provides JSON file validation based on the built in JSON validator. The schema that I'm validating against (OpenAPI 3.1.x) uses meta-schema features, i.e. $dynamicRef, which I also need to use, since I reference the OpenAPI schema.

When defining a custom schema like the following, I get a warning stating that the validator doesn't support meta-schema features yet. Needless to say, validation does really not work. When using normal $ref, most of the schema work but not properties that use $dynamicRef. So I'm forced to reference the schema by $dynamicRef as well.

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "OpenApiPathObject",
  "type": "object",
  "additionalProperties": {
    "$dynamicRef": "https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/schemas/v3.1/schema.json#/$defs/path-item-or-reference"
  }
}
The schema uses meta-schema features ($dynamicRef) that are not yet supported by the validator.

I'm using VS Code 1.69.0 and changed the required engine of my extension to ^1.68.0, which should include support for schema verion Draft 2020-12 as stated in the May 2022 release notes. What are my options here and how can I come around this warning?

Here's an excerpt of the extension package.json

...
"engines": {
    "vscode": "^1.68.0"
},
...
0 Answers
Related