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

Branch scanning fails when PR refer to a deleted fork

    Details

    • Similar Issues:

      Description

      Hi!

      I noticed that, when scanning a repository, when the source fork of a pull request have been deleted the scan fails:

      Checking pull request #5146
      ERROR: [Fri Jan 20 10:07:04 CET 2017] Could not fetch branches from source org.jenkinsci.plugins.github_branch_source.GitHubSCMNavigator::https://api.github.com::xxx::xxx
      java.lang.NullPointerException
      	at org.jenkinsci.plugins.github_branch_source.GitHubSCMSource.doRetrieve(GitHubSCMSource.java:553)
      	at org.jenkinsci.plugins.github_branch_source.GitHubSCMSource.retrieve(GitHubSCMSource.java:433)
      	at jenkins.scm.api.SCMSource._retrieve(SCMSource.java:300)
      	at jenkins.scm.api.SCMSource.fetch(SCMSource.java:210)
      	at jenkins.branch.MultiBranchProject.computeChildren(MultiBranchProject.java:516)
      	at com.cloudbees.hudson.plugins.folder.computed.ComputedFolder.updateChildren(ComputedFolder.java:187)
      	at com.cloudbees.hudson.plugins.folder.computed.FolderComputation.run(FolderComputation.java:139)
      	at jenkins.branch.MultiBranchProject$BranchIndexing.run(MultiBranchProject.java:874)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:404)
      [Fri Jan 20 10:07:04 CET 2017] Finished branch indexing. Indexing took 18 sec
      FATAL: Failed to recompute children of Xxxxx ยป xxxxxx
      java.lang.NullPointerException
      	at org.jenkinsci.plugins.github_branch_source.GitHubSCMSource.doRetrieve(GitHubSCMSource.java:553)
      	at org.jenkinsci.plugins.github_branch_source.GitHubSCMSource.retrieve(GitHubSCMSource.java:433)
      	at jenkins.scm.api.SCMSource._retrieve(SCMSource.java:300)
      	at jenkins.scm.api.SCMSource.fetch(SCMSource.java:210)
      	at jenkins.branch.MultiBranchProject.computeChildren(MultiBranchProject.java:516)
      	at com.cloudbees.hudson.plugins.folder.computed.ComputedFolder.updateChildren(ComputedFolder.java:187)
      	at com.cloudbees.hudson.plugins.folder.computed.FolderComputation.run(FolderComputation.java:139)
      	at jenkins.branch.MultiBranchProject$BranchIndexing.run(MultiBranchProject.java:874)
      	at hudson.model.ResourceController.execute(ResourceController.java:98)
      	at hudson.model.Executor.run(Executor.java:404)
      Finished: FAILURE
      

      Could it be possible to skip those pull requests ? The best would be to be able to build a temporary branch and apply the patch provided by github but any workaround would be appreciated

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                stephenconnolly Stephen Connolly
                Reporter:
                clementgautier Clement Gautier
              • Votes:
                3 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: