Skip to content

Add ability to search log header line

Payton Burdette requested to merge 408443-search-by-section-header into master

What does this MR do and why?

Previously users could not search a string that would highlight a collapsible job log line header. This MR fixes that issue by identifying the object format of a line header and making that data available to highlight the correct line.

This MR should

  1. Give users the ability to highlight lines that are collapsible sections.
  2. Ensure users can still highlight all other lines (plain lines, collapsed lines)
  3. Ensure that log line hash highlighting still works.

Screenshots or screen recordings

Screenshot_2023-08-21_at_3.56.23_PM

How to set up and validate locally

  1. Have a runner setup on GDK or a project with jobs/collapsible jobs
  2. View a job log
  3. Test out searching for line headers and normal lines

Here is a nice to have test job

large_log_output:
    stage: build
    script:
        - echo -e "\e[0Ksection_start:`date +%s`:my_first_section[collapsed=true]\r\e[0KHeader of the 1st collapsible section"
        - cat README.md
        - echo -e "\e[0Ksection_end:`date +%s`:my_first_section\r\e[0K"
        - echo "hello world!"

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #408443 (closed)

Edited by Payton Burdette

Merge request reports