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

Regression: Responses without content are displayed with empty Schema and Example Value #5453

Closed
hkosova opened this issue Jul 10, 2019 · 1 comment · Fixed by #5504
Closed

Comments

@hkosova
Copy link
Contributor

hkosova commented Jul 10, 2019

Q&A (please complete the following information)

  • OS: Windows 10
  • Browser: any
  • Method of installation: https://editor.swagger.io
  • Swagger-UI version: 3.23.0
  • Swagger/OpenAPI version: OpenAPI 3.0

Content & configuration

Example Swagger/OpenAPI definition:

openapi: 3.0.2
info:
  title: Response without a schema
  version: 1.0.0
paths:
  /foo:
    get:
      responses:
        '200':
          description: OK

Describe the bug you're encountering

Responses without content are now displayed with empty "Example Value" and "Schema" sections. This is a regression introduced in v. 3.23.0 by /pull/5427.

Expected behavior

Responses without content should NOT have the "Example Value" and "Schema" sections.

Screenshots

Empty "Example Value" and "Schema" sections in a response

@shockey
Copy link
Contributor

shockey commented Jul 10, 2019

Thanks @hkosova!

Based on your report, this appears to be limited to us incorrectly rendering an empty ModelExample -- that is, we aren't ever not displaying valid data. As such, I think a hot fix isn't necessary, we can fix this in the next couple of weeks and ship it out on a Friday.

Let me know if I've missed something, or you disagree!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants