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

PR Webhook only triggered first repo while using multi SCMs

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • multiple-scms-plugin
    • None
    • Jenkins 2.346.3
      multiple-scms 0.8
      gitee 1.2.4
      os win10 x64

      I have a jenkins job using multi scms plugin, which contains many repos, repo A, repo B, repo C.

       

       

      Now I have set trigger condition to when pr is open. 

       

      When repo A opened a pr, jenkins builds fine.

      When repo B opened a pr, jenkins returns an error. It seems Jenkins still fetching code from repo A, while using repo B's pr id.

      //代码占位符
      Gitee Óû§ ÍõÕý ÍÆËÍ´¥·¢¹¹½¨
      Running as SYSTEM
      Building in workspace C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega
      The recommended git tool is: NONE
      using credential xxxxxxxxxxxxxxx
       > C:\Program Files\Git\cmd\git.exe rev-parse --resolve-git-dir C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega\IntellVega.Workbench.Startup\.git # timeout=10
      Fetching changes from the remote Git repository
       > C:\Program Files\Git\cmd\git.exe config remote.origin.url git@gitee.com:xxxxxx.git # timeout=10
      Fetching upstream changes from git@gitee.com:xxxxxx.git
       > C:\Program Files\Git\cmd\git.exe --version # timeout=10
       > git --version # 'git version 2.34.0.windows.1'
      using GIT_ASKPASS to set credentials 
       > C:\Program Files\Git\cmd\git.exe fetch --tags --force --progress -- git@gitee.com:xxxxxx.git +refs/heads/*:refs/remotes/origin/* # timeout=10
       > C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}" # timeout=10
      FATAL: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
      stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
      Use '--' to separate paths from revisions, like this:
      'git <command> [<revision>...] -- [<file>...]'hudson.plugins.git.GitException: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
      stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
      Use '--' to separate paths from revisions, like this:
      'git <command> [<revision>...] -- [<file>...]'    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2675)
          at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2605)
          at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2601)
          at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1969)
          at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1981)
          at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.revParse(CliGitAPIImpl.java:1083)
          at hudson.plugins.git.GitAPI.revParse(GitAPI.java:337)
          at hudson.plugins.git.RevisionParameterAction.toRevision(RevisionParameterAction.java:98)
          at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:1142)
          at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1309)
          at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:143)
          at hudson.scm.SCM.checkout(SCM.java:540)
          at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
          at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
          at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
          at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
          at hudson.model.Run.execute(Run.java:1897)
          at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
          at hudson.model.ResourceController.execute(ResourceController.java:101)
          at hudson.model.Executor.run(Executor.java:442)
      Sending e-mails to: rio.li@megarobo.tech wangzheng@megarobo.tech
      Finished: FAILURE
       

       

       

       

       

       

       

       

       

          [JENKINS-70618] PR Webhook only triggered first repo while using multi SCMs

          Vincent created issue -
          Vincent made changes -
          Environment Original: Jenkins 2.346.3 New: Jenkins 2.346.3
          multiple-scms 0.8
          gitee 1.2.4
          os win10 x64
          Vincent made changes -
          Description New: I have a jenkins job, which contains
          Vincent made changes -
          Attachment New: image-2023-02-14-10-05-34-431.png [ 59973 ]
          Vincent made changes -
          Description Original: I have a jenkins job, which contains New: I have a jenkins job using multi scms plugin, which contains many repos, repo A, repo B, repo C.

           

          !image-2023-02-14-10-05-34-431.png!

           

          Now I have set trigger condition to when pr is open. 

           

          When repo A opened a pr, jenkins builds fine.

          When repo B opened a pr, jenkins returns an error. It seems Jenkins still fetching code from repo A, while using repo B's pr id.
          {code:java}
          //代码占位符
          Gitee Óû§ ÍõÕý ÍÆËÍ´¥·¢¹¹½¨
          Running as SYSTEM
          Building in workspace C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega
          The recommended git tool is: NONE
          using credential a40430f9-224a-4d31-b000-1f6ecd4d1dc4
           > C:\Program Files\Git\cmd\git.exe rev-parse --resolve-git-dir C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega\IntellVega.Workbench.Startup\.git # timeout=10
          Fetching changes from the remote Git repository
           > C:\Program Files\Git\cmd\git.exe config remote.origin.url git@gitee.com:intelligent-manufacturing-xuanyuan/IntellVega.Workbench.Startup.git # timeout=10
          Fetching upstream changes from git@gitee.com:intelligent-manufacturing-xuanyuan/IntellVega.Workbench.Startup.git
           > C:\Program Files\Git\cmd\git.exe --version # timeout=10
           > git --version # 'git version 2.34.0.windows.1'
          using GIT_ASKPASS to set credentials 
           > C:\Program Files\Git\cmd\git.exe fetch --tags --force --progress -- git@gitee.com:intelligent-manufacturing-xuanyuan/IntellVega.Workbench.Startup.git +refs/heads/*:refs/remotes/origin/* # timeout=10
           > C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}" # timeout=10
          FATAL: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'hudson.plugins.git.GitException: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2675)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2605)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2601)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1969)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1981)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.revParse(CliGitAPIImpl.java:1083)
              at hudson.plugins.git.GitAPI.revParse(GitAPI.java:337)
              at hudson.plugins.git.RevisionParameterAction.toRevision(RevisionParameterAction.java:98)
              at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:1142)
              at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1309)
              at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:143)
              at hudson.scm.SCM.checkout(SCM.java:540)
              at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
              at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
              at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
              at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
              at hudson.model.Run.execute(Run.java:1897)
              at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
              at hudson.model.ResourceController.execute(ResourceController.java:101)
              at hudson.model.Executor.run(Executor.java:442)
          Sending e-mails to: rio.li@megarobo.tech wangzheng@megarobo.tech
          Finished: FAILURE
           {code}
           

           

           

           

           

           

           

           
          Vincent made changes -
          Description Original: I have a jenkins job using multi scms plugin, which contains many repos, repo A, repo B, repo C.

           

          !image-2023-02-14-10-05-34-431.png!

           

          Now I have set trigger condition to when pr is open. 

           

          When repo A opened a pr, jenkins builds fine.

          When repo B opened a pr, jenkins returns an error. It seems Jenkins still fetching code from repo A, while using repo B's pr id.
          {code:java}
          //代码占位符
          Gitee Óû§ ÍõÕý ÍÆËÍ´¥·¢¹¹½¨
          Running as SYSTEM
          Building in workspace C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega
          The recommended git tool is: NONE
          using credential a40430f9-224a-4d31-b000-1f6ecd4d1dc4
           > C:\Program Files\Git\cmd\git.exe rev-parse --resolve-git-dir C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega\IntellVega.Workbench.Startup\.git # timeout=10
          Fetching changes from the remote Git repository
           > C:\Program Files\Git\cmd\git.exe config remote.origin.url git@gitee.com:intelligent-manufacturing-xuanyuan/IntellVega.Workbench.Startup.git # timeout=10
          Fetching upstream changes from git@gitee.com:intelligent-manufacturing-xuanyuan/IntellVega.Workbench.Startup.git
           > C:\Program Files\Git\cmd\git.exe --version # timeout=10
           > git --version # 'git version 2.34.0.windows.1'
          using GIT_ASKPASS to set credentials 
           > C:\Program Files\Git\cmd\git.exe fetch --tags --force --progress -- git@gitee.com:intelligent-manufacturing-xuanyuan/IntellVega.Workbench.Startup.git +refs/heads/*:refs/remotes/origin/* # timeout=10
           > C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}" # timeout=10
          FATAL: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'hudson.plugins.git.GitException: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2675)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2605)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2601)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1969)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1981)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.revParse(CliGitAPIImpl.java:1083)
              at hudson.plugins.git.GitAPI.revParse(GitAPI.java:337)
              at hudson.plugins.git.RevisionParameterAction.toRevision(RevisionParameterAction.java:98)
              at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:1142)
              at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1309)
              at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:143)
              at hudson.scm.SCM.checkout(SCM.java:540)
              at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
              at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
              at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
              at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
              at hudson.model.Run.execute(Run.java:1897)
              at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
              at hudson.model.ResourceController.execute(ResourceController.java:101)
              at hudson.model.Executor.run(Executor.java:442)
          Sending e-mails to: rio.li@megarobo.tech wangzheng@megarobo.tech
          Finished: FAILURE
           {code}
           

           

           

           

           

           

           

           
          New: I have a jenkins job using multi scms plugin, which contains many repos, repo A, repo B, repo C.

           

          !image-2023-02-14-10-05-34-431.png!

           

          Now I have set trigger condition to when pr is open. 

           

          When repo A opened a pr, jenkins builds fine.

          When repo B opened a pr, jenkins returns an error. It seems Jenkins still fetching code from repo A, while using repo B's pr id.
          {code:java}
          //代码占位符
          Gitee Óû§ ÍõÕý ÍÆËÍ´¥·¢¹¹½¨
          Running as SYSTEM
          Building in workspace C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega
          The recommended git tool is: NONE
          using credential xxxxxxxxxxxxxxx
           > C:\Program Files\Git\cmd\git.exe rev-parse --resolve-git-dir C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega\IntellVega.Workbench.Startup\.git # timeout=10
          Fetching changes from the remote Git repository
           > C:\Program Files\Git\cmd\git.exe config remote.origin.url git@gitee.com:xxxxxx.git # timeout=10
          Fetching upstream changes from git@gitee.com:xxxxxx.git
           > C:\Program Files\Git\cmd\git.exe --version # timeout=10
           > git --version # 'git version 2.34.0.windows.1'
          using GIT_ASKPASS to set credentials 
           > C:\Program Files\Git\cmd\git.exe fetch --tags --force --progress -- git@gitee.com:xxxxxx.git +refs/heads/*:refs/remotes/origin/* # timeout=10
           > C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}" # timeout=10
          FATAL: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'hudson.plugins.git.GitException: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2675)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2605)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2601)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1969)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1981)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.revParse(CliGitAPIImpl.java:1083)
              at hudson.plugins.git.GitAPI.revParse(GitAPI.java:337)
              at hudson.plugins.git.RevisionParameterAction.toRevision(RevisionParameterAction.java:98)
              at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:1142)
              at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1309)
              at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:143)
              at hudson.scm.SCM.checkout(SCM.java:540)
              at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
              at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
              at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
              at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
              at hudson.model.Run.execute(Run.java:1897)
              at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
              at hudson.model.ResourceController.execute(ResourceController.java:101)
              at hudson.model.Executor.run(Executor.java:442)
          Sending e-mails to: rio.li@megarobo.tech wangzheng@megarobo.tech
          Finished: FAILURE
           {code}
           

           

           

           

           

           

           

           
          Vincent made changes -
          Description Original: I have a jenkins job using multi scms plugin, which contains many repos, repo A, repo B, repo C.

           

          !image-2023-02-14-10-05-34-431.png!

           

          Now I have set trigger condition to when pr is open. 

           

          When repo A opened a pr, jenkins builds fine.

          When repo B opened a pr, jenkins returns an error. It seems Jenkins still fetching code from repo A, while using repo B's pr id.
          {code:java}
          //代码占位符
          Gitee Óû§ ÍõÕý ÍÆËÍ´¥·¢¹¹½¨
          Running as SYSTEM
          Building in workspace C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega
          The recommended git tool is: NONE
          using credential xxxxxxxxxxxxxxx
           > C:\Program Files\Git\cmd\git.exe rev-parse --resolve-git-dir C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega\IntellVega.Workbench.Startup\.git # timeout=10
          Fetching changes from the remote Git repository
           > C:\Program Files\Git\cmd\git.exe config remote.origin.url git@gitee.com:xxxxxx.git # timeout=10
          Fetching upstream changes from git@gitee.com:xxxxxx.git
           > C:\Program Files\Git\cmd\git.exe --version # timeout=10
           > git --version # 'git version 2.34.0.windows.1'
          using GIT_ASKPASS to set credentials 
           > C:\Program Files\Git\cmd\git.exe fetch --tags --force --progress -- git@gitee.com:xxxxxx.git +refs/heads/*:refs/remotes/origin/* # timeout=10
           > C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}" # timeout=10
          FATAL: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'hudson.plugins.git.GitException: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2675)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2605)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2601)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1969)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1981)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.revParse(CliGitAPIImpl.java:1083)
              at hudson.plugins.git.GitAPI.revParse(GitAPI.java:337)
              at hudson.plugins.git.RevisionParameterAction.toRevision(RevisionParameterAction.java:98)
              at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:1142)
              at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1309)
              at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:143)
              at hudson.scm.SCM.checkout(SCM.java:540)
              at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
              at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
              at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
              at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
              at hudson.model.Run.execute(Run.java:1897)
              at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
              at hudson.model.ResourceController.execute(ResourceController.java:101)
              at hudson.model.Executor.run(Executor.java:442)
          Sending e-mails to: rio.li@megarobo.tech wangzheng@megarobo.tech
          Finished: FAILURE
           {code}
           

           

           

           

           

           

           

           
          New: I have a jenkins job using multi scms plugin, which contains many repos, repo A, repo B, repo C.

           

          !image-2023-02-14-10-05-34-431.png|width=565,height=283!

           

          Now I have set trigger condition to when pr is open. 

           

          When repo A opened a pr, jenkins builds fine.

          When repo B opened a pr, jenkins returns an error. It seems Jenkins still fetching code from repo A, while using repo B's pr id.
          {code:java}
          //代码占位符
          Gitee Óû§ ÍõÕý ÍÆËÍ´¥·¢¹¹½¨
          Running as SYSTEM
          Building in workspace C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega
          The recommended git tool is: NONE
          using credential xxxxxxxxxxxxxxx
           > C:\Program Files\Git\cmd\git.exe rev-parse --resolve-git-dir C:\ProgramData\Jenkins\.jenkins\workspace\IntellVega\IntellVega.Workbench.Startup\.git # timeout=10
          Fetching changes from the remote Git repository
           > C:\Program Files\Git\cmd\git.exe config remote.origin.url git@gitee.com:xxxxxx.git # timeout=10
          Fetching upstream changes from git@gitee.com:xxxxxx.git
           > C:\Program Files\Git\cmd\git.exe --version # timeout=10
           > git --version # 'git version 2.34.0.windows.1'
          using GIT_ASKPASS to set credentials 
           > C:\Program Files\Git\cmd\git.exe fetch --tags --force --progress -- git@gitee.com:xxxxxx.git +refs/heads/*:refs/remotes/origin/* # timeout=10
           > C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}" # timeout=10
          FATAL: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'hudson.plugins.git.GitException: Command "C:\Program Files\Git\cmd\git.exe rev-parse "remotes/origin/auto-9211739-master-a040bbad^{commit}"" returned status code 128:
          stdout: remotes/origin/auto-9211739-master-a040bbad^{commit}stderr: fatal: ambiguous argument 'remotes/origin/auto-9211739-master-a040bbad^{commit}': unknown revision or path not in the working tree.
          Use '--' to separate paths from revisions, like this:
          'git <command> [<revision>...] -- [<file>...]'    at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2675)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2605)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:2601)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1969)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:1981)
              at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.revParse(CliGitAPIImpl.java:1083)
              at hudson.plugins.git.GitAPI.revParse(GitAPI.java:337)
              at hudson.plugins.git.RevisionParameterAction.toRevision(RevisionParameterAction.java:98)
              at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:1142)
              at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1309)
              at org.jenkinsci.plugins.multiplescms.MultiSCM.checkout(MultiSCM.java:143)
              at hudson.scm.SCM.checkout(SCM.java:540)
              at hudson.model.AbstractProject.checkout(AbstractProject.java:1217)
              at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:647)
              at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:85)
              at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:519)
              at hudson.model.Run.execute(Run.java:1897)
              at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44)
              at hudson.model.ResourceController.execute(ResourceController.java:101)
              at hudson.model.Executor.run(Executor.java:442)
          Sending e-mails to: rio.li@megarobo.tech wangzheng@megarobo.tech
          Finished: FAILURE
           {code}
           

           

           

           

           

           

           

           

            jimklimov Jim Klimov
            hupo376787 Vincent
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: