Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-55273

recordIssues step fails silently when it can't get get version control information

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • warnings-ng-plugin
    • None
    • Jenkins 2.150.1
      Warnings Next Generation Plugin 1.0.0-beta9
    • 1.0.0

      I am attempting to display errors and warnings from flake8 with the following step in a pipeline:

      recordIssues enabledForFailure: true, ignoreFailedBuilds: false, tools: [flake8(pattern: 'flake8.txt')]

       The step finds issues, then immediately fails, which fails the entire build. There was nothing relevant to the failure in the output from the step:

      00:03:17.360 [Flake8] Searching for all files in '/home/sscadmin/git/pippin' that match the pattern 'flake8.txt'
      00:03:17.361 [Flake8] -> found 1 file
      00:03:17.361 [Flake8] Successfully parsed file /home/sscadmin/git/pippin/flake8.txt
      00:03:17.361 [Flake8] -> found 73 issues (skipped 0 duplicates)
       > git rev-parse HEAD^{commit} # timeout=10
      

      There was a traceback in the job console output:

      org.eclipse.jgit.errors.MissingObjectException: Missing unknown 56520e2e8da7a76d073b60ba663faee3a18ee6f0
       at org.eclipse.jgit.internal.storage.file.WindowCursor.open(WindowCursor.java:158)
       at org.eclipse.jgit.lib.ObjectReader.open(ObjectReader.java:227)
       at org.eclipse.jgit.blame.BlameGenerator.push(BlameGenerator.java:317)
       at org.eclipse.jgit.api.BlameCommand.call(BlameCommand.java:214)
      Also: hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from 10.12.4.4/10.12.4.4:38848
       at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1741)
       at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:357)
       at hudson.remoting.Channel.call(Channel.java:955)
       at hudson.FilePath.act(FilePath.java:1072)
       at hudson.FilePath.act(FilePath.java:1061)
       at io.jenkins.plugins.analysis.core.steps.IssuesScanner.postProcess(IssuesScanner.java:83)
       at io.jenkins.plugins.analysis.core.steps.IssuesScanner.scan(IssuesScanner.java:67)
       at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.scanWithTool(IssuesRecorder.java:654)
       at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.record(IssuesRecorder.java:622)
       at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.perform(IssuesRecorder.java:597)
       at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:80)
       at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:67)
       at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1$1.call(SynchronousNonBlockingStepExecution.java:51)
       at hudson.security.ACL.impersonate(ACL.java:290)
       at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1.run(SynchronousNonBlockingStepExecution.java:48)
       at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
       at java.util.concurrent.FutureTask.run(FutureTask.java:266)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      Caused: org.eclipse.jgit.api.errors.JGitInternalException: Missing unknown 56520e2e8da7a76d073b60ba663faee3a18ee6f0
       at org.eclipse.jgit.api.BlameCommand.call(BlameCommand.java:232)
       at io.jenkins.plugins.analysis.core.scm.GitBlamer$BlameRunner.run(GitBlamer.java:216)
       at io.jenkins.plugins.analysis.core.scm.GitBlamer$BlameCallback.run(GitBlamer.java:164)
       at io.jenkins.plugins.analysis.core.scm.GitBlamer$BlameCallback.invoke(GitBlamer.java:113)
       at io.jenkins.plugins.analysis.core.scm.GitBlamer$BlameCallback.invoke(GitBlamer.java:94)
       at org.jenkinsci.plugins.gitclient.AbstractGitAPIImpl.withRepository(AbstractGitAPIImpl.java:29)
       at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.withRepository(CliGitAPIImpl.java:72)
       at io.jenkins.plugins.analysis.core.scm.GitBlamer.blame(GitBlamer.java:73)
       at io.jenkins.plugins.analysis.core.steps.IssuesScanner$ReportPostProcessor.invoke(IssuesScanner.java:138)
       at io.jenkins.plugins.analysis.core.steps.IssuesScanner$ReportPostProcessor.invoke(IssuesScanner.java:106)
       at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3086)
       at hudson.remoting.UserRequest.perform(UserRequest.java:212)
       at hudson.remoting.UserRequest.perform(UserRequest.java:54)
       at hudson.remoting.Request$2.run(Request.java:369)
       at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
       at java.util.concurrent.FutureTask.run(FutureTask.java:266)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
       at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:93)
       at java.lang.Thread.run(Thread.java:748)

      The job is triggered by a git commit, but uses a custom git command to check out the code rather than "scm checkout".

            drulli Ulli Hafner
            jrogers Jonathan Rogers
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: