-
-
Notifications
You must be signed in to change notification settings - Fork 6.6k
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
[BUG][GO] openapi-generator generates invalid Go code for response code ranges (e.g. 5XX) #6829
Comments
I don't think 5xx is a valid status code. You need to provide something like 500 instead. |
@wing328
|
👌 Would you have time to contribute a fix? I can show you some good starting points. |
the same issue is present when generating any java server version. |
I've filed #7381 to add |
Bug Report Checklist
Description
For response code ranges (e.g. 1XX, 2XX, 5XX) it generate invalid Go code, for example:
openapi-generator version
v4.3.1
OpenAPI declaration file content or url
Command line used for generation
openapi-generator-cli generate --generator-name go
--input-spec ${OAS_SPEC_FILE}
--api-package ${GO_API_PACKAGE} --package-name ${GO_PACKAGE}
--git-host github.com --git-user-id exampleuser --git-repo-id ${GO_ARTIFACT}
--output "${GO_ARTIFACT}"
The text was updated successfully, but these errors were encountered: