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

Checkout fails with ERROR: Could not determine exact tip revision of <branch>

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • None
    • Jenkins v2.225
      Gerrit Code Review plugin v0.4.1
    • gerrit-code-review-0.4.5

      Short explanation

      Creating Multibranch Pipelines using Gerrit as Branch Source through the UI causes the error to occur. The error is that for every new Change Request, the first build (and automatic) occurs with no problem, but if you hit Build Now to build a second, it fails with the error stated. 

      This error doesn't happen if you use Jenkins Job Builder or Job DSL to create the Multibranch pipeline, only when created by the UI.

      Long explanation

      The issue is the same as the others linked (and closed) but happens using the Gerrit Code Review plugin. Seems like a fix was applied for BlueOcean, Github, Jervis, but I suppose this must also be fixed here. 

      Every time I push a new change for review, the first build of that patchset works. But if you hit Build now on that change, the build fails. 

      The error is:

      ERROR: Could not determine exact tip revision of 01/7002801/3

      A picture of the pipeline:

          [JENKINS-61469] Checkout fails with ERROR: Could not determine exact tip revision of <branch>

          Felipe Santos created issue -
          Felipe Santos made changes -
          Link New: This issue is related to JENKINS-48571 [ JENKINS-48571 ]

          Matt Story added a comment -

          I run into this issue when triggering a multibranch plugin job from another multibranch plugin job with 'build job: ...'.  When I build the job manually it works fine.

          Jenkins v2.202

          GCR plugin version unknown since I don't have 'Manage Jenkins' privs.

          Gerrit v3.0.2

          Matt Story added a comment - I run into this issue when triggering a multibranch plugin job from another multibranch plugin job with 'build job: ...'.  When I build the job manually it works fine. Jenkins v2.202 GCR plugin version unknown since I don't have 'Manage Jenkins' privs. Gerrit v3.0.2
          Felipe Santos made changes -
          Description Original: Hi,

          I'm experiencing this issue in one of my projects, using this plugin.

           

          The issue is the same as the others linked (and closed) but happens using the Gerrit Code Review plugin. Seems like a fix was applied for BlueOcean, Github, Jervis, but I suppose this must also be fixed here. 

          Every time I push a new change for review, the first build of that patchset works. But if you hit Build now on that change, the build fails. 

          The error is:
          ```log
          ERROR: Could not determine exact tip revision of 01/7002801/3
          ```

          !image-2020-03-13-10-08-19-925.png!
          New: Hi,

          I'm experiencing this issue in one of my projects, using this plugin.

           

          The issue is the same as the others linked (and closed) but happens using the Gerrit Code Review plugin. Seems like a fix was applied for BlueOcean, Github, Jervis, but I suppose this must also be fixed here. 

          Every time I push a new change for review, the first build of that patchset works. But if you hit Build now on that change, the build fails. 

          The error is:
          {code:java}
          ERROR: Could not determine exact tip revision of 01/7002801/3{code}
          A picture of the pipeline:

          !image-2020-03-13-10-08-19-925.png!

          Felipe Santos added a comment -

          There are two workarounds

          1. Use Jenkins Job Builder to create the Multibranch Pipeline on Jenkins 
              How-to: https://jenkins-job-builder.readthedocs.io/en/latest/project_workflow_multibranch.html#project_multibranch.gerrit_scm
          2. Use Job DSL to create the Multibranch Pipeline on Jenkins

          Felipe Santos added a comment - There are two workarounds 1. Use Jenkins Job Builder to create the Multibranch Pipeline on Jenkins      How-to:  https://jenkins-job-builder.readthedocs.io/en/latest/project_workflow_multibranch.html#project_multibranch.gerrit_scm 2. Use Job DSL to create the Multibranch Pipeline on Jenkins
          Felipe Santos made changes -
          Description Original: Hi,

          I'm experiencing this issue in one of my projects, using this plugin.

           

          The issue is the same as the others linked (and closed) but happens using the Gerrit Code Review plugin. Seems like a fix was applied for BlueOcean, Github, Jervis, but I suppose this must also be fixed here. 

          Every time I push a new change for review, the first build of that patchset works. But if you hit Build now on that change, the build fails. 

          The error is:
          {code:java}
          ERROR: Could not determine exact tip revision of 01/7002801/3{code}
          A picture of the pipeline:

          !image-2020-03-13-10-08-19-925.png!
          New: ## Short explanation:

          Creating Multibranch Pipelines using Gerrit as Branch Source through the UI causes the error to occur. The error is that for every new Change Request, the first build (and automatic) occurs with no problem, but if you hit Build Now to build a second, it fails with the error stated. 

          This error doesn't happen if you use Jenkins Job Builder or Job DSL to create the Multibranch pipeline, only when created by the UI.


          ## Long explanation:

          The issue is the same as the others linked (and closed) but happens using the Gerrit Code Review plugin. Seems like a fix was applied for BlueOcean, Github, Jervis, but I suppose this must also be fixed here. 

          Every time I push a new change for review, the first build of that patchset works. But if you hit Build now on that change, the build fails. 

          The error is:
          {code:java}
          ERROR: Could not determine exact tip revision of 01/7002801/3{code}
          A picture of the pipeline:

          !image-2020-03-13-10-08-19-925.png!
          Felipe Santos made changes -
          Description Original: ## Short explanation:

          Creating Multibranch Pipelines using Gerrit as Branch Source through the UI causes the error to occur. The error is that for every new Change Request, the first build (and automatic) occurs with no problem, but if you hit Build Now to build a second, it fails with the error stated. 

          This error doesn't happen if you use Jenkins Job Builder or Job DSL to create the Multibranch pipeline, only when created by the UI.


          ## Long explanation:

          The issue is the same as the others linked (and closed) but happens using the Gerrit Code Review plugin. Seems like a fix was applied for BlueOcean, Github, Jervis, but I suppose this must also be fixed here. 

          Every time I push a new change for review, the first build of that patchset works. But if you hit Build now on that change, the build fails. 

          The error is:
          {code:java}
          ERROR: Could not determine exact tip revision of 01/7002801/3{code}
          A picture of the pipeline:

          !image-2020-03-13-10-08-19-925.png!
          New: h2. Short explanation

          Creating Multibranch Pipelines using Gerrit as Branch Source through the UI causes the error to occur. The error is that for every new Change Request, the first build (and automatic) occurs with no problem, but if you hit Build Now to build a second, it fails with the error stated. 

          This error doesn't happen if you use Jenkins Job Builder or Job DSL to create the Multibranch pipeline, only when created by the UI.
          h2. Long explanation

          The issue is the same as the others linked (and closed) but happens using the Gerrit Code Review plugin. Seems like a fix was applied for BlueOcean, Github, Jervis, but I suppose this must also be fixed here. 

          Every time I push a new change for review, the first build of that patchset works. But if you hit Build now on that change, the build fails. 

          The error is:
          {code:java}
          ERROR: Could not determine exact tip revision of 01/7002801/3{code}
          A picture of the pipeline:

          !image-2020-03-13-10-08-19-925.png!
          Felipe Santos made changes -
          Environment Original: Jenkins v2.225
          Gerrit Code Review plugin v0.4.1
          Gerrit v2.14
          New: Jenkins v2.225
          Gerrit Code Review plugin v0.4.1
          Felipe Santos made changes -
          Link New: This issue is related to JENKINS-49610 [ JENKINS-49610 ]

          Looks like we have to configure the refspec `+refs/changes/*:refs/remotes/@

          {remote}

          /*` to fix this issue. I will investigate further. If this turns out to be a reproducible fix, I will upload a change, making this the default.

          Thomas Draebing added a comment - Looks like we have to configure the refspec `+refs/changes/*:refs/remotes/@ {remote} /*` to fix this issue. I will investigate further. If this turns out to be a reproducible fix, I will upload a change, making this the default.

            lucamilanesio Luca Domenico Milanesio
            felipecassiors Felipe Santos
            Votes:
            1 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: