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

Couldn't find any revision to build for PR build

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None

      After updating to version 4.1.2, on one of our pipelines we have begun seeing an error
      ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job.
      At this point to our knowledge it is only happening on this specific pipeline, which does do some things differently than our other pipelines so I will do my best to describe how it is configured.

      This pipeline is configured with the following behaviors 

      The main differences here compared to most of our other pipelines is the checkout timeout and Git LFS usage. The other key difference is that this pipeline is configured to skip the default checkout and does its checkout using a checkout step using the GitSCM class, configured as such

      checkout([
                  $class: 'GitSCM',
                  branches: scm.branches,
                  doGenerateSubmoduleConfigurations: false,
                  extensions: [
                      [$class: 'CloneOption', depth: 50, noTags: false, shallow: true],
                      [$class: 'GitLFSPull']
                  ],
                  submoduleCfg: [],
                  userRemoteConfigs: scm.userRemoteConfigs
              ]) 

       

          [JENKINS-75088] Couldn't find any revision to build for PR build

          Hello butter1484 
          Could you share a bit more? Could you share build logs so we can see what is happening? What version of Bitbucket are you connecting to? What version did you upgrade from? Does opening and saving the pipeline (in Jenkins) make a difference? We need a bit more information to be able to start tracking this down. If you are unable to share the requested information publicly via the issue tracker but would be happy to share it directly with me, I'm happy for you to send me the information in a direct e-mail to me.

          Daniel Kjellin added a comment - Hello butter1484   Could you share a bit more? Could you share build logs so we can see what is happening? What version of Bitbucket are you connecting to? What version did you upgrade from? Does opening and saving the pipeline (in Jenkins) make a difference? We need a bit more information to be able to start tracking this down. If you are unable to share the requested information publicly via the issue tracker but would be happy to share it directly with me, I'm happy for you to send me the information in a direct e-mail to me.

          Brady Shober added a comment -

          We have since downgraded and the build logs for the affected builds have dropped off due to our retention settings, but from what I recall everything looked normal up until the error 

          ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job.

          We were upgrading from version 4.0.0. I believe I did try opening and saving the pipeline configuration.

          Our Bitbucket version is 8.19.12

          Brady Shober added a comment - We have since downgraded and the build logs for the affected builds have dropped off due to our retention settings, but from what I recall everything looked normal up until the error  ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job. We were upgrading from version 4.0.0. I believe I did try opening and saving the pipeline configuration. Our Bitbucket version is 8.19.12

          Thank you butter1484 

          I'll see what I can do. I have not been able to reproduce this error (yet). Did this happen for all branches for this pipeline? Is it a multi-branch pipeline or a "pipeline"? Is the build instructions stored in a Jenkinsfile in the repository or in Jenkins itself?

          Daniel Kjellin added a comment - Thank you butter1484   I'll see what I can do. I have not been able to reproduce this error (yet). Did this happen for all branches for this pipeline? Is it a multi-branch pipeline or a "pipeline"? Is the build instructions stored in a Jenkinsfile in the repository or in Jenkins itself?

          Brady Shober added a comment -

          The issue was specifically impacting PR builds, I believe normal branch builds were still working. This is a multi branch pipeline and we keep a Jenkinsfile in the repository.

          Brady Shober added a comment - The issue was specifically impacting PR builds, I believe normal branch builds were still working. This is a multi branch pipeline and we keep a Jenkinsfile in the repository.

          Hello butter1484 
          We've tried to reproduce this issue today including an upgrade from 4.0.0, and we cannot reproduce this issue. We have a local checkout same as you have in this report and it works for us.
          Are you using slashes in the branch names? We did have issues with that, but it should have been resolved in 4.1.2. Would you be able to share your Jenkinsfile with us (or me, you can send it to me directly on dkjellin@atlassian.com )

          If/when you upgrade can you capture the log from a failed build so we can see more details about what is going on? Again you can mail it straight to me if you don't want to attach it on the issue.

          Daniel Kjellin added a comment - Hello butter1484   We've tried to reproduce this issue today including an upgrade from 4.0.0, and we cannot reproduce this issue. We have a local checkout same as you have in this report and it works for us. Are you using slashes in the branch names? We did have issues with that, but it should have been resolved in 4.1.2. Would you be able to share your Jenkinsfile with us (or me, you can send it to me directly on dkjellin@atlassian.com ) If/when you upgrade can you capture the log from a failed build so we can see more details about what is going on? Again you can mail it straight to me if you don't want to attach it on the issue.

            Unassigned Unassigned
            butter1484 Brady Shober
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: