Scan of git pipeline fails with NPE due to recent GitSCMSource change

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: Blocker
    • Component/s: git-plugin
    • Environment:
      Docker instance as described later in bug report, including unreleased version of git plugin

      Initial scan of branches in a multi-branch-project fails with a null pointer exception. It seems to be due to the addition of GitSCMSource: support custom remote and refspec.

      Steps to duplicate the problem:

      1. Clone, build, and run the docker instance
          $ git lfs clone https://github.com/MarkEWaite/docker-lfs JENKINS-42204
          $ cd JENKINS-42204
          $ git lfs fetch origin 4bd3aba9910323f8bc279ad5bd7ac3ae8d5ffd5f
          $ git checkout -b lts-with-plugins 4bd3aba9910323f8bc279ad5bd7ac3ae8d5ffd5f
          $ docker build -t jenkins:JENKINS-42204 .
          $ docker run -i --rm --publish 8080:8080 jenkins:JENKINS-42204
        
      2. Connect a web browser to that docker instance (http://localhost:8080)
      3. Open the "Bugs - Pipeline Checks"
      4. Open the "jenkins-bugs" multi-branch pipeline job
      5. Click the "Scan Multibranch Pipeline" link and then the "Run Now" link to start branch indexing
      6. Click the "Log" link to view the log - stack trace will appear in that log

      If I revert the commit for GitSCMSource: support custom remote and refspec, the problem no longer appears. Refer to PR466 for more details.

            Assignee:
            jbq
            Reporter:
            Mark Waite
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: