Created by: jmini
PR checklist
-
Read the contribution guidelines. -
Ran the shell script under ./bin/
to update Petstore sample so that CIs can verify the change. (For instance, only need to run./bin/{LANG}-petstore.sh
,./bin/openapi3/{LANG}-petstore.sh
if updating the {LANG} (e.g. php, ruby, python, etc) code generator or {LANG} client's mustache templates). Windows batch files can be found in.\bin\windows\
. -
Filed the PR against the correct branch: master
,. Default:3.4.x
,4.0.x
master
. -
Copied the technical committee to review the pull request if your PR is targeting a particular programming language. @OpenAPITools/generator-core-team
Description of the PR
To remove follwing Stacktrace:
[main] WARN i.s.parser.util.DeserializationUtils - Error snake-parsing yaml content
io.swagger.parser.util.DeserializationUtils$SnakeException: Exception safe-checking yaml content (maxDepth 2000)
at io.swagger.parser.util.DeserializationUtils$CustomSnakeYamlConstructor.getSingleData(DeserializationUtils.java:300)
at org.yaml.snakeyaml.Yaml.loadFromReader(Yaml.java:450)
at org.yaml.snakeyaml.Yaml.load(Yaml.java:369)
at io.swagger.parser.util.DeserializationUtils.readYamlTree(DeserializationUtils.java:137)
at io.swagger.parser.Swagger20Parser.deserializeYaml(Swagger20Parser.java:83)
at io.swagger.parser.Swagger20Parser.readWithInfo(Swagger20Parser.java:64)
at io.swagger.parser.SwaggerParser.readWithInfo(SwaggerParser.java:32)
at io.swagger.v3.parser.converter.SwaggerConverter.readLocation(SwaggerConverter.java:92)
at io.swagger.parser.OpenAPIParser.readLocation(OpenAPIParser.java:19)
at org.openapitools.codegen.config.CodegenConfigurator.toClientOptInput(CodegenConfigurator.java:606)
at org.openapitools.codegen.cmd.Generate.run(Generate.java:367)
at org.openapitools.codegen.OpenAPIGenerator.main(OpenAPIGenerator.java:60)
Caused by: java.lang.IllegalAccessError: tried to access field org.yaml.snakeyaml.constructor.BaseConstructor.composer from class io.swagger.parser.util.DeserializationUtils$CustomSnakeYamlConstructor
at io.swagger.parser.util.DeserializationUtils$CustomSnakeYamlConstructor.getSingleData(DeserializationUtils.java:279)
... 11 common frames omitted
That is due to an outdated version of org.yaml:snakeyaml
, we need to update TestNG.
Before the change, our TestNG version 6.9.6
(very old) requires version 1.15
of org.yaml:snakeyaml
as compile dependency.
I took the opportunity of this PR to also remove the JUnit stuff that was configured and used in some of our tests.