Thanks for filing an issue 😄 ! Before you submit, please read the following:
Search open/closed issues before submitting since someone might have asked the same thing before!
Issues on GitHub are only related to problems of Swagger-Editor itself. We’ll try to offer support
here for your use case, but we can’t offer help with projects that use Swagger-UI indirectly,
like Springfox or swagger-node.
If your issue has to do with the right-hand side of the Editor, you’re likely talking about
Swagger-UI. Please file your issue there instead: https://github.com/swagger-api/swagger-ui/issues/new
Likewise, we can’t accept features or bugs within the Swagger/OpenAPI specifications themselves,
or anything that violates the specifications.
As you will see with the provided evil, but valid swagger, there a number of things done incorrectly due to extensions not being properly ignored and being parsed as things like paths or responses.
editor.swagger.io parses and validates the swagger, but shows things like “x-an-extension-fake-path” as paths rather than ignoring them as they are extensions.
editor2.swagger.io fails to even parse the swagger document as it tries to read extensions as a variety of different object types instead of ignoring them
(for example the following error seems to be due to trying to read path.consumes from an extension which is null or a primative.
✖ Unknown Error
Cannot read property 'consumes' of undefined
<!— Provide a general summary of the issue in the title above –>
| Bug or feature request?
| Which Swagger/OpenAPI version?
| Which Swagger-Editor version?
|| editor.swagger.io and editor2.swagger.io as of 13/10/2017
| Which browser & version?
|| chrome 61
| Which operating system?
|| windows 10
Demonstration API definition
<!— If you’re describing a bug, tell us what should happen –>
<!— If you’re suggesting a change/improvement, tell us how it should work –>
Swagger document is parsed correctly. Extensions are not displayed as paths, responses or any other type of object.
<!— If describing a bug, tell us what happens instead of the expected behavior –>
<!— If suggesting a change/improvement, explain the difference from current behavior –>
extensions are not ignored by whatever is parsing the swagger, and the UI displays extensions as paths.
<!— Not obligatory, but suggest a fix/reason for the bug, –>
<!— or ideas how to implement the addition or change –>
Extensions should be ignored in every location that they are allowed. They should not be parsed as, or show up as parameters, paths, responses and any other types of object.
The provided swagger document should parse correctly and not display and extensions. It should also display all parameters and paths as expected.
<!— How has this issue affected you? What are you trying to accomplish? –>
<!— Providing context helps us come up with a solution that is most useful in the real world –>
Tried to make a swagger for my own project which would allow project developers to find issues with the way swagger is handled. Instead, found issues with the official tools.