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

Karaoke does not resume after "scroll to bottom"

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • blueocean-plugin
    • None
    • Blue Ocean 1.1, Blue Ocean 1.1, Blue Ocean 1.2-beta1, Blue Ocean 1.4 - beta 2

      Original description
      When viewing the Run Details logs for a running build, when a user scrolls up, the system stops loading logs entirely. This obviously prevents any karaoke behavior from occurring. It appears that when the build completes, we do refresh the data and logs to reflect the completed state.

      I have tested this in the following commits and the behavior seems consistent:

      There seems to be some debate as to what the behavior should be. tscherler indicated it's always worked this way, although jamesdumay says that log loading should continue regardless, just no auto scrolling / auto stage moving.

      Before I dig deeper into JENKINS-43316 and JENKINS-43317 it'd help to know whether this issue needs addressing. And if it's true that karaoke has always worked like this, this should be marked as an enhancement and probably not block 1.1 release as it may take some time to implement this from scratch. I don't know the code base well enough to estimate the effort.

          [JENKINS-44342] Karaoke does not resume after "scroll to bottom"

          Cliff Meyers added a comment -

          Note that my testing has been using this repo, which I intend to add to over time to contain more interesting Jenkinsfiles:

          https://github.com/histos/karaoke-samples
          using the "stages-steps-ping" branch

          Cliff Meyers added a comment - Note that my testing has been using this repo, which I intend to add to over time to contain more interesting Jenkinsfiles: https://github.com/histos/karaoke-samples using the "stages-steps-ping" branch

          James Dumay added a comment -

          cliffmeyers after speaking with michaelneale I think we do want to fix this up. Can we chat about it directly after planning?

          James Dumay added a comment - cliffmeyers after speaking with michaelneale I think we do want to fix this up. Can we chat about it directly after planning?

          cliffmeyers the resume if scrolled to bottom never has been implemented. You can find it in the initial PR and tickets. I agree with you cliffmeyers that this is an enhancement.

          Regarding the implementation https://github.com/jenkinsci/blueocean-plugin/blob/master/blueocean-dashboard/src/main/js/components/RunDetailsPipeline.jsx#L56 here you would need to implement the logic. If you imitate classic this should be to evaluate if the last step log is in the current viewport and the scroll is still to the bottom. So I am not sure why you would need to implement it from scratch, sounds more like a couple of hours (testing with ATH included).

          Thorsten Scherler added a comment - cliffmeyers the resume if scrolled to bottom never has been implemented. You can find it in the initial PR and tickets. I agree with you cliffmeyers that this is an enhancement. Regarding the implementation https://github.com/jenkinsci/blueocean-plugin/blob/master/blueocean-dashboard/src/main/js/components/RunDetailsPipeline.jsx#L56 here you would need to implement the logic. If you imitate classic this should be to evaluate if the last step log is in the current viewport and the scroll is still to the bottom. So I am not sure why you would need to implement it from scratch, sounds more like a couple of hours (testing with ATH included).

          Cliff Meyers added a comment -

          tscherler yeah, when I said "from scratch" I did not mean rewriting anything in karaoke. I was just pointing out that there is usually a greater effort to implement a feature for the first time, versus just fixing a bug.

          Cliff Meyers added a comment - tscherler yeah, when I said "from scratch" I did not mean rewriting anything in karaoke. I was just pointing out that there is usually a greater effort to implement a feature for the first time, versus just fixing a bug.

          Cliff Meyers added a comment -

          jamesdumay so to confirm, as part of this ticket, we expect the following behaviors:

          • Scrolling up should not stop loading of the log file. No matter what the user does, if they are viewing a stage (or freestyle log) that's running, it should always continue to append log data to the screen.
          • Scrolling up should ensure the UI stops the following behaviors:
            • Do not auto scroll to bottom as new log data is appended
            • Do not jump to the next stage when it begins running
          • Scrolling down to the bottom of a stage (or freestyle log) that's currently running should reactive karaoke.

          tscherler currently I think the code that "turns off karaoke" just calls `Pager.clear()` to turn off the auto fetch. So to satisfy above requirements, we probably need to make some changes so that "clear" doesn't stop auto-loading but changes whether the UI responds to new data by auto-scrolling to bottom or jumping to new stage. Does that sound correct?

          Cliff Meyers added a comment - jamesdumay so to confirm, as part of this ticket, we expect the following behaviors: Scrolling up should not stop loading of the log file. No matter what the user does, if they are viewing a stage (or freestyle log) that's running, it should always continue to append log data to the screen. Scrolling up should ensure the UI stops the following behaviors: Do not auto scroll to bottom as new log data is appended Do not jump to the next stage when it begins running Scrolling down to the bottom of a stage (or freestyle log) that's currently running should reactive karaoke. tscherler currently I think the code that "turns off karaoke" just calls `Pager.clear()` to turn off the auto fetch. So to satisfy above requirements, we probably need to make some changes so that "clear" doesn't stop auto-loading but changes whether the UI responds to new data by auto-scrolling to bottom or jumping to new stage. Does that sound correct?

          James Dumay added a comment -

          cliffmeyers thats spot on. I'd also say that when karaoke is paused:

          • Clicking on another active step reactivates karaoke

          James Dumay added a comment - cliffmeyers thats spot on. I'd also say that when karaoke is paused: Clicking on another active step reactivates karaoke

          Cliff Meyers added a comment -

          sophistifunk btw I linked two tickets to this one, JENKINS-43316 and JENKINS-43317. I know kzantow had been working on a significant refactor to Karaoke to resolve all these tickets, but I believe it still had some bugs in it. May want to touch base with him to see if that branch can be carried forward?

          Cliff Meyers added a comment - sophistifunk btw I linked two tickets to this one, JENKINS-43316 and JENKINS-43317 . I know kzantow had been working on a significant refactor to Karaoke to resolve all these tickets, but I believe it still had some bugs in it. May want to touch base with him to see if that branch can be carried forward?

          James Dumay added a comment -

          This no longer a problem

          James Dumay added a comment - This no longer a problem

          "Do not auto scroll to bottom as new log data is appended" is still an issue for me. This is very irritating, because our logs are extremely long and every time I try to scroll up (for example using the Home-key on the keyboard), it immediately scrolls all the way down again. Is this a known bug?

          Christian Ciach added a comment - "Do not auto scroll to bottom as new log data is appended" is still an issue for me. This is very irritating, because our logs are extremely long and every time I try to scroll up (for example using the Home-key on the keyboard), it immediately scrolls all the way down again. Is this a known bug?

          Josh McDonald added a comment -

          christianciach work on addressing these issues is currently in progress.

          Josh McDonald added a comment - christianciach work on addressing these issues is currently in progress.

            sophistifunk Josh McDonald
            cliffmeyers Cliff Meyers
            Votes:
            3 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: