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

Failed to read XML file produced by maven spy after an execution threw an exception and color is enabled

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • pipeline-maven-plugin
    • None
    • pipeline-maven-plugin: 3.8.2
    • pipeline-maven-plugin 3.9.0-beta-1

      The plugin fails to read the XML log file produced by the maven spy under the following circumstances:

      • maven is executed with ANSI color enabled
      • a plugin execution fails to execute 

      The maven spy captures the exception thrown by the failed execution and writes it asis in its XML log file. Unfortunately, it appears that the exception message contains ANSI color escape codes when maven is executed with coloring enabled. These escape codes are not valid XML content hence causing the failure to read back the XML log file.

      The issue can be easily reproduced with the attached sample pom.xml.


      Note: according to issue JENKINS-55318, coloring is not working because the plugin always invoke maven in batch mode. Our Jenkins installation is actually using a kind of post-processor that removes the --batch-mode argument from the generated wrapper script... so we have coloring working nicely.

          [JENKINS-61791] Failed to read XML file produced by maven spy after an execution threw an exception and color is enabled

          Bertrand Renuart created issue -
          Bertrand Renuart made changes -
          Remote Link New: This issue links to "PR-232 (Web Link)" [ 24817 ]
          Bertrand Renuart made changes -
          Description Original: The plugin fails to read the XML log file produced by the maven spy under the following circumstances:
           * maven is executed with ANSI color enabled
           * a plugin execution fails to execute 

          The maven spy captures the exception thrown by the failed execution and writes it asis in its XML log file. Unfortunately, it appears that the exception message contains ANSI color escape codes when maven is executed with coloring enabled. These escape codes are not valid XML content hence causing the failure to read back the XML log file.

          The issue can be easily reproduced with the attached sample {{pom.xml}}.
          New: The plugin fails to read the XML log file produced by the maven spy under the following circumstances:
           * maven is executed with ANSI color enabled
           * a plugin execution fails to execute 

          The maven spy captures the exception thrown by the failed execution and writes it asis in its XML log file. Unfortunately, it appears that the exception message contains ANSI color escape codes when maven is executed with coloring enabled. These escape codes are not valid XML content hence causing the failure to read back the XML log file.

          The issue can be easily reproduced with the attached sample {{pom.xml}}.

          Note: 
          Bertrand Renuart made changes -
          Description Original: The plugin fails to read the XML log file produced by the maven spy under the following circumstances:
           * maven is executed with ANSI color enabled
           * a plugin execution fails to execute 

          The maven spy captures the exception thrown by the failed execution and writes it asis in its XML log file. Unfortunately, it appears that the exception message contains ANSI color escape codes when maven is executed with coloring enabled. These escape codes are not valid XML content hence causing the failure to read back the XML log file.

          The issue can be easily reproduced with the attached sample {{pom.xml}}.

          Note: 
          New: The plugin fails to read the XML log file produced by the maven spy under the following circumstances:
           * maven is executed with ANSI color enabled
           * a plugin execution fails to execute 

          The maven spy captures the exception thrown by the failed execution and writes it asis in its XML log file. Unfortunately, it appears that the exception message contains ANSI color escape codes when maven is executed with coloring enabled. These escape codes are not valid XML content hence causing the failure to read back the XML log file.

          The issue can be easily reproduced with the attached sample {{pom.xml}}.

          ----

          Note: according to issue JENKINS-55318, coloring is _not_ working because the plugin always invoke maven in batch mode. Our Jenkins installation is actually using a kind of post-processor that removes the --batch-mode argument from the generated wrapper script... so we have coloring working nicely.
          Arnaud Héritier made changes -
          Assignee Original: Alvaro Lobato [ alobato ]
          Arnaud Héritier made changes -
          Assignee New: Cyrille Le Clerc [ cleclerc ]
          Arnaud Héritier made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Fixed but Unreleased [ 10203 ]
          Arnaud Héritier made changes -
          Released As New: pipeline-maven-plugin 3.9.0-beta-1
          Status Original: Fixed but Unreleased [ 10203 ] New: Resolved [ 5 ]
          Benoit made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]

            cleclerc Cyrille Le Clerc
            brenuart Bertrand Renuart
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: