Swagger-editor: Generator3 needs SSL. OAS3.0 Client Generation Broken

Created on 22 May 2018  路  7Comments  路  Source: swagger-api/swagger-editor

Q&A (please complete the following information)

  • OS: Ubuntu 18.04
  • Browser: Chrome
  • Version: 66.0.3359.181
  • Method of installation: n/a
  • Swagger-Editor version: whatver is currently at editor.swagger.io
  • Swagger/OpenAPI version: OpenAPI 3.0

Example Swagger/OpenAPI definition:
https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v3.0/petstore.yaml

Describe the bug you're encountering

I just want to generate HTML client code for my OpenAPI 3.0 yaml. When I try it with the OAS3.0 petstore example (see above), it throws a mixed content error:
index.js:1 Mixed Content: The page at 'https://editor.swagger.io/' was loaded over HTTPS, but requested an insecure resource 'http://generator3.swagger.io/api/generator.json'. This request has been blocked; the content must be served over HTTPS.

To reproduce...

Steps to reproduce the behavior:

  1. Go to editor.swagger.io
  2. Paste in the OAS3.0 petstore code from https://raw.githubusercontent.com/OAI/OpenAPI-Specification/master/examples/v3.0/petstore.yaml
  3. Click generate client code in HTML
  4. See error

Expected behavior

HTML client gets downloaded for OAS3.0 stuff

Screenshots

generateerror2

Most helpful comment

@delmartechdude no problem! Glad to hear it.

We run releases weekly, so you should see this fixed on Swagger.io around this time of day on Friday.

In the meantime, using the Editor over HTTP should let you work around the issue!

All 7 comments

Well this is just silly...

Generator3 supports HTTPS, we just aren't using it 馃槵

thanks @delmartechdude!

@shockey Thanks for being so quick about fixing it! :) I've been very impressed with Swagger and OpenAPI. How soon will this fix be deployed?

@delmartechdude no problem! Glad to hear it.

We run releases weekly, so you should see this fixed on Swagger.io around this time of day on Friday.

In the meantime, using the Editor over HTTP should let you work around the issue!

@shockey Sounds good. And interesting...I was seeing this on my local Docker Swagger Editor instance as well over HTTP...however the error was different. I was getting an HTTP 500 error in the Chrome Dev Console back from generator3 I believe when clicking the client generate button. I might need to open another issue for that one ;)

Interesting indeed... If your definition was valid, the Codegen folks would probably love to hear about it: https://github.com/swagger-api/swagger-codegen

@shockey Yeah...I mean I assume my definition is valid because I'm not getting errors or rendering problems in Swagger Editor. So I've opened an issue with the Codegen people (https://github.com/swagger-api/swagger-codegen/issues/8222)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

alecmev picture alecmev  路  4Comments

korenlev picture korenlev  路  4Comments

ChristineBoersen picture ChristineBoersen  路  3Comments

bluesh55 picture bluesh55  路  3Comments

delim29 picture delim29  路  4Comments