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

Workflow multibranch failed after rebase: IllegalStateException: could not find branch tip

      I rebased a branch (dev/main) in git, but the workflow-multibranch poller didn't seem to pick
      it up.

      When I retriggered, I got the following error

      Started by user anonymous
      java.lang.IllegalStateException: could not find branch tip on SCMHead{'dev/main'}
      	at org.jenkinsci.plugins.workflow.multibranch.SCMBinder.create(SCMBinder.java:91)
      	at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:183)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:381)
      Finished: FAILURE
      

          [JENKINS-30798] Workflow multibranch failed after rebase: IllegalStateException: could not find branch tip

          magnayn created issue -
          Jesse Glick made changes -
          Labels Original: multibranch workflow New: multibranch

          Jesse Glick added a comment -

          Any particular steps to reproduce? I can try to guess and might get lucky.

          Jesse Glick added a comment - Any particular steps to reproduce? I can try to guess and might get lucky.

          magnayn added a comment -

          Not sure. I may have also seen this behaviour in the non-wf multi branch, where branches seem to have just stopped building.

          I also tried re-running the branch indexing, but didn't seem to help

          magnayn added a comment - Not sure. I may have also seen this behaviour in the non-wf multi branch, where branches seem to have just stopped building. I also tried re-running the branch indexing, but didn't seem to help

          magnayn added a comment -

          Hm. Even more strange behaviour.

          I'd set the 'branches' to be "dev*, release*" - which doesn't work. So I changed it to "dev* release*" - and then when I thought a bit more to just "*".

          Now I have projects building - but I can't access their URL. E.g:
          http://jenkins.blah.com/job/rd2/

          Shows a list of branches. But clicking on one (e.g: dev-main) that's currently building goes to
          http://jenkins.blah.com/job/rd2/branch/dev-main/

          Which results in a 404 Not Found.

          magnayn added a comment - Hm. Even more strange behaviour. I'd set the 'branches' to be "dev*, release*" - which doesn't work. So I changed it to "dev* release*" - and then when I thought a bit more to just "*". Now I have projects building - but I can't access their URL. E.g: http://jenkins.blah.com/job/rd2/ Shows a list of branches. But clicking on one (e.g: dev-main) that's currently building goes to http://jenkins.blah.com/job/rd2/branch/dev-main/ Which results in a 404 Not Found.

          Jesse Glick added a comment -

          The IllegalStateException I have seen (just do not know how to reproduce from scratch yet). The 404 is something else entirely, and I have no guesses what could cause that.

          Jesse Glick added a comment - The IllegalStateException I have seen (just do not know how to reproduce from scratch yet). The 404 is something else entirely, and I have no guesses what could cause that.

          magnayn added a comment -

          Rather helpfully (for me, or unhelpfully for debugging) when I re-started the instance, the 404s went away and it started behaving as normal. :-/

          The original issue also went away - so it looks like some transient issue where manipulating what branches get build and/or rebasing one of them causes a failure that restarting recovers from.

          I will keep monitoring and try to find out if there's a trigger cause.

          magnayn added a comment - Rather helpfully (for me, or unhelpfully for debugging) when I re-started the instance, the 404s went away and it started behaving as normal. :-/ The original issue also went away - so it looks like some transient issue where manipulating what branches get build and/or rebasing one of them causes a failure that restarting recovers from. I will keep monitoring and try to find out if there's a trigger cause.

          Jesse Glick added a comment -

          Thanks, any information will be helpful.

          Jesse Glick added a comment - Thanks, any information will be helpful.
          Jesse Glick made changes -
          Summary Original: workflow multibranch failed after rebase New: Workflow multibranch failed after rebase: IllegalStateException: could not find branch tip
          Jesse Glick made changes -
          Remote Link New: This issue links to "PR 231 (Web Link)" [ 13195 ]

            recena Manuel Recena Soto
            magnayn magnayn
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: