-
Notifications
You must be signed in to change notification settings - Fork 0
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
Support for OpenAPI release 3.1.0 #5
Comments
Thanks for the feedback! We plan to support 3.1.0 in the future versions of the extension, but supporting it requires more than simply fixing a version check. For instance we rely on OpenAPI JSON Schema to do the validation, which is not yet available for 3.1.0. |
Hi, This would greatly simplify the #ref to pathItem object in separate file. In 3.0 only a generic yaml object can be imported. But then the plugin support cannot be utilized on this yaml file. Thanks for your great plugin |
Hi @Davetwo ! we surely would like to support 3.1, but something which is stopping us from doing it right now We use JSON Schemas provided by OpenAPI Initiative to do validation and completion, and the |
Apparently IntelliJ uses the schemas available at https://www.schemastore.org/json/. A PR to their GitHub repo would enable this 🙂 @ak1394 Would this do the trick? |
@filipeamaral unfortunately no, the new schema uses newer "JSON Schema 2020-12" dialect not yet supported by IntelliJ |
Does anyone know if there's an outstanding issue on the Jetbrains issue tracker to support 2020-12 schemas? I've tried searching but can't find anything |
I'm not sure there is visible issue on the tracker yet, so far we've contacted their support but haven't heard back yet. |
The issue in IntelliJ tracker is https://youtrack.jetbrains.com/issue/IDEA-275297 |
@ak1394 maybe you could add a link to the issue tracker in the error message, so that people can like it and, thus, bump its priority By error message I mean this one:
|
We need 3.1 support for |
3.1.0 is now over a year old... is there really no way to validate these in the IDE? |
What is holding up here ? It's been more than two years. In our case, we are not relying on json schema for the models and use yaml instead. So I guess most of the previous comments are not applying to us. May I propose to fix support for 3.1.0 for yaml files at least? |
Hi @michellemay ! Unfortunately, the JSON Schema support is central for the 3.1 support. We rely on the IDE to provide validation and auto completion for both JSON and YAML files. So even if you are using YAML, you still rely on JSON Schema. |
@ak1394, what this does exactly mean? If the support has to be provided by the IDE, is this bug still valid? If it's not only about the IDE, what is needed to be done to have the support for OAS 3.1? Moreover, it looks that json-schema-org.github.io has been archived on past Oct. 23, and all information are now available on https://json-schema.org/: what now? As any user can add new JSON schemes in IDEA (in addition to the ones supported out-of-the-box), there is any workaround one could apply? Or could the plugin itself ship/setup the new schema? (This could come in handy for future version, eventually). And a last question: how using JSON Schema 2020-12 can be enough, if OAS 3.1 is actually using a specific dialect? (Dialect already available on json-schema.org, BTW.) Sorry for the many questions, but I hope they can somehow help to shed some light on this issue's status, and eventually to get to close it. |
Hi @meden ! Maybe I should have worded it a bit better, when I talk about "JSON Schema support" in the context of this ticket, I specifically mean the support for the "JSON Schema 2020-12" dialect of it. OAS 3.1 uses this newer schema dialect which is not currently supported IntelliJ (see this ticket for details https://youtrack.jetbrains.com/issue/IDEA-275297), so this is the issue not the availability of the schemas itself. Without editor support for this dialect, there is no point of support for 3.1 as things like autocompletion and validation will not work. |
@ak1394, thanks for the clarification. I guess then it's not enough to add a custom schema (as I actually tried to do), as it would have a more recent JSON schema-version directly supported in IDEA anyway, right? |
@meden Correct! See the details here https://youtrack.jetbrains.com/issue/IDEA-275297 |
There is a new release of OpenAPI (3.1.0). The regex for validating the version marks this as invalid.
https://github.com/OAI/OpenAPI-Specification/releases
The text was updated successfully, but these errors were encountered: