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

edu.hm.hafner.analysis.ParsingException: Unable to change directory

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • analysis-model
    • None
    • Jenkins 2.319.1
      Analysis Model API Plugin 10.8.1
      Warnings Next Generation Plugin 9.10.2
      java.runtime.name OpenJDK Runtime Environment
      java.runtime.version 11.0.13+8-post-Debian-1deb11u1
      Linux 5.10.0-9-amd64 (Debian Bullseye)

      Hi,

      I'm facing same issue as JENKINS-66923, but with the last plugins versions.

      If i downgrade to :

      Analysis Model API Plugin 10.3.0
      Warnings Next Generation Plugin 9.5.0

      The problem is not present anymore. Maybe i missed something ?

      Regards,

      edu.hm.hafner.analysis.ParsingException: Unable to change directory using: .*Entering directory [`'](?<dir>.*)['`] to match -- Entering directory build/Debug
       at edu.hm.hafner.analysis.LookaheadParser.extractDirectory(LookaheadParser.java:157)
       at edu.hm.hafner.analysis.LookaheadParser.enterDirectory(LookaheadParser.java:92)
       at edu.hm.hafner.analysis.LookaheadParser.handleDirectoryChanges(LookaheadParser.java:123)
       at edu.hm.hafner.analysis.LookaheadParser.parse(LookaheadParser.java:68)
       at edu.hm.hafner.analysis.LookaheadParser.parse(LookaheadParser.java:57)
       at edu.hm.hafner.analysis.registry.CompositeParserDescriptor$CompositeParser.parse(CompositeParserDescriptor.java:84)
       at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scanInConsoleLog(ReportScanningTool.java:190)
       at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scan(ReportScanningTool.java:137)
       at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scan(ReportScanningTool.java:129)
       at io.jenkins.plugins.analysis.core.steps.IssuesScanner.scan(IssuesScanner.java:95)
       at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.scanWithTool(IssuesRecorder.java:765)
       at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.record(IssuesRecorder.java:728)
       at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.perform(IssuesRecorder.java:697)
       at io.jenkins.plugins.analysis.core.steps.RecordIssuesStep$Execution.run(RecordIssuesStep.java:1109)
       at io.jenkins.plugins.analysis.core.steps.RecordIssuesStep$Execution.run(RecordIssuesStep.java:1067)
       at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
       at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
       at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
       at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
       at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
       at java.base/java.lang.Thread.run(Thread.java:829)

          [JENKINS-67417] edu.hm.hafner.analysis.ParsingException: Unable to change directory

          Ulli Hafner added a comment -

          Can you please paste a snippet of your output in your log so we can create a new test case? (The part with the text Entering directory)

          Ulli Hafner added a comment - Can you please paste a snippet of your output in your log so we can create a new test case? (The part with the text Entering directory )

          Eric Beuque added a comment - - edited

          Current console output at his crash is :

          [Pipeline] }
           [Pipeline] // dir
           [Pipeline] }
           [Pipeline] // script
           [Pipeline] script
           [Pipeline] {
           [Pipeline] }
           [Pipeline] // script
           [Pipeline] script
           [Pipeline] {
           [Pipeline] echo
           Clean up build directories
           [Pipeline] echo
           Keep build directories...
           [Pipeline] }
           [Pipeline] // script
           [Pipeline] }
           [Pipeline] // ws
           [Pipeline] }
           [Pipeline] // withEnv
           [Pipeline] }
           [Pipeline] // node
           [Pipeline] }
           [Pipeline] // parallel
           [Pipeline] }
           [Pipeline] // stage
           [Pipeline] stage
           [Pipeline] { (Checks)
           [Pipeline] echo
           Compilation warnings checks
           [Pipeline] recordIssues
           [GNU C Compiler (gcc)] Sleeping for 5 seconds due to JENKINS-32191...
           [GNU C Compiler (gcc)] Parsing console log (workspace: '/var/lib/jenkins/workspace/Toolkit_Trunk')
           [Pipeline] }
           [Pipeline] // stage
           [Pipeline] step
           Sending e-mails to: ***@****
           [Pipeline] }
           [Pipeline] // load
           [Pipeline] }
           [Pipeline] // node
           [Pipeline] End of Pipeline
           edu.hm.hafner.analysis.ParsingException: Unable to change directory using: .Entering directory [`'](?<dir>.)['`] to match – Entering directory build/Debug
           at edu.hm.hafner.analysis.LookaheadParser.extractDirectory(LookaheadParser.java:157)
           at edu.hm.hafner.analysis.LookaheadParser.enterDirectory(LookaheadParser.java:92)
           at edu.hm.hafner.analysis.LookaheadParser.handleDirectoryChanges(LookaheadParser.java:123)
           at edu.hm.hafner.analysis.LookaheadParser.parse(LookaheadParser.java:68)
           at edu.hm.hafner.analysis.LookaheadParser.parse(LookaheadParser.java:57)
           at edu.hm.hafner.analysis.registry.CompositeParserDescriptor$CompositeParser.parse(CompositeParserDescriptor.java:84)
           at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scanInConsoleLog(ReportScanningTool.java:190)
           at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scan(ReportScanningTool.java:137)
           at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scan(ReportScanningTool.java:129)
           at io.jenkins.plugins.analysis.core.steps.IssuesScanner.scan(IssuesScanner.java:95)
           at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.scanWithTool(IssuesRecorder.java:765)
           at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.record(IssuesRecorder.java:728)
           at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.perform(IssuesRecorder.java:697)
           at io.jenkins.plugins.analysis.core.steps.RecordIssuesStep$Execution.run(RecordIssuesStep.java:1109)
           at io.jenkins.plugins.analysis.core.steps.RecordIssuesStep$Execution.run(RecordIssuesStep.java:1067)
           at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
           at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
           at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
           at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
           at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
           at java.base/java.lang.Thread.run(Thread.java:829)
           Finished: FAILURE

          Is it enough for you ? Note that builds are done on other node than to master doing the warnings checks.

          Eric Beuque added a comment - - edited Current console output at his crash is : [Pipeline] } [Pipeline] // dir [Pipeline] } [Pipeline] // script [Pipeline] script [Pipeline] { [Pipeline] } [Pipeline] // script [Pipeline] script [Pipeline] { [Pipeline] echo Clean up build directories [Pipeline] echo Keep build directories... [Pipeline] } [Pipeline] // script [Pipeline] } [Pipeline] // ws [Pipeline] } [Pipeline] // withEnv [Pipeline] } [Pipeline] // node [Pipeline] } [Pipeline] // parallel [Pipeline] } [Pipeline] // stage [Pipeline] stage [Pipeline] { (Checks) [Pipeline] echo Compilation warnings checks [Pipeline] recordIssues [GNU C Compiler (gcc)] Sleeping for 5 seconds due to JENKINS-32191... [GNU C Compiler (gcc)] Parsing console log (workspace: '/ var /lib/jenkins/workspace/Toolkit_Trunk' ) [Pipeline] } [Pipeline] // stage [Pipeline] step Sending e-mails to: ***@**** [Pipeline] } [Pipeline] // load [Pipeline] } [Pipeline] // node [Pipeline] End of Pipeline edu.hm.hafner.analysis.ParsingException: Unable to change directory using: .Entering directory [` '](?<dir>.)[' `] to match – Entering directory build/Debug at edu.hm.hafner.analysis.LookaheadParser.extractDirectory(LookaheadParser.java:157) at edu.hm.hafner.analysis.LookaheadParser.enterDirectory(LookaheadParser.java:92) at edu.hm.hafner.analysis.LookaheadParser.handleDirectoryChanges(LookaheadParser.java:123) at edu.hm.hafner.analysis.LookaheadParser.parse(LookaheadParser.java:68) at edu.hm.hafner.analysis.LookaheadParser.parse(LookaheadParser.java:57) at edu.hm.hafner.analysis.registry.CompositeParserDescriptor$CompositeParser.parse(CompositeParserDescriptor.java:84) at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scanInConsoleLog(ReportScanningTool.java:190) at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scan(ReportScanningTool.java:137) at io.jenkins.plugins.analysis.core.model.ReportScanningTool.scan(ReportScanningTool.java:129) at io.jenkins.plugins.analysis.core.steps.IssuesScanner.scan(IssuesScanner.java:95) at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.scanWithTool(IssuesRecorder.java:765) at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.record(IssuesRecorder.java:728) at io.jenkins.plugins.analysis.core.steps.IssuesRecorder.perform(IssuesRecorder.java:697) at io.jenkins.plugins.analysis.core.steps.RecordIssuesStep$Execution.run(RecordIssuesStep.java:1109) at io.jenkins.plugins.analysis.core.steps.RecordIssuesStep$Execution.run(RecordIssuesStep.java:1067) at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang. Thread .run( Thread .java:829) Finished: FAILURE Is it enough for you ? Note that builds are done on other node than to master doing the warnings checks.

          Ulli Hafner added a comment -

          Sorry for being not clear. I do not need the log of the exception. Since the warnings plugin is parsing the compiler log I need to need that snippet of your compiler output in the log that contains those messages that start with the text Entering directory, see JENKINS-66923 for an example. This part seems to be parsed incorrectly.

          Ulli Hafner added a comment - Sorry for being not clear. I do not need the log of the exception. Since the warnings plugin is parsing the compiler log I need to need that snippet of your compiler output in the log that contains those messages that start with the text Entering directory , see JENKINS-66923 for an example. This part seems to be parsed incorrectly.

          Eric Beuque added a comment -

          Hi, here are the logs.

          I just replaced the original username by "abcdefg".
          + /Users/abcdefg/devel/build/scripts/run_test.sh jet1oeil-toolkit-testsuite build/Debug /Users/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-darwin-clang-x86_64-10_14_Debug/src/testfile -maxwarnings 0
          – Current path /Users/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-darwin-clang-x86_64-10_14_Debug
          – Launching build/Debug/jet1oeil-toolkit-testsuite
          – Entering directory build/Debug[439/685] Building CXX object src\Toolkit\QtGui\CMakeFiles\toolkit_qtgui.dir\Image\QIconThemeFallback.cpp.obj
          Here a second entry :
          + /home/devel/build/scripts/run_test.sh jet1oeil-toolkit-testsuite build /home/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-debian-stretch-gcc64_Release/src/testfile -maxwarnings 0
          – Current path /home/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-debian-stretch-gcc64_Release
          – Launching build/jet1oeil-toolkit-testsuite
          – Entering directory build
          DEBUG: (Thread 139689230178112) [Main] Using test directory: /home/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-debian-stretch-gcc64_Release/src/testfile
          Is it ok for you ?

          Regards,

          Eric Beuque added a comment - Hi, here are the logs. I just replaced the original username by "abcdefg". + /Users/abcdefg/devel/build/scripts/run_test.sh jet1oeil-toolkit-testsuite build/Debug /Users/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-darwin-clang-x86_64-10_14_Debug/src/testfile -maxwarnings 0 – Current path /Users/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-darwin-clang-x86_64-10_14_Debug – Launching build/Debug/jet1oeil-toolkit-testsuite – Entering directory build/Debug [439/685] Building CXX object src\Toolkit\QtGui\CMakeFiles\toolkit_qtgui.dir\Image\QIconThemeFallback.cpp.obj Here a second entry : + /home/devel/build/scripts/run_test.sh jet1oeil-toolkit-testsuite build /home/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-debian-stretch-gcc64_Release/src/testfile -maxwarnings 0 – Current path /home/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-debian-stretch-gcc64_Release – Launching build/jet1oeil-toolkit-testsuite – Entering directory build DEBUG: (Thread 139689230178112) [Main] Using test directory: /home/abcdefg/jenkins/workspace/Toolkit_Trunk/platform-debian-stretch-gcc64_Release/src/testfile Is it ok for you ? Regards,

          Ulli Hafner added a comment -

          Almost, can your wrap in a noformat block? Are the - and + part of the log?

          Ulli Hafner added a comment - Almost, can your wrap in a noformat block? Are the - and + part of the log?

          Eric Beuque added a comment -

          Actually, this the output i see in "/job/Toolkit_Trunk/1274/consoleFull"

          + sign is added to mark the executed command by a batch script, it's displayed as this in console output.

          I got a copy/paste issue, but this line is generated by the .sh script and start with a double - sign.

          -- Entering directory build

           

           

          Eric Beuque added a comment - Actually, this the output i see in "/job/Toolkit_Trunk/1274/consoleFull" + sign is added to mark the executed command by a batch script, it's displayed as this in console output. I got a copy/paste issue, but this line is generated by the .sh script and start with a double - sign. -- Entering directory build    

          Ulli Hafner added a comment -

          Can you please wrap the log in your comment above in a noformat block. Then I can copy it as such in a test case. It is important to have the block exactly as in your log.

          Ulli Hafner added a comment - Can you please wrap the log in your comment above in a noformat block. Then I can copy it as such in a test case. It is important to have the block exactly as in your log.

          Eric Beuque added a comment -

          Here the extract in attachement in plain text.

          consoleText.txt

          Eric Beuque added a comment - Here the extract in attachement in plain text. consoleText.txt

          Ulli Hafner added a comment -

          I'm not sure but this seems to be fixed recently.

          Ulli Hafner added a comment - I'm not sure but this seems to be fixed recently.

            drulli Ulli Hafner
            ebeuque Eric Beuque
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: