java.lang.NullPointerException

Jenkins JIRA | Juan Sotuyo | 4 years ago
  1. 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
  2. 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
  3. 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
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 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
  6. 0

    Under the Boot Up Vagrant VM task, specifying a relative path to the Vagrantfile doesnt work. Tried: ./Vagrantfile and Vagrantfile It appears as though 'vagrant up' tries to execute in / leaving the field empty gives a stack trace: {noformat} 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:285) at hudson.FilePath.<init>(FilePath.java:230) at org.jenkinsci.plugins.vagrant.VagrantWrapper.parseVagrantEnvironment(VagrantWrapper.java:107) at org.jenkinsci.plugins.vagrant.VagrantWrapper.validate(VagrantWrapper.java:184) at org.jenkinsci.plugins.vagrant.VagrantWrapper.executeCommand(VagrantWrapper.java:133) at org.jenkinsci.plugins.vagrant.VagrantUpCommand.perform(VagrantUpCommand.java:101) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:770) at hudson.model.Build$BuildExecution.build(Build.java:199) at hudson.model.Build$BuildExecution.doRun(Build.java:160) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:533) at hudson.model.Run.execute(Run.java:1745) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:89) at hudson.model.Executor.run(Executor.java:240) {noformat} I can fix this by using the full path (/var/lib/jenkins/jobs/project/workspace/Vagrantfile), but it's not ideal

    Jenkins JIRA | 2 years ago | jessebs
    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 java.util.regex.Matcher.getTextLength()
  2. Java RT
    Pattern.matcher
    1. java.util.regex.Matcher.getTextLength(Matcher.java:1140)
    2. java.util.regex.Matcher.reset(Matcher.java:291)
    3. java.util.regex.Matcher.<init>(Matcher.java:211)
    4. java.util.regex.Pattern.matcher(Pattern.java:888)
    4 frames
  3. Hudson
    FilePath.<init>
    1. hudson.FilePath.normalize(FilePath.java:248)
    2. hudson.FilePath.<init>(FilePath.java:194)
    2 frames
  4. hudson.plugins.findbugs
    FindBugsReporter.perform
    1. hudson.plugins.findbugs.FindBugsReporter.getOutputPath(FindBugsReporter.java:180)
    2. hudson.plugins.findbugs.FindBugsReporter.perform(FindBugsReporter.java:175)
    2 frames
  5. Static Analysis Utilities
    HealthAwareReporter.postExecute
    1. hudson.plugins.analysis.core.HealthAwareReporter.postExecute(HealthAwareReporter.java:313)
    1 frame
  6. Hudson Maven Embedder
    MavenBuilder$Adapter.postExecute
    1. hudson.maven.Maven2Builder.postExecute(Maven2Builder.java:155)
    2. hudson.maven.MavenBuilder$Adapter.postExecute(MavenBuilder.java:310)
    2 frames
  7. Hudson M2
    PluginManagerInterceptor.executeMojo
    1. hudson.maven.agent.PluginManagerInterceptor$1MojoIntercepterImpl.callPost(PluginManagerInterceptor.java:170)
    2. hudson.maven.agent.PluginManagerInterceptor.executeMojo(PluginManagerInterceptor.java:183)
    2 frames
  8. Maven Core
    DefaultMaven.execute
    1. org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
    2. org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556)
    3. org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535)
    4. org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
    5. org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348)
    6. org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
    7. org.apache.maven.lifecycle.LifecycleExecutorInterceptor.execute(LifecycleExecutorInterceptor.java:65)
    8. org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
    9. org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
    9 frames
  9. M3 Interceptor
    MavenCli.main
    1. org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
    1 frame
  10. Java RT
    Method.invoke
    1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    4. java.lang.reflect.Method.invoke(Method.java:597)
    4 frames
  11. Plexus
    Launcher.launch
    1. org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
    2. org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
    2 frames
  12. Hudson M2
    Main.launch
    1. hudson.maven.agent.Main.launch(Main.java:185)
    1 frame
  13. Hudson Maven Embedder
    Maven2Builder.call
    1. hudson.maven.MavenBuilder.call(MavenBuilder.java:151)
    2. hudson.maven.Maven2Builder.call(Maven2Builder.java:77)
    3. hudson.maven.Maven2Builder.call(Maven2Builder.java:53)
    3 frames
  14. Hudson :: Remoting Layer
    InterceptingExecutorService$1.call
    1. hudson.remoting.UserRequest.perform(UserRequest.java:118)
    2. hudson.remoting.UserRequest.perform(UserRequest.java:48)
    3. hudson.remoting.Request$2.run(Request.java:326)
    4. hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
    4 frames
  15. Java RT
    Thread.run
    1. java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    2. java.util.concurrent.FutureTask.run(FutureTask.java:138)
    3. java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
    4. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
    5. java.lang.Thread.run(Thread.java:662)
    5 frames