You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I was generating code to work with the EVE Online api and was getting bad requests returned by the server.
Dug into it and it was because the generated code included empty but non-null bodies in all requests and the server was rejecting them. Presumably their server is just being more strict than the HTTP spec which allows for GET to have a body that would be ignored.
Is it worth adding an option to codegen that would tell the templates to not include an empty body on verbs like GET/DELETE? is there a reason not to? I have this half-implemented (template modified, but no opt) and would be happy to submit a PR if its something desired.
The text was updated successfully, but these errors were encountered:
I was just dealing with this today(2nd time this year). It's painful enough to troubleshoot that I hope we can get a fix for this, it looks like they are lacking contributors right now: #167
Actually my edit shows that swagger codegen is actually out of spec now. Previously it was tolerable to include empty bodies in those requests, but now its agaisnt spec.
So I was generating code to work with the EVE Online api and was getting bad requests returned by the server.
Dug into it and it was because the generated code included empty but non-null bodies in all requests and the server was rejecting them. Presumably their server is just being more strict than the HTTP spec which allows for GET to have a body that would be ignored.
Is it worth adding an option to codegen that would tell the templates to not include an empty body on verbs like GET/DELETE? is there a reason not to? I have this half-implemented (template modified, but no opt) and would be happy to submit a PR if its something desired.
The text was updated successfully, but these errors were encountered: