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

Trailing space in Git branch name causes build failures

    XMLWordPrintable

Details

    Description

      While setting up a new job, I C&P my Git branch name into the "Branch Specifier" under SCM. I didn't realize it, but there was a trailing space in the branch name. This caused the build to fail with:

      Started by user ryan.shoemaker
      Building in workspace /opt/jenkins/jobs/MyJob/workspace
      Checkout:workspace / /opt/jenkins/jobs/MyJob/workspace - hudson.remoting.LocalChannel@6c616408
      Using strategy: Default
      Wiping out workspace first.
      Cloning the remote Git repository
      Cloning repository origin
      Fetching upstream changes from ssh://ryan.shoemaker@mygitserver.com/git/MyModule
      ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job.

      When I removed the trailing space from the branch name, everything built fine.

      Attachments

        Activity

          ryanshoemaker ryan shoemaker created issue -
          sogabe sogabe made changes -
          Field Original Value New Value
          Resolution Fixed [ 1 ]
          Status Open [ 1 ] Resolved [ 5 ]
          rtyler R. Tyler Croy made changes -
          Workflow JNJira [ 145957 ] JNJira + In-Review [ 191712 ]
          markewaite Mark Waite made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

          People

            ndeloof Nicolas De Loof
            ryanshoemaker ryan shoemaker
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: