java.lang.NullPointerException

Jenkins JIRA | Flominator | 2 years ago
  1. 0

    [JENKINS-17034] NullPointerException when publishing Checkstyle results - Jenkins JIRA

    jenkins-ci.org | 1 year ago
    org.apache.maven.InternalErrorException: Internal error: java.lang.NullPointerException
  2. Speed up your debug routine!

    Automated exception search integrated into your IDE

  3. 0

    I upgraded my version of the Checkstyle plugin from 3.32 to 3.34 and started getting NullPointerExceptions when building the Apache Shindig project. The exception is coming from code that was introduced by this changeset: https://github.com/jenkinsci/checkstyle-plugin/commit/e79892bdb3873059ab04ad1e0569311262353f4c My guess is that "mojo.getConfigurationValue("outputFile", String.class)" is null or empty. I'm not sure what that should be returning or how it gets set in the environment. Have I missed some newly required configuration? Here's the NPE: mavenExecutionResult exceptions not empty message : Internal error: java.lang.NullPointerException cause : null Stack trace : org.apache.maven.InternalErrorException: Internal error: java.lang.NullPointerException at org.apache.maven.lifecycle.internal.BuilderCommon.handleBuildError(BuilderCommon.java:128) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:95) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59) at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) at org.jvnet.hudson.maven3.launcher.Maven3Launcher.main(Maven3Launcher.java:79) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.codehaus.plexus.classworlds.launcher.Launcher.launchStandard(Launcher.java:329) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:239) at org.jvnet.hudson.maven3.agent.Maven3Main.launch(Maven3Main.java:158) at hudson.maven.Maven3Builder.call(Maven3Builder.java:100) at hudson.maven.Maven3Builder.call(Maven3Builder.java:66) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722) Caused by: java.lang.NullPointerException at java.util.regex.Matcher.getTextLength(Matcher.java:1234) at java.util.regex.Matcher.reset(Matcher.java:308) at java.util.regex.Matcher.<init>(Matcher.java:228) at java.util.regex.Pattern.matcher(Pattern.java:1088) at hudson.FilePath.normalize(FilePath.java:250) at hudson.FilePath.<init>(FilePath.java:196) at hudson.plugins.checkstyle.CheckStyleReporter.getFileName(CheckStyleReporter.java:128) at hudson.plugins.checkstyle.CheckStyleReporter.perform(CheckStyleReporter.java:123) at hudson.plugins.analysis.core.HealthAwareReporter.postExecute(HealthAwareReporter.java:313) at hudson.maven.Maven3Builder$MavenExecutionListener.recordMojoEnded(Maven3Builder.java:453) at hudson.maven.Maven3Builder$MavenExecutionListener.mojoSucceeded(Maven3Builder.java:435) at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire(DefaultExecutionEventCatapult.java:87) at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire(DefaultExecutionEventCatapult.java:42) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:228) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84) ... 24 more

    Jenkins JIRA | 4 years ago | Stanton Sievers
    org.apache.maven.InternalErrorException: Internal error: java.lang.NullPointerException
  4. 0

    Evver since upgrading the plugin to the latest version, all my projects (all using Jenkin's built-in Maven2 builder, haven't tried with other types of projects) fail with the following stacktrace. [JENKINS] Archiving redacted [INFO] ------------------------------------------------------------------------ [ERROR] FATAL ERROR [INFO] ------------------------------------------------------------------------ [INFO] null [INFO] ------------------------------------------------------------------------ [INFO] Trace java.lang.NullPointerException at java.util.regex.Matcher.getTextLength(Matcher.java:1140) at java.util.regex.Matcher.reset(Matcher.java:291) at java.util.regex.Matcher.<init>(Matcher.java:211) at java.util.regex.Pattern.matcher(Pattern.java:888) at hudson.FilePath.normalize(FilePath.java:248) at hudson.FilePath.<init>(FilePath.java:194) at hudson.plugins.findbugs.FindBugsReporter.getOutputPath(FindBugsReporter.java:180) at hudson.plugins.findbugs.FindBugsReporter.perform(FindBugsReporter.java:175) at hudson.plugins.analysis.core.HealthAwareReporter.postExecute(HealthAwareReporter.java:313) at hudson.maven.Maven2Builder.postExecute(Maven2Builder.java:155) at hudson.maven.MavenBuilder$Adapter.postExecute(MavenBuilder.java:310) at hudson.maven.agent.PluginManagerInterceptor$1MojoIntercepterImpl.callPost(PluginManagerInterceptor.java:170) at hudson.maven.agent.PluginManagerInterceptor.executeMojo(PluginManagerInterceptor.java:183) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) at org.apache.maven.lifecycle.LifecycleExecutorInterceptor.execute(LifecycleExecutorInterceptor.java:65) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138) at org.apache.maven.cli.MavenCli.main(MavenCli.java:362) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) at hudson.maven.agent.Main.launch(Main.java:185) at hudson.maven.MavenBuilder.call(MavenBuilder.java:151) at hudson.maven.Maven2Builder.call(Maven2Builder.java:77) at hudson.maven.Maven2Builder.call(Maven2Builder.java:53) at hudson.remoting.UserRequest.perform(UserRequest.java:118) at hudson.remoting.UserRequest.perform(UserRequest.java:48) at hudson.remoting.Request$2.run(Request.java:326) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:662) The problem happens on both Jenkins 1.480.2 and 1.480.3.

    Jenkins JIRA | 4 years ago | Juan Sotuyo
    java.lang.NullPointerException

  1. tyson925 4 times, last 2 months ago
  2. tyson925 28 times, last 2 months ago
  3. lribeiro 6 times, last 3 months ago
  4. davidvanlaatum 1 times, last 4 months ago
  5. jk 2 times, last 5 months ago
5 more registered users
9 unregistered visitors
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 java.util.regex.Matcher.getTextLength()
  2. Java RT
    Pattern.matcher
    1. java.util.regex.Matcher.getTextLength(Unknown Source)
    2. java.util.regex.Matcher.reset(Unknown Source)
    3. java.util.regex.Matcher.<init>(Unknown Source)
    4. java.util.regex.Pattern.matcher(Unknown Source)
    4 frames
  3. Hudson
    FilePath.<init>
    1. hudson.FilePath.normalize(FilePath.java:286)
    2. hudson.FilePath.<init>(FilePath.java:231)
    2 frames
  4. hudson.plugins.msbuild
    MsBuildBuilder.perform
    1. hudson.plugins.msbuild.MsBuildBuilder.perform(MsBuildBuilder.java:129)
    1 frame
  5. Hudson
    Executor.run
    1. hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
    2. hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:761)
    3. hudson.model.Build$BuildExecution.build(Build.java:203)
    4. hudson.model.Build$BuildExecution.doRun(Build.java:160)
    5. hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:536)
    6. hudson.model.Run.execute(Run.java:1741)
    7. hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
    8. hudson.model.ResourceController.execute(ResourceController.java:98)
    9. hudson.model.Executor.run(Executor.java:374)
    9 frames