Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-71003

java.lang.NoSuchMethodError mightBePositionalArgumentConstructor

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Critical Critical
    • workflow-cps-plugin
    • None

      Cannot run any scripted pipeline builds.

      Background:

      • Trying to upgrade our jenkins server from 2.319.2 --> 2.387.2
      • The upgrade process is now scripted in terraform so I can re-run and destroy it without impacting our current 2.319.2 server.  I'm re-working this script until it runs cleanly.
      • The upgraded jenkins instance was working well with some minor issues I was working through... until yesterday when this exception popped up around the moment when the 2.387.2 release came out.

      Things I tried

      • Downgrading to 2.387.1 which was working before with the latest plugins installed - same issue. 

      The exception:

      java.lang.NoSuchMethodError: 'boolean org.kohsuke.groovy.sandbox.SandboxTransformer.mightBePositionalArgumentConstructor(org.codehaus.groovy.ast.expr.VariableExpression)'
          at com.cloudbees.groovy.cps.SandboxCpsTransformer.visitAssignmentOrCast(SandboxCpsTransformer.java:93)
          at com.cloudbees.groovy.cps.CpsTransformer$42.run(CpsTransformer.java:1171)
          at com.cloudbees.groovy.cps.CpsTransformer.makeChildren(CpsTransformer.java:446)
          at com.cloudbees.groovy.cps.CpsTransformer.makeNode(CpsTransformer.java:409)
          at com.cloudbees.groovy.cps.CpsTransformer.visitDeclarationExpression(CpsTransformer.java:1164)
          at org.codehaus.groovy.ast.expr.DeclarationExpression.visit(DeclarationExpression.java:89)
          at com.cloudbees.groovy.cps.CpsTransformer.visit(CpsTransformer.java:357)
          at com.cloudbees.groovy.cps.CpsTransformer.visitExpressionStatement(CpsTransformer.java:589)
          at org.codehaus.groovy.ast.stmt.ExpressionStatement.visit(ExpressionStatement.java:42)
          at com.cloudbees.groovy.cps.CpsTransformer.visit(CpsTransformer.java:357)
          at com.cloudbees.groovy.cps.CpsTransformer.visit(CpsTransformer.java:363)
          at com.cloudbees.groovy.cps.CpsTransformer$5.run(CpsTransformer.java:515)
          at com.cloudbees.groovy.cps.CpsTransformer.makeChildren(CpsTransformer.java:446)
          at com.cloudbees.groovy.cps.CpsTransformer.makeNode(CpsTransformer.java:409)
          at com.cloudbees.groovy.cps.CpsTransformer.visitBlockStatement(CpsTransformer.java:512)
          at org.codehaus.groovy.ast.stmt.BlockStatement.visit(BlockStatement.java:71)
          at com.cloudbees.groovy.cps.CpsTransformer.visit(CpsTransformer.java:357)
          at com.cloudbees.groovy.cps.CpsTransformer$2.run(CpsTransformer.java:388)
          at com.cloudbees.groovy.cps.CpsTransformer.makeChildren(CpsTransformer.java:446)
          at com.cloudbees.groovy.cps.CpsTransformer.makeNode(CpsTransformer.java:409)
          at com.cloudbees.groovy.cps.CpsTransformer.visitWithSafepoint(CpsTransformer.java:374)
          at com.cloudbees.groovy.cps.CpsTransformer.visitMethod(CpsTransformer.java:231)
          at com.cloudbees.groovy.cps.SandboxCpsTransformer.visitMethod(SandboxCpsTransformer.java:73)
          at com.cloudbees.groovy.cps.CpsTransformer.call(CpsTransformer.java:136)
          at com.cloudbees.groovy.cps.SandboxCpsTransformer.call(SandboxCpsTransformer.java:29)
          at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1087)
          at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:624)
          at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:602)
          at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:579)
          at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:323)
          at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:293)
          at groovy.lang.GroovyShell.parseClass(GroovyShell.java:677)
          at groovy.lang.GroovyShell.parse(GroovyShell.java:689)
          at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.doParse(CpsGroovyShell.java:142)
          at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.reparse(CpsGroovyShell.java:127)
          at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.parseScript(CpsFlowExecution.java:572)
          at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.start(CpsFlowExecution.java:524)
          at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:334)
          at hudson.model.ResourceController.execute(ResourceController.java:101)
          at hudson.model.Executor.run(Executor.java:442)

      GitHub has been notified of this commit's build result

      Finished: FAILURE

            Unassigned Unassigned
            mkelandis Michael
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: