• Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major Major
    • Jenkins 2.19.4 (LTS)
      Plugins affected
      io.jenkins.blueocean:blueocean:1.0.0-b14
      org.jenkins-ci.plugins:htmlpublisher:1.11
    • Blue Ocean 1.2

      Ready for release

      This improvement is completed and scheduled for release in 1.2. Check the roadmap page for updates.

      Original request
      I Have a really basic repo I wanted to test with Blue Ocean. As part of the build script

      node {
          stage('Cleanup') {
              sh 'rm -rf ./*'
          }
          stage('Fetch from GitHub') {
              sh 'git clone https://github.com/Lewiscowles1986/julid'
          }
          dir('julid') {
              stage('Test') {
                  sh 'gradle test'
              }
              
              
              stage('Build') {
                  sh 'gradle build'
              }
          }
          stage('Report Gathering') {
              publishHTML([allowMissing: true, alwaysLinkToLastBuild: false, keepAll: true, reportDir: 'julid/build/reports/tests', reportFiles: 'index.html', reportName: 'JUnit Test Reports'])
              publishHTML([allowMissing: true, alwaysLinkToLastBuild: false, keepAll: true, reportDir: 'julid/build/reports/jacoco', reportFiles: 'index.html', reportName: 'JaCoCo Coverage Reports'])
          }
          stage('Package') {
              sh 'cd julid && gradle jar'
          }
      }
      

      It still shows in the old UI but not in artifacts or any reports for the Blue Ocean. It's deliberately a really naive example as I am learning and testing new things

          [JENKINS-40616] publishHTML on blueocean

          James Dumay added a comment -

          lewiscowles1986 I am assuming that this is provided by the HTML publisher plugin?

          James Dumay added a comment - lewiscowles1986 I am assuming that this is provided by the HTML publisher plugin ?

          Lewis Cowles added a comment -

          Hello, yes it is sorry I didn't know I could multi-select from that area

          Lewis Cowles added a comment - Hello, yes it is sorry I didn't know I could multi-select from that area

          Michael Neale added a comment -

          thanks lewiscowles1986 - would it suffice to open the HTML report in a new tab or do you see it embedded in an iframe type of thing? 

          Michael Neale added a comment - thanks lewiscowles1986 - would it suffice to open the HTML report in a new tab or do you see it embedded in an iframe type of thing? 

          Lewis Cowles added a comment -

          That sounds great Michael Neale!

          Lewis Cowles added a comment - That sounds great Michael Neale!

          I'm surprised that this has a low priority. For me it's almost the only reason I have to go back to the old frontend.

          Marco Bachmann added a comment - I'm surprised that this has a low priority. For me it's almost the only reason I have to go back to the old frontend.

          Michael Neale added a comment -

          nerumo Bumped prioirty and changed this to be a "usability improvement" - as this is the sort of thing that would make things more widely usable right jamesdumay

          Michael Neale added a comment - nerumo Bumped prioirty and changed this to be a "usability improvement" - as this is the sort of thing that would make things more widely usable right jamesdumay ? 

          James Dumay added a comment -

          It's likely a backend change that will allow published HTML to be viewable from the Artifacts tab.

          James Dumay added a comment - It's likely a backend change that will allow published HTML to be viewable from the Artifacts tab.

          I think opening in a new tab would be sufficient. Just list the reports like artefacts 

          Martin Reinhardt added a comment - I think opening in a new tab would be sufficient. Just list the reports like artefacts 

          I´d like to mantain old interface behabiour:

          • In artifacts: Show link to report. 
          • When clicked go to that HTML report with its styles.

          Ty!

          Patricio Iglesias added a comment - I´d like to mantain old interface behabiour: In artifacts: Show link to report.  When clicked go to that HTML report with its styles. Ty!

          Code changed in jenkins
          User: James William Dumay
          Path:
          content/projects/blueocean/roadmap/data.json
          http://jenkins-ci.org/commit/jenkins.io/f1e06ba25c36980aab99ea4e9acf60c112cb6a9c
          Log:
          Add JENKINS-40616 to Blue Ocean roadmap

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: James William Dumay Path: content/projects/blueocean/roadmap/data.json http://jenkins-ci.org/commit/jenkins.io/f1e06ba25c36980aab99ea4e9acf60c112cb6a9c Log: Add JENKINS-40616 to Blue Ocean roadmap

          Code changed in jenkins
          User: R. Tyler Croy
          Path:
          content/projects/blueocean/roadmap/data.json
          http://jenkins-ci.org/commit/jenkins.io/44b733af555456cff8af6027a49d4246375aa53a
          Log:
          Merge pull request #1068 from i386/patch-6

          Add JENKINS-40616 to Blue Ocean roadmap

          Compare: https://github.com/jenkins-infra/jenkins.io/compare/140721029724...44b733af5554

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: R. Tyler Croy Path: content/projects/blueocean/roadmap/data.json http://jenkins-ci.org/commit/jenkins.io/44b733af555456cff8af6027a49d4246375aa53a Log: Merge pull request #1068 from i386/patch-6 Add JENKINS-40616 to Blue Ocean roadmap Compare: https://github.com/jenkins-infra/jenkins.io/compare/140721029724...44b733af5554

          James Dumay added a comment - - edited

          Available in Blue Ocean 1.2 shortly

          James Dumay added a comment - - edited Available in Blue Ocean 1.2 shortly

          Mukul Garg added a comment -

          Hi,

          I have included HTML publisher in my pipeline code but unable to see the tab on blueocean UI.

          Mukul Garg added a comment - Hi, I have included HTML publisher in my pipeline code but unable to see the tab on blueocean UI.

          Vivek Pandey added a comment -

          gargmukku07 Not in tab. It should appear in the artifacts with link. Click on the link to see the HTML content. Please try and let us know.

          Vivek Pandey added a comment - gargmukku07 Not in tab. It should appear in the artifacts with link. Click on the link to see the HTML content. Please try and let us know.

          Anders Pikas added a comment - - edited

          I have the same problem. No links to the published HTML on Blue Ocean.

          I'm running Jenkins 2.79, Blue Ocean 1.2.4. Pipeline:

          publishHTML(target: [allowMissing: false, alwaysLinkToLastBuild: false, keepAll: false, reportDir: 'doc/internal/html', reportFiles: 'index.html', reportName: 'DOC', reportTitles: ''])

          The link appears in the old UI on the page for e.g. "PR-919/", but not for a particular build, e.g. "PR-919/1/".

          This is unlike the old UI artifacts - they are listed under the build, e.g. "PR-919/1/".

          It would make sense to have a similar behavior in the Blue Ocean UI, i.e. have the link somewhere on the "activity" page. But a link together with the artifacts would also be useful!

          Anders Pikas added a comment - - edited I have the same problem. No links to the published HTML on Blue Ocean. I'm running Jenkins 2.79, Blue Ocean 1.2.4. Pipeline: publishHTML(target: [allowMissing: false, alwaysLinkToLastBuild: false, keepAll: false, reportDir: 'doc/internal/html', reportFiles: 'index.html', reportName: 'DOC', reportTitles: ''] ) The link appears in the old UI on the page for e.g. "PR-919/", but not for a particular build, e.g. "PR-919/1/". This is unlike the old UI artifacts - they are listed under the build, e.g. "PR-919/1/". It would make sense to have a similar behavior in the Blue Ocean UI, i.e. have the link somewhere on the "activity" page. But a link together with the artifacts would also be useful!

          Kyle Leinen added a comment -

          apikas, wouldn't you need to set keepAll  to true to get that to happen?

          Kyle Leinen added a comment - apikas , wouldn't you need to set keepAll  to true to get that to happen?

          Michael Neale added a comment -

          I am not actually sure how this feature is meant to work, perhaps jamesdumay can comment when back from vaction sometime? 

          Michael Neale added a comment - I am not actually sure how this feature is meant to work, perhaps jamesdumay can comment when back from vaction sometime? 

          Anders Pikas added a comment -

          kmleinen Yes, keepAll:true makes the HTML appear as a link in the artifact list in Blue Ocean. In the old UI the link appears on the left, both in  "PR-919/", and in "PR-919/1/".

          The documentation says "If checked, archive reports for all successful builds, otherwise only the most recent". So I guess the only drawback of having keepAll set to true is the extra space (in my case 43 MB per build for HTML).

          Anders Pikas added a comment - kmleinen Yes, keepAll:true makes the HTML appear as a link in the artifact list in Blue Ocean. In the old UI the link appears on the left, both in  "PR-919/", and in "PR-919/1/". The documentation says "If checked, archive reports for all successful builds, otherwise only the most recent". So I guess the only drawback of having keepAll set to true is the extra space (in my case 43 MB per build for HTML).

          Liam Newman added a comment -

          jamesdumay vivek 

          Something needs to change here.  Having the user have to use "keepAll:true" to get the item to appear in the artifact list is sufficient to close this bug, I guess, but not great. 

          At minimum there needs to be documentation of this, but that's not great either.  Blue Ocean to tell the user is calling the publishHTML step,  Blue Ocean should give messaging when the publishHTML step is called without this setting that says "keepAll:false is not supported by Blue Ocean".

          Better would be to have links added to the Activity pane for a Pipeline. 

          Liam Newman added a comment - jamesdumay vivek   Something needs to change here.  Having the user have to use "keepAll:true" to get the item to appear in the artifact list is sufficient to close this bug, I guess, but not great.  At minimum there needs to be documentation of this, but that's not great either.  Blue Ocean to tell the user is calling the publishHTML step,  Blue Ocean should give messaging when the publishHTML step is called without this setting that says "keepAll:false is not supported by Blue Ocean". Better would be to have links added to the Activity pane for a Pipeline. 

          Michael Neale added a comment -

          ah hrm - this does seem bad. Not sure of solution though - how does "classic" solve it? Always shows a link to something? 

          Michael Neale added a comment - ah hrm - this does seem bad. Not sure of solution though - how does "classic" solve it? Always shows a link to something? 

            jamesdumay James Dumay
            lewiscowles1986 Lewis Cowles
            Votes:
            31 Vote for this issue
            Watchers:
            35 Start watching this issue

              Created:
              Updated: