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

Truncated build logs do not show parallel branch names that began before the truncation point

XMLWordPrintable

    • workflow-job 2.37

      JENKINS-54304 added a CSS prefix for parallel branch names to Pipeline logs, but that fix relies on the start node for the branch being present in the HTML displayed on the console output page, which is not always the case for truncated logs. This results in parallel branch names not being displayed for branches that began before the truncation point.

      I am not sure about the best way to fix this. We could create some synthetic hidden nodes that hold the necessary information when the log is truncated and write them directly into the log when we are producing an HTML log, or add them directly in a copy of console.jelly, and then tweak the Javascript in workflow-job that adds the CSS rules to display the branch names, but that seems very awkward, and I think would need to be done in each individual implementation of LogStorage (or maybe we could make some API change to LogStorage.overallLog or AnnotatedLargeText to make it possible to add that logic in just once place). A prototype of this kind of approach can be seen here.

      Maybe it would be better to revert to inserting the branch names directly into the logs when generating HTML logs in the LogStorage implementations, similarly to how things worked before JENKINS-38381. That would also take care of JENKINS-56910, and would get rid of the lag between when the log shows up and the branch names are displayed because they are generated via Javascript. That would make the logs larger because of all of the redundant data, but given the comments on JENKINS-60862, it seems like a lot of people considered the old behavior a feature, so I think the tradeoff is worth considering.

            dnusbaum Devin Nusbaum
            dnusbaum Devin Nusbaum
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: