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

Tags are breaking the structure of the Go client #199

Open
mraerino opened this issue Sep 23, 2019 · 7 comments
Open

Tags are breaking the structure of the Go client #199

mraerino opened this issue Sep 23, 2019 · 7 comments
Assignees

Comments

@mraerino
Copy link
Member

Tags on operations cause the Go client generator to create a package for every tag.
Although this seems reasonable we cannot use this feature because it would be a breaking change for all users of the Go client.

Current workaround is to remove tags before generating.
We need to think of a stable way to keep doing this or make a breaking change, e.g. v2 release.

@mraerino mraerino self-assigned this Sep 23, 2019
@ehmicky
Copy link
Contributor

ehmicky commented Sep 24, 2019

Should this be closed?

@mraerino
Copy link
Member Author

Let's discuss how to solve the rough edges of my workaround over here.

@ehmicky
Copy link
Contributor

ehmicky commented Sep 24, 2019

Three questions:

  • are we always sure the Makefile will be executed on a machine that has sh (e.g. some Windows machines don't) and jq installed?
  • we are already both validating and "flattening" the swagger.yml and converting it to swagger.json as part of npm run convert. This could be used instead of go-swagger validate and flatten methods?
  • likewise we could remove the tags properties from that convert.js method, and output it to a second file swagger_go.json?

@verythorough
Copy link
Contributor

I don't suppose that would mean we could move away from go-swagger and upgrade to OpenAPI 3.0?

@ehmicky
Copy link
Contributor

ehmicky commented Sep 25, 2019

While we could use the Node.js logic instead of go-swagger for validation, flattening and JSON conversion, we still need go-swagger to generate the Go SDK code.

@mraerino
Copy link
Member Author

I don't suppose that would mean we could move away from go-swagger and upgrade to OpenAPI 3.0?

I'm happy to explore that. is there an existing issue?

@ehmicky
Copy link
Contributor

ehmicky commented Sep 25, 2019

There is an issue at #171.

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

No branches or pull requests

3 participants