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

NoSuchMethodError: hudson.scm.SubversionSCM.getLocations

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • svn-revert-plugin
    • None
    • Jenkins 1.643
      Subversion Plugin 2.5.6
      Subversion Revert Plugin 1.3

      I was testing this plugin's capabilities. I configured a build that always returns unstable, just to see what happens. Except, the revert plugin throws an exception immediately.

      ERROR: Step ‘Reverts commits that breaks the build’ aborted due to exception: 
      java.lang.NoSuchMethodError: hudson.scm.SubversionSCM.getLocations(Lhudson/EnvVars;Lhudson/model/AbstractBuild;)[Lhudson/scm/SubversionSCM$ModuleLocation;
      	at jenkins.plugins.svn_revert.ModuleFinder.getModules(ModuleFinder.java:29)
      	at jenkins.plugins.svn_revert.ChangeLocator.changedFilesMatchesModules(ChangeLocator.java:37)
      	at jenkins.plugins.svn_revert.ChangeLocator.changesOutsideWorkspace(ChangeLocator.java:29)
      	at jenkins.plugins.svn_revert.Bouncer.throwOutIfUnstable(Bouncer.java:46)
      	at jenkins.plugins.svn_revert.JenkinsGlue.perform(JenkinsGlue.java:52)
      	at hudson.tasks.BuildStepMonitor$3.perform(BuildStepMonitor.java:45)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:782)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:723)
      	at hudson.model.Build$BuildExecution.post2(Build.java:185)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:668)
      	at hudson.model.Run.execute(Run.java:1763)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:410)
      

      I looked at the call site from the revert plugin

      subversionScm.getLocations(envVars, build)
      

      And the method and type signature match in the Subversion plugin classes.

      public ModuleLocation[] getLocations(EnvVars env, Run<?,?> build)
      

      I also checked that an AbstractBuild is a type of a Run, so that should be fine, right?

            Unassigned Unassigned
            anthonymastrean Anthony Mastrean
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: