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
Hello I started to test openapi-generator this weekend. I want to use useTags option in order to generate different classes for my API. I have some tags with unicode character like é in french language.
When I generate my spring-boot application, I discovered that the generated interface has the following name CrancesApi.
Here is a partial of the generated file.
@Validated
@Api(value = "Crances", description = "the Crances API")
public interface CrancesApi {
It will be great if the generated interface name will be CreanceApi and the value of @Api remains Créances.
If I set allowUnicodeIdentifiers to true, both are generated with Créances word.
Related issues/PRs
Maybe #1695 if the problem comes from sanitize methods
Suggest a fix
The text was updated successfully, but these errors were encountered:
FixesOpenAPITools#1696
An object schema containing no properties that also has additionalProperties
set to an object schema with no properties will cause
ModelUtils.isFreeFormObject to throw an NPE.
This PR adds additional checking to avoid the NPE.
A-Joshi
pushed a commit
to ihsmarkitoss/openapi-generator
that referenced
this issue
Feb 27, 2019
FixesOpenAPITools#1696
An object schema containing no properties that also has additionalProperties
set to an object schema with no properties will cause
ModelUtils.isFreeFormObject to throw an NPE.
This PR adds additional checking to avoid the NPE.
Description
The Api name is sanitize for the class name and for the value of @Api swagger tag. I think it should only be sanitized for the class name.
openapi-generator version
OpenAPI declaration file content or url
Command line used for generation
Command line:
java -jar ~/git/github/openapi-generator/modules/openapi-generator-cli/target/openapi-generator-cli.jar generate -g spring -i tag.openapi.yaml -c java-config.json -o ./tags
Config file
Steps to reproduce
Hello I started to test openapi-generator this weekend. I want to use
useTags
option in order to generate different classes for my API. I have some tags with unicode character likeé
in french language.When I generate my spring-boot application, I discovered that the generated interface has the following name
CrancesApi
.Here is a partial of the generated file.
It will be great if the generated interface name will be
CreanceApi
and the value of @Api remainsCréances
.If I set
allowUnicodeIdentifiers
totrue
, both are generated withCréances
word.Related issues/PRs
Maybe #1695 if the problem comes from sanitize methods
Suggest a fix
The text was updated successfully, but these errors were encountered: