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

Generated java client: maven-javadoc-plugin error #43

Closed
jmini opened this issue May 15, 2018 · 1 comment
Closed

Generated java client: maven-javadoc-plugin error #43

jmini opened this issue May 15, 2018 · 1 comment
Milestone

Comments

@jmini
Copy link
Member

jmini commented May 15, 2018

Description

Running maven in a generated java client can not be compiled due to javadoc error:

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.10.4:jar (attach-javadocs) on project petstore-openapigen-java: MavenReportException: Error while generating Javadoc: 
[ERROR] Exit code: 1 - /____/petstore-openapigen-java/src/main/java/org/openapitools/client/api/PetApi.java:298: error: unknown tag: String
[ERROR]      * @param status Status values that need to be considered for filter (optional, default to new ArrayList<String>())
[ERROR]                                                                                                             ^
[ERROR] /____/petstore-openapigen-java/src/main/java/org/openapitools/client/api/PetApi.java:359: error: unknown tag: String
[ERROR]      * @param status Status values that need to be considered for filter (optional, default to new ArrayList<String>())
[ERROR]                                                                                                             ^
[ERROR] /____/petstore-openapigen-java/src/main/java/org/openapitools/client/api/PetApi.java:371: error: unknown tag: String
[ERROR]      * @param status Status values that need to be considered for filter (optional, default to new ArrayList<String>())
[ERROR]                                                                                                             ^
[ERROR] /____/petstore-openapigen-java/src/main/java/org/openapitools/client/api/PetApi.java:384: error: unknown tag: String
[ERROR]      * @param status Status values that need to be considered for filter (optional, default to new ArrayList<String>())
[ERROR]                                                                                                             ^
[ERROR] 
[ERROR] Command line was: /Library/Java/JavaVirtualMachines/jdk1.8.0_161.jdk/Contents/Home/jre/../bin/javadoc @options @packages
openapi-generator version

3.0.0-SNAPSHOT

OpenAPI declaration file content or url

Normal petstore.json

Command line used for generation

Java code:

JavaClientCodegen config = new org.openapitools.codegen.languages.JavaClientCodegen();
config.setArtifactId("some-artifactId");
config.setJava8Mode(true);
config.setHideGenerationTimestamp(true);
config.setOutputDir(outputDir);

final OpenAPI openAPI = new OpenAPIParser().readLocation(folder + "/" + inputSpecName, null, new ParseOptions()).getOpenAPI()

final ClientOptInput opts = new ClientOptInput();
opts.setConfig(config);
opts.setOpenAPI(openAPI);
opts.setOpts(new ClientOpts());
new DefaultGenerator().opts(opts).generate();
Steps to reproduce

run mvn verify in petstore-openapigen-java/

Suggest a fix/enhancement

In the javadoc section in the template there is a difference between {{type}} and {{{type}}} (one is wrong).

I am not sure why we do not catch it in the CI server. Do we run mvn verify there?

@jmini
Copy link
Member Author

jmini commented May 20, 2018

Closed with #106

@jmini jmini closed this as completed May 20, 2018
aserkes pushed a commit to aserkes/openapi-generator that referenced this issue Aug 29, 2022
Signed-off-by: tvallin <thibault.vallin@oracle.com>
nilskuhn pushed a commit to nilskuhn/openapi-generator that referenced this issue Apr 6, 2023
Ghufz pushed a commit to Ghufz/openapi-generator that referenced this issue Jun 8, 2023
pulling in the python set-item fix from master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant