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

Autofavouriting breaks first build of a new job/branch

    Details

    • Similar Issues:
    • Epic Link:

      Description

      When a new branch is discovered by multibranch, it fails due to a missing commit (which is actually there in github). Re-running the build subsequently fixes this.

      The stack trace should be informative (this is from the job: https://ci.blueocean.io/job/blueocean/job/bug%252FJENKINS-39627-buttonbarlayout/1/console):

      GitHub has been notified of this commit’s build result
      
      hudson.plugins.git.GitException: org.eclipse.jgit.errors.MissingObjectException: Missing commit afbbb05dc881da89e63c5901e94f333deaeaf020
      	at org.jenkinsci.plugins.gitclient.JGitAPIImpl$4.includes(JGitAPIImpl.java:1020)
      	at io.jenkins.blueocean.autofavorite.FavoritingScmListener.onCheckout(FavoritingScmListener.java:58)
      	at org.jenkinsci.plugins.workflow.steps.scm.SCMStep.checkout(SCMStep.java:123)
      	at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:83)
      	at org.jenkinsci.plugins.workflow.steps.scm.SCMStep$StepExecutionImpl.run(SCMStep.java:73)
      	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:52)
      	at hudson.security.ACL.impersonate(ACL.java:213)
      	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:49)
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:745)
      Caused by: org.eclipse.jgit.errors.MissingObjectException: Missing commit afbbb05dc881da89e63c5901e94f333deaeaf020
      	at org.eclipse.jgit.internal.storage.file.WindowCursor.open(WindowCursor.java:159)
      	at org.eclipse.jgit.revwalk.RevWalk.getCachedBytes(RevWalk.java:903)
      	at org.eclipse.jgit.revwalk.RevCommit.parseHeaders(RevCommit.java:155)
      	at org.eclipse.jgit.revwalk.RevWalk.markStart(RevWalk.java:293)
      	at org.jenkinsci.plugins.gitclient.JGitAPIImpl$4.includes(JGitAPIImpl.java:1016)
      	... 12 more
      Finished: FAILURE
      

      Yay for dogfooding for picking this up

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jamesdumay James Dumay
                Reporter:
                michaelneale Michael Neale
              • Votes:
                1 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: