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

Saving to Github/GHE requires email with user or it fails

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • blueocean-plugin
    • None
    • Blue Ocean 1.4 - beta 3, Blue Ocean 1.5 - beta 2

      In Scope

      • If there is no email address available, use $jenkinsUsername@email-address-not-set

      Original request
      A pipeline created with BlueOcean 1.3.3 (from docker image) and repository GHE, won't be saved if you use default admin user without any other data (specifically, no email address).

      Ideally this would either not be required, or notify the user they need to set an email for the admin (default) user. I think this is only a problem with github enterprise (github.com would always have an email associated I believe, and there is no default user). 

       

      A 500 error will be returned during the PUT request:

      java.lang.IllegalArgumentException: E-mail address of PersonIdent must not be null.
          at org.eclipse.jgit.lib.PersonIdent.<init>(PersonIdent.java:279)
          at org.eclipse.jgit.lib.PersonIdent.<init>(PersonIdent.java:229)
          at io.jenkins.blueocean.blueocean_git_pipeline.GitUtils.buildPersonIdent(GitUtils.java:369)
          at io.jenkins.blueocean.blueocean_git_pipeline.GitUtils.commit(GitUtils.java:311)
          at io.jenkins.blueocean.blueocean_git_pipeline.GitBareRepoReadSaveRequest$2.invoke(GitBareRepoReadSaveRequest.java:90)
          at io.jenkins.blueocean.blueocean_git_pipeline.GitBareRepoReadSaveRequest$2.invoke(GitBareRepoReadSaveRequest.java:71)
          at jenkins.plugins.git.GitSCMFileSystem$3.invoke(GitSCMFileSystem.java:193)
          at org.jenkinsci.plugins.gitclient.AbstractGitAPIImpl.withRepository(AbstractGitAPIImpl.java:29)
          at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.withRepository(CliGitAPIImpl.java:71)
          at jenkins.plugins.git.GitSCMFileSystem.invoke(GitSCMFileSystem.java:189)
          at io.jenkins.blueocean.blueocean_git_pipeline.GitCacheCloneReadSaveRequest.invokeOnScm(GitCacheCloneReadSaveRequest.java:149)
          at io.jenkins.blueocean.blueocean_git_pipeline.GitBareRepoReadSaveRequest.save(GitBareRepoReadSaveRequest.java:71)
          at 
      

      The issue can be workarounded by adding the email to admin user.

            imeredith Ivan Meredith
            michaelneale Michael Neale
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: