-
Bug
-
Resolution: Won't Fix
-
Major
-
None
After upgrading to a newer version of the git plugin I would get this on existing projects:
No change to record in branch origin/master
FATAL: null
java.lang.NullPointerException
at hudson.plugins.git.util.BuildData.saveBuild(BuildData.java:75)
at hudson.plugins.git.util.BuildChooser.revisionBuilt(BuildChooser.java:184)
at hudson.plugins.git.GitSCM$4.invoke(GitSCM.java:646)
at hudson.plugins.git.GitSCM$4.invoke(GitSCM.java:577)
at hudson.FilePath.act(FilePath.java:676)
at hudson.FilePath.act(FilePath.java:660)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:577)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1005)
at hudson.model.AbstractBuild$AbstractRunner.checkout(AbstractBuild.java:486)
at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:412)
at hudson.model.Run.run(Run.java:1179)
at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:304)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:122)
After a little hunting I think this is due to changes in src/main/java/hudson/plugins/git/util/BuildData.java (rev: 0f56dae4) which the name of the last build ID field was changed and so when loading up the old object buildsByBranchName is left as null and hence generates this NPE.