mshauneu / chrome-swagger-ui

Chrome Extension for Swagger UI
17 stars 7 forks source link

Extension send requests to wrong urls #9

Closed shaggyone closed 7 years ago

shaggyone commented 7 years ago

After the last update the extension stopped to work

Now it sends to chrome-extension scheme instead of http/https

Following curl example is shown in query log:

curl -X POST --header 'Content-Type: application/json' \
                       --header 'Accept: application/json' \
                       --header 'X-AUTH-TOKEN: <my token>' \
                       -d '<my data>' \
                       'chrome-extension://<my-url>'
                             ^ mistake, should not change original url scheme
ashertarno commented 7 years ago

still works through Expand Operations. can be used as a work around meanwhile...

mkrufky commented 7 years ago

this is a duplicate of https://github.com/mshauneu/chrome-swagger-ui/issues/10 (not sure why it's closed) ... There is a patch to fix to swagger-js here: https://github.com/swagger-api/swagger-js/pull/913

emreerguden commented 7 years ago

i closed because the problem is not about swagger-chrome-extension. I tried to fix and send pull request to swager-js but i am not sure they will merge it and i am not sure if chrome-swagger-ui will get the latest version :) I reopened #10

They have merged the fixed, new swagger 2.2.8 will be fixed if chromw extension ui will have the latest version, this issue and 10. issue will be closed

emreerguden commented 7 years ago

Can you check with the version 0.0.7, if the problem is same as issue #10, then it should be resolved.

theigl commented 7 years ago

I'm still seeing the same issue after upgrading to 0.0.7. Is there anything else I have to do to get this working again?

emreerguden commented 7 years ago

if swager doc has no scheme property which should have at least "http" information new swagger ui send exceptions. Could you please check scheme information in swagger doc? If it is not exists, then it should be added to document json. Otherwise please give information about your case, let us open issue to swaggerui git hub. (For ex. my swagger doc has "schemes":["http","https"], only http is best for ex)

theigl commented 7 years ago

@emreerguden: Thank you very much, that was it!

emreerguden commented 7 years ago

Then, we shall close the issue, your welcome

eortner commented 5 years ago

I have the latest java lib, the latest chrome extension, and this is still an issue. There is a workaround, just not using the extension, but it is not the idea.