Skip to content

Generated client doesn't have "text/html" consumer #106

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

Closed
maxkarelov opened this issue Jun 22, 2018 · 0 comments
Closed

Generated client doesn't have "text/html" consumer #106

maxkarelov opened this issue Jun 22, 2018 · 0 comments

Comments

@maxkarelov
Copy link
Contributor

go-swagger generated client is unable to work with "text/html" responses because there is no in consumers list

runtime/client/runtime.go

Lines 207 to 215 in 563d495

// TODO: actually infer this stuff from the spec
rt.Consumers = map[string]runtime.Consumer{
runtime.JSONMime: runtime.JSONConsumer(),
runtime.XMLMime: runtime.XMLConsumer(),
runtime.TextMime: runtime.TextConsumer(),
runtime.DefaultMime: runtime.ByteStreamConsumer(),
}
rt.Producers = map[string]runtime.Producer{
runtime.JSONMime: runtime.JSONProducer(),

maxkarelov added a commit to maxkarelov/runtime that referenced this issue Jun 22, 2018
casualjim added a commit that referenced this issue Jun 22, 2018
Fixes #106. Add text/html consumer
bcomnes added a commit to netlify/open-api that referenced this issue Feb 26, 2019
This should fix the missing consumer errors:

- go-openapi/runtime#106
- go-openapi/runtime@17da9ad
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

1 participant