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

bump swagger to 3.x #70

Closed
srl295 opened this issue Jul 26, 2017 · 3 comments · Fixed by #86
Closed

bump swagger to 3.x #70

srl295 opened this issue Jul 26, 2017 · 3 comments · Fixed by #86
Assignees
Milestone

Comments

@srl295
Copy link
Contributor

srl295 commented Jul 26, 2017

better to do this before #68 edit: see below

https://swagger.io/new-ui-faq/

@srl295 srl295 modified the milestone: v1.6.0 Jul 26, 2017
@srl295
Copy link
Contributor Author

srl295 commented Jul 26, 2017

more at
https://github.com/swagger-api/swagger-js/releases/tag/v3.0.1

  • requires ES6

Minimum runtime node version: 4.x

so yeah #55

I made the decision way back when to not require promises. But I think it was before native promises were in node.

If we were to go promise-only… now that the underlying REST calls in swagger 3.x require promises… we could probably do it by having the cb parameter be optional. No callback, and you get a promise.

Given all of this, I am wondering if we should not move to 3.x right now, and think about it a bit more. An interim step might be to add promise support, prior to making it the default case.

Yes, we could 'unpromisify' the promises to just call the callback function, that doesn't seem so productive though.

srl295 added a commit to srl295/gp-js-client that referenced this issue Jul 26, 2017
@srl295 srl295 mentioned this issue Aug 2, 2017
@srl295
Copy link
Contributor Author

srl295 commented Aug 26, 2017

See Level/levelup#455 (comment)

@srl295
Copy link
Contributor Author

srl295 commented Aug 28, 2017

@srl295 srl295 mentioned this issue Aug 30, 2017
srl295 added a commit to srl295/gp-js-client that referenced this issue Aug 30, 2017
- bump swagger to 3.x
- return Promises everywhere
- add eslint as an automated step

Note: `basicAuth` is not supported at this point.

Fixes: IBM-Cloud#70
srl295 added a commit to srl295/gp-js-client that referenced this issue Aug 30, 2017
- note that docs aren’t updated to note that cb is optional and
promises are returned.

To fix in: IBM-Cloud#85

IBM-Cloud#70
@srl295 srl295 added this to the v2.0.0 milestone Aug 30, 2017
@srl295 srl295 self-assigned this Sep 7, 2017
@srl295 srl295 closed this as completed in #86 Sep 8, 2017
srl295 added a commit to srl295/gp-js-client that referenced this issue Oct 31, 2017
- reset package.json to accept later swagger-client versions
- apply() function needed to return `obj` instead of `true` for the load of swagger.json

This bug was introduced in IBM-Cloud#70  because before swagger-api/swagger-js#1161 it seems the requestInterceptor was not called for /swagger.json loads.

Fixes: IBM-Cloud#104
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.

1 participant