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

[json] JSONSchema draft 2019-09 support #98724

Open
srounce opened this issue May 28, 2020 · 25 comments
Open

[json] JSONSchema draft 2019-09 support #98724

srounce opened this issue May 28, 2020 · 25 comments
Assignees
Labels
feature-request Request for new features or functionality help wanted Issues identified as good community contribution opportunities json JSON support issues
Milestone

Comments

@srounce
Copy link

srounce commented May 28, 2020

JSONSchema draft-07 is currently supported but http://json-schema.org/draft/2019-09/schema# does not currently load, or at least no completion or validation functionality is able to be provided from it.

@vscodebot
Copy link

vscodebot bot commented May 28, 2020

(Experimental duplicate detection)
Thanks for submitting this issue. Please also check if it is already covered by an existing one, like:

@aeschli aeschli added feature-request Request for new features or functionality json JSON support issues labels Jun 2, 2020
@aeschli aeschli changed the title JSONSchema draft 2019-09 support [json] JSONSchema draft 2019-09 support Jun 2, 2020
@aeschli aeschli added this to the Backlog milestone Jun 2, 2020
@aeschli aeschli added the help wanted Issues identified as good community contribution opportunities label Aug 27, 2020
@aeschli
Copy link
Contributor

aeschli commented Aug 27, 2020

@Relequestual
Copy link

As an FYI, OpenAPI Specification 3.1 defines using JSON Schema 2020-12.
We're working on the test suite.
There are a few implementations of 2020-12 already should anyone wish to try it.

carlos-zamora pushed a commit to microsoft/terminal that referenced this issue Jun 4, 2021
Update profiles schema to draft 2020-12 because as mentioned in microsoft/vscode#98724 (comment), OpenAPI Specification 3.1 defines using JSON Schema 2020-12 and VS Code already has early implementation around it.

Basically, this just gets rid of the following error shown by VS Code when editing the settings.json file
```
Draft 2019-09 schemas are not yet fully supported.
```

## PR Checklist
* [x] CLA signed. If not, go over [here](https://cla.opensource.microsoft.com/microsoft/Terminal) and sign the CLA
* [x] Schema updated.
@pratnala
Copy link

I still see this error in VS Code

Draft 2019-09 schemas are not yet fully supported.

Is this fixed?

@ajcool2k
Copy link

ajcool2k commented Jul 1, 2021

I still see this error in VS Code

Draft 2019-09 schemas are not yet fully supported.

Is this fixed?

What do you mean by fixed? There is no implementation for the 2019-09 version.

@Relequestual
Copy link

@ajcool2k what do you mean by "There is no implementation for the 2019-09 version."?
Within VSCode, no there is not.
In the community? There are many: https://json-schema.org/implementations.html

@ajcool2k
Copy link

@ajcool2k what do you mean by "There is no implementation for the 2019-09 version."?

Within VSCode, no there is not.

In the community? There are many: https://json-schema.org/implementations.html

This is clear. My point is, that there cannot be a fix when there is no bug and clearly there is no bug.

@Relequestual
Copy link

Relequestual commented Jul 22, 2021

🤷‍♂️ "Is it fixed?" / "Is my problem resolved now?"
Please try to consider that English is not everyones first language, and be kind. It's quite clear what they meant.

Demonstrating empathy and kindness toward other people

https://opensource.microsoft.com/codeofconduct/

@ajcool2k
Copy link

🤷‍♂️ "Is it fixed?" / "Is my problem resolved now?"
Please try to consider that English is not everyones first language, and be kind. It's quite clear what they meant.

Demonstrating empathy and kindness toward other people

https://opensource.microsoft.com/codeofconduct/

I apologize, wrote this on the go. Just found it strange that people joining the discussion of an open feature requesting asking if it is fixed yet :-). Yeah but I agree, will be more polite on this in the feature. Thanks for making me aware of it @Relequestual

@Relequestual
Copy link

@wolf99
Copy link

wolf99 commented Apr 17, 2022

Am working on exercism/problem-specifications#1972 and would love to see more recent drafts supported, even small thinhgs like the support for "format": "uuid" from 2019-09 would make things instantly happier 🙂.

@niklas-paro
Copy link

niklas-paro commented Apr 25, 2022

Would love to see support for this. We were considering upgrading a schema we use from draft 07 to draft 2019-09. We are planning to use the Monaco Editor. However, the lack of support means we'll have to skip the upgrade, compromise, or find a different editor.

@aeschli
Copy link
Contributor

aeschli commented May 13, 2022

I made progress and closed some gaps: See microsoft/vscode-json-languageservice#133

The remaining known gaps are:

@isc-rsingh
Copy link

Just a cheerleading comment. Looking forward to meta-schema support. I have a project that needs it badly!

@thomasklein-toptal
Copy link

Cheerleading @aeschli and dancing around my chair for this one to get done :)

@ghost
Copy link

ghost commented Nov 1, 2022

A question: When using "$schema": "https://json-schema.org/draft/2020-12/schema in VS Code 1.71.2 I get the warning The schema uses meta-schema features ($dynamicRef) that are not yet supported by the validator.. This is fine and expected. Validation for the implemented features works fine. However, with 2020-12 intellisense / autocompletion in VS code does not work any longer. It works fine if I go to draft-07. Is this a known issue or expected behaviour?

@aeschli
Copy link
Contributor

aeschli commented Nov 1, 2022

@stephan-probst Can you file an issue with steps and a sample? I quickly tested and I see code completions.

@gcacars
Copy link

gcacars commented Mar 8, 2023

A question: When using "$schema": "https://json-schema.org/draft/2020-12/schema in VS Code 1.71.2 I get the warning The schema uses meta-schema features ($dynamicRef) that are not yet supported by the validator.. This is fine and expected. Validation for the implemented features works fine. However, with 2020-12 intellisense / autocompletion in VS code does not work any longer. It works fine if I go to draft-07. Is this a known issue or expected behaviour?

Same here. For root level properties this works fine:
image

But for sub levels, autocompletion doesn't work:
image

When I change to draft-07 the magic happens:
image

microsoft/vscode-json-languageservice#179

@dahu33
Copy link

dahu33 commented Jun 16, 2023

Is this issue resolved? I'm a bit confused here.

@gcacars
Copy link

gcacars commented Jun 22, 2023

3 years later...

@Relequestual
Copy link

The VSCode Language Service is now on Bowtie: https://bowtie-json-schema.github.io/bowtie/

Bowtie is a multi-implementation tester that uses the official JSON Schema test suite and reports on compliance. It was created and is maintained by members of the JSON Schema team and community.

@DaVince
Copy link

DaVince commented Sep 12, 2023

3 years later...

Some features just take a while to implement, and 3 years later has seen progress, y'know? :)

@gcacars
Copy link

gcacars commented Sep 13, 2023

Yep, but this is most like 2019-19 version, I can imagine that this isn't a big effort.
Also, I just complaining about the auto complete, that I guess that is more simple yet.

@julian-alarcon
Copy link

OpenAPI 3.0.4 released, and we still have this issue

@delmohf
Copy link

delmohf commented Dec 5, 2024

OpenAPI 3.0.4 released, and we still have this issue

Even version 3.1 was released in 2021 and this issue is still here :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request Request for new features or functionality help wanted Issues identified as good community contribution opportunities json JSON support issues
Projects
None yet
Development

No branches or pull requests