Skip to content

[JENKINS-47530] java.lang.NullPointerException at end of successful build preventing downstream jobs #22375

Closed

Description

@jenkins-infra-bot

I have a Freestyle project job which has been working for over 40 runs but now gets the error below at the end of each build.  I have created another job copying the configuration of this one and it runs without getting the error.  This error stops the trigger of downstream jobs but doesn't appear to hurt anything in the build itself. I have not updated or installed anything recently that could account for this.

 
Archiving artifacts
FATAL: null
java.lang.NullPointerException
at hudson.model.RunParameterDefinition.getDefaultParameterValue(RunParameterDefinition.java:174)
at jenkins.model.ParameterizedJobMixIn.getDefaultParametersValues(ParameterizedJobMixIn.java:171)
at jenkins.model.ParameterizedJobMixIn.scheduleBuild2(ParameterizedJobMixIn.java:153)
at jenkins.model.ParameterizedJobMixIn.scheduleBuild2(ParameterizedJobMixIn.java:122)
at jenkins.model.ParameterizedJobMixIn$ParameterizedJob.scheduleBuild2(ParameterizedJobMixIn.java:417)
at hudson.model.AbstractProject.scheduleBuild2(AbstractProject.java:852)
at hudson.model.AbstractProject.scheduleBuild2(AbstractProject.java:824)
at hudson.model.AbstractProject.scheduleBuild2(AbstractProject.java:807)
at hudson.model.AbstractProject.scheduleBuild(AbstractProject.java:795)
at hudson.tasks.BuildTrigger.execute(BuildTrigger.java:278)
at hudson.model.AbstractBuild$AbstractBuildExecution.cleanUp(AbstractBuild.java:643)
at hudson.model.Build$BuildExecution.cleanUp(Build.java:201)
at hudson.model.Run.execute(Run.java:1784)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:97)
at hudson.model.Executor.run(Executor.java:421)
Finished: SUCCESS


Originally reported by jmckinnon, imported from: java.lang.NullPointerException at end of successful build preventing downstream jobs
  • status: Resolved
  • priority: Major
  • component(s): core
  • label(s): NullPointerException, build, jenkins, newbie-friendly
  • resolution: Fixed
  • resolved: 2019-02-04T13:37:37+00:00
  • votes: 0
  • watchers: 2
  • imported: 2025-11-24
Raw content of original issue

I have a Freestyle project job which has been working for over 40 runs but now gets the error below at the end of each build.  I have created another job copying the configuration of this one and it runs without getting the error.  This error stops the trigger of downstream jobs but doesn't appear to hurt anything in the build itself. I have not updated or installed anything recently that could account for this.

  Archiving artifacts FATAL: null java.lang.NullPointerException at hudson.model.RunParameterDefinition.getDefaultParameterValue(RunParameterDefinition.java:174) at jenkins.model.ParameterizedJobMixIn.getDefaultParametersValues(ParameterizedJobMixIn.java:171) at jenkins.model.ParameterizedJobMixIn.scheduleBuild2(ParameterizedJobMixIn.java:153) at jenkins.model.ParameterizedJobMixIn.scheduleBuild2(ParameterizedJobMixIn.java:122) at jenkins.model.ParameterizedJobMixIn$ParameterizedJob.scheduleBuild2(ParameterizedJobMixIn.java:417) at hudson.model.AbstractProject.scheduleBuild2(AbstractProject.java:852) at hudson.model.AbstractProject.scheduleBuild2(AbstractProject.java:824) at hudson.model.AbstractProject.scheduleBuild2(AbstractProject.java:807) at hudson.model.AbstractProject.scheduleBuild(AbstractProject.java:795) at hudson.tasks.BuildTrigger.execute(BuildTrigger.java:278) at hudson.model.AbstractBuild$AbstractBuildExecution.cleanUp(AbstractBuild.java:643) at hudson.model.Build$BuildExecution.cleanUp(Build.java:201) at hudson.model.Run.execute(Run.java:1784) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:421) Finished: SUCCESS

  • environment: jenkins version 2.73.2 running on Windows Server 2016

Activity

  1. jenkins-infra-bot commented on Oct 19, 2017

    @jenkins-infra-bot
    Author
  2. jenkins-infra-bot commented on Oct 20, 2017

    @jenkins-infra-bot
    Author
    oleg_nenashev:
    • Original comment link
    • Raw content of original comment:

      From what I see, it is a defect in the core. RunParameterDefinition#getProject() may return null, and this is not checked in the calling logic of getDefaultParameterValue(). Sounds it's easy to at least add proper null checks.

    From what I see, it is a defect in the core. RunParameterDefinition#getProject() may return null, and this is not checked in the calling logic of getDefaultParameterValue(). Sounds it's easy to at least add proper null checks.

  3. jenkins-infra-bot commented on Oct 20, 2017

    @jenkins-infra-bot
    Author
    oleg_nenashev:
    • Original comment link
    • Raw content of original comment:

      OTOH it is not a regression. The code has not been modified for years

    OTOH it is not a regression. The code has not been modified for years

  4. jenkins-infra-bot commented on Oct 20, 2017

    @jenkins-infra-bot
    Author
    oleg_nenashev:
    • Original comment link
    • Raw content of original comment:

      The potential culprit is installation of AuthorizeProject on the instance, which may impact this default value retrieval.

    The potential culprit is installation of AuthorizeProject on the instance, which may impact this default value retrieval.

  5. jenkins-infra-bot commented on Oct 20, 2017

    @jenkins-infra-bot
    Author
    jmckinnon:
    • Original comment link
    • Raw content of original comment:

      Why would that only affect this one configuration and not the copy of it?

    Why would that only affect this one configuration and not the copy of it?

  6. jenkins-infra-bot commented on Feb 4, 2019

    @jenkins-infra-bot
    Author
    oleg_nenashev:
    • Original comment link
    • Raw content of original comment:

      The fix was released in Jenkins 2.163

    The fix was released in Jenkins 2.163

  7. removed
    bugFor changelog: Minor bug. Will be listed after features
    on Nov 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions