java.lang.NullPointerException

Jenkins JIRA | bjacobse | 9 years ago
  1. 0

    P4 plugin throws a null pointer exception causing job failure when running a "p4 -s users <deleted-user>" where <deleted-user> is a once active, now deleted account. The only workaround appears to be to recreate the deleted account which consumes a Perforce license. I have verified this workaround twice with two different deleted accounts. Example failure output: Started by user cmteam Building in workspace /var/opt/jenkins-data/jobs/some-deploy/workspace Using master perforce client: ciqa-some-deploy [workspace] $ p4 workspace -o ciqa-some-deploy Saving modified client ciqa-some-deploy [workspace] $ p4 -s client -i Clearing workspace... Note: .repository directory in workspace (if exists) is skipped. Cleared workspace. Last build changeset: 79972 [workspace] $ p4 -s changes -s submitted -m 1 //ciqa-some-deploy/...@somelabel-4.1.0.0 [workspace] $ p4 -s changes -s submitted //ciqa-some-deploy/...@79973,@85075 [workspace] $ p4 describe -s 85075 [workspace] $ p4 -G where //... [workspace] $ p4 describe -s 85012 [workspace] $ p4 describe -s 85005 [workspace] $ p4 describe -s 84668 <snip> [workspace] $ p4 describe -s 81052 [workspace] $ p4 describe -s 81031 [workspace] $ p4 describe -s 81029 [workspace] $ p4 -s users valid-user-1 [workspace] $ p4 user -o valid-user-1 [workspace] $ p4 -s users valid-user-2 [workspace] $ p4 user -o valid-user-2 [workspace] $ p4 -s users deleted-user FATAL: null java.lang.NullPointerException at hudson.plugins.perforce.PerforceSCM.retrieveUserInformation(PerforceSCM.java:633) at hudson.plugins.perforce.PerforceSCM.checkout(PerforceSCM.java:816) at hudson.model.AbstractProject.checkout(AbstractProject.java:1197) at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:579) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:468) at hudson.model.Run.run(Run.java:1410) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:481) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:238) And of course the job fails at this point. Note that "p4 -s users deleted-user" returns error: deleted-user - no such user(s). exit: 0 while "p4 -s users valid-user" returns info: valid-user <valid-user@my.company.com> (Valid User) accessed 2012/03/29 exit: 0

    Jenkins JIRA | 5 years ago | S Stack
    java.lang.NullPointerException
  2. Speed up your debug routine!

    Automated exception search integrated into your IDE

  3. 0

    P4 plugin throws a null pointer exception causing job failure when running a "p4 -s users <deleted-user>" where <deleted-user> is a once active, now deleted account. The only workaround appears to be to recreate the deleted account which consumes a Perforce license. I have verified this workaround twice with two different deleted accounts. Example failure output: Started by user cmteam Building in workspace /var/opt/jenkins-data/jobs/some-deploy/workspace Using master perforce client: ciqa-some-deploy [workspace] $ p4 workspace -o ciqa-some-deploy Saving modified client ciqa-some-deploy [workspace] $ p4 -s client -i Clearing workspace... Note: .repository directory in workspace (if exists) is skipped. Cleared workspace. Last build changeset: 79972 [workspace] $ p4 -s changes -s submitted -m 1 //ciqa-some-deploy/...@somelabel-4.1.0.0 [workspace] $ p4 -s changes -s submitted //ciqa-some-deploy/...@79973,@85075 [workspace] $ p4 describe -s 85075 [workspace] $ p4 -G where //... [workspace] $ p4 describe -s 85012 [workspace] $ p4 describe -s 85005 [workspace] $ p4 describe -s 84668 <snip> [workspace] $ p4 describe -s 81052 [workspace] $ p4 describe -s 81031 [workspace] $ p4 describe -s 81029 [workspace] $ p4 -s users valid-user-1 [workspace] $ p4 user -o valid-user-1 [workspace] $ p4 -s users valid-user-2 [workspace] $ p4 user -o valid-user-2 [workspace] $ p4 -s users deleted-user FATAL: null java.lang.NullPointerException at hudson.plugins.perforce.PerforceSCM.retrieveUserInformation(PerforceSCM.java:633) at hudson.plugins.perforce.PerforceSCM.checkout(PerforceSCM.java:816) at hudson.model.AbstractProject.checkout(AbstractProject.java:1197) at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:579) at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:468) at hudson.model.Run.run(Run.java:1410) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:481) at hudson.model.ResourceController.execute(ResourceController.java:88) at hudson.model.Executor.run(Executor.java:238) And of course the job fails at this point. Note that "p4 -s users deleted-user" returns error: deleted-user - no such user(s). exit: 0 while "p4 -s users valid-user" returns info: valid-user <valid-user@my.company.com> (Valid User) accessed 2012/03/29 exit: 0

    Jenkins JIRA | 5 years ago | S Stack
    java.lang.NullPointerException
  4. 0

    Double whammy: Perforce plugin NPE and Jira failure

    Google Groups | 5 years ago | Steve Freeland
    java.lang.NullPointerException

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.NullPointerException

      No message provided

      at hudson.plugins.perforce.PerforceSCM.getLastChange()
    2. hudson.plugins.perforce
      PerforceSCM.checkout
      1. hudson.plugins.perforce.PerforceSCM.getLastChange(PerforceSCM.java:281)
      2. hudson.plugins.perforce.PerforceSCM.checkout(PerforceSCM.java:186)
      2 frames
    3. Hudson
      Run.run
      1. hudson.model.AbstractProject.checkout(AbstractProject.java:529)
      2. hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:223)
      3. hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:189)
      4. hudson.model.Run.run(Run.java:601)
      4 frames
    4. Hudson Maven Embedder
      MavenModuleSetBuild.run
      1. hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:172)
      1 frame
    5. Hudson
      Executor.run
      1. hudson.model.ResourceController.execute(ResourceController.java:70)
      2. hudson.model.Executor.run(Executor.java:62)
      2 frames