- edited description
Error after upgrading Snake YAML from 1.33 to 2.0
I’m seeing the following runtime error after my recent upgrade from 1.33 to 2.0:
java.lang.NoSuchMethodError: org.yaml.snakeyaml.constructor.SafeConstructor: method 'void <init>()' not found
Can someone please assist?
P.S: I’m not using Spring in my project.
Comments (11)
-
reporter -
- changed status to open
-
- marked as minor
- marked as task
-
assigned issue to
-
Do you use any IDE ?
SafeConstructor
requires to haveLoaderOptions
in its constructor.(why Spring should anyhow affect how you create an instance of
SafeConstructor
?) -
reporter I'm using
SafeConstructor
like this:Yaml yaml = new Yaml(new SafeConstructor(new LoaderOptions()), new Representer(yamlOptions()));
-
The initial report clearly shows that you call empty contructor:
method 'void <init>()
-
Can you please provide a complete failing test ?
-
It look like you parse bean has not empty param
constructor
and the snakeyaml need it the parse by reflect -
reporter Apologies, it was not a SnakeYAML library issue. This can be closed.
-
reporter - changed status to resolved
-
- changed status to invalid
- Log in to comment