java.lang.IncompatibleClassChangeError

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • When using job-dsl-plugin 1.22, I forgot to give the job a name, and I ended up getting error message as below. I would suggest to output a more helpful error message which, in this case, should reveal where exactly the problem was or prompt me more helpful information. As a newbie to Jenkins plugins, the following error message is very difficult for me to figure out the root cause. FATAL: the number of constructors during runtime and compile time for java.lang.RuntimeException do not match. Expected 5 but got 4 java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for java.lang.RuntimeException do not match. Expected 5 but got 4 at groovy.lang.MetaClassImpl.selectConstructorAndTransformArguments(MetaClassImpl.java:1381) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.selectConstructorAndTransformArguments(ScriptBytecodeAdapter.java:234) at javaposse.jobdsl.dsl.NameNotProvidedException.<init>(NameNotProvidedException.groovy:8) at javaposse.jobdsl.dsl.AbstractJobManagement.validateNameArg(AbstractJobManagement.java:67) at javaposse.jobdsl.dsl.AbstractJobManagement.validateUpdateArgs(AbstractJobManagement.java:58) at javaposse.jobdsl.plugin.JenkinsJobManagement.createOrUpdateConfig(JenkinsJobManagement.java:99) at javaposse.jobdsl.dsl.DslScriptLoader.extractGeneratedJobs(DslScriptLoader.java:122) at javaposse.jobdsl.dsl.DslScriptLoader.runDslEngine(DslScriptLoader.java:98) at javaposse.jobdsl.plugin.ExecuteDslScripts.perform(ExecuteDslScripts.java:159) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:804) at hudson.model.Build$BuildExecution.build(Build.java:199) at hudson.model.Build$BuildExecution.doRun(Build.java:160) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:586) at hudson.model.Run.execute(Run.java:1575) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:241)
    via by Tianming Zhao,
  • When using job-dsl-plugin 1.22, I forgot to give the job a name, and I ended up getting error message as below. I would suggest to output a more helpful error message which, in this case, should reveal where exactly the problem was or prompt me more helpful information. As a newbie to Jenkins plugins, the following error message is very difficult for me to figure out the root cause. FATAL: the number of constructors during runtime and compile time for java.lang.RuntimeException do not match. Expected 5 but got 4 java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for java.lang.RuntimeException do not match. Expected 5 but got 4 at groovy.lang.MetaClassImpl.selectConstructorAndTransformArguments(MetaClassImpl.java:1381) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.selectConstructorAndTransformArguments(ScriptBytecodeAdapter.java:234) at javaposse.jobdsl.dsl.NameNotProvidedException.<init>(NameNotProvidedException.groovy:8) at javaposse.jobdsl.dsl.AbstractJobManagement.validateNameArg(AbstractJobManagement.java:67) at javaposse.jobdsl.dsl.AbstractJobManagement.validateUpdateArgs(AbstractJobManagement.java:58) at javaposse.jobdsl.plugin.JenkinsJobManagement.createOrUpdateConfig(JenkinsJobManagement.java:99) at javaposse.jobdsl.dsl.DslScriptLoader.extractGeneratedJobs(DslScriptLoader.java:122) at javaposse.jobdsl.dsl.DslScriptLoader.runDslEngine(DslScriptLoader.java:98) at javaposse.jobdsl.plugin.ExecuteDslScripts.perform(ExecuteDslScripts.java:159) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:804) at hudson.model.Build$BuildExecution.build(Build.java:199) at hudson.model.Build$BuildExecution.doRun(Build.java:160) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:586) at hudson.model.Run.execute(Run.java:1575) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:241)
    via by Tianming Zhao,
  • Gradle exception for cargo plugin
    via Stack Overflow by Priya
    ,
  • PyCharm 4
    via GitHub by ithamsteri
    ,
  • GitHub comment 17#92789984
    via GitHub by sudhirkhanger
    ,
    • java.lang.IncompatibleClassChangeError: the number of constructors during runtime and compile time for java.lang.RuntimeException do not match. Expected 5 but got 4 at groovy.lang.MetaClassImpl.selectConstructorAndTransformArguments(MetaClassImpl.java:1381) at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.selectConstructorAndTransformArguments(ScriptBytecodeAdapter.java:234) at javaposse.jobdsl.dsl.NameNotProvidedException.<init>(NameNotProvidedException.groovy:8) at javaposse.jobdsl.dsl.AbstractJobManagement.validateNameArg(AbstractJobManagement.java:67) at javaposse.jobdsl.dsl.AbstractJobManagement.validateUpdateArgs(AbstractJobManagement.java:58) at javaposse.jobdsl.plugin.JenkinsJobManagement.createOrUpdateConfig(JenkinsJobManagement.java:99) at javaposse.jobdsl.dsl.DslScriptLoader.extractGeneratedJobs(DslScriptLoader.java:122) at javaposse.jobdsl.dsl.DslScriptLoader.runDslEngine(DslScriptLoader.java:98) at javaposse.jobdsl.plugin.ExecuteDslScripts.perform(ExecuteDslScripts.java:159) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:804) at hudson.model.Build$BuildExecution.build(Build.java:199) at hudson.model.Build$BuildExecution.doRun(Build.java:160) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:586) at hudson.model.Run.execute(Run.java:1575) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:241)

    Users with the same issue

    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,