Skip to content

Dark theme for CI Doctor report - #343

Merged
openshift-merge-bot[bot] merged 1 commit into
openshift-eng:mainfrom
pmtk:ci-doctor-dark-theme
Nov 19, 2026
Merged

openshift-merge-bot[bot] merged 1 commit into
openshift-eng:mainfrom
pmtk:ci-doctor-dark-theme

Conversation

@pmtk

@pmtk pmtk commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Summary by CodeRabbit

  • New Features
    • Added light, dark, and system theme options to reports, with accessible controls for switching modes.
    • Reports can restore a saved theme preference when available and adapt to changes in the system theme.
    • Charts and report elements update their colors to match the selected theme.

@openshift-ci

openshift-ci Bot commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: pmtk

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 19, 2026
@coderabbitai

coderabbitai Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review.

Walkthrough

The generated report now supports light, dark, and system themes. Theme variables cover report surfaces and controls. A controller restores and saves preferences, follows system changes, updates chart colors, and provides accessible theme buttons.

Changes

Report theming

Layer / File(s) Summary
Theme palettes and report styling
plugins/shared/scripts/create-report.py
Light and dark palettes provide colors for report content, charts, tables, and controls.
Theme selection and chart updates
plugins/shared/scripts/create-report.py
THEME_JS restores and saves preferences, responds to system changes and button clicks, and updates chart colors. The report loads the controller and passes it to PCP chart initialization.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Feature

Suggested reviewers: kasturinarra, redhat-chai-bot, suleymanakbas91

Merge Risk: Minimal · up to 3c385

The report gains light, dark and system themes through CSS variables and a small client-side controller. No concrete defect was identified, and the change is limited to generated report presentation, so merge risk is minimal.

Pre-merge checks: Passed 10

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title "Dark theme for CI Doctor report" matches the main change. The summary describes shared theme variables with light and dark palettes, a theme controller that selects system, light, or dark m…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
No-Weak-Crypto Passed The PR (openshift-eng/edge-tooling #343, author pmtk) changes one file, plugins/shared/scripts/create-report.py (+144/-62). The change adds a dark theme to the CI Doctor HTML report: CSS theme variabl…
Container-Privileges Passed The check is not applicable to this pull request. The reviewed range changes one file, plugins/shared/scripts/create-report.py (status M). It has no container or Kubernetes manifests. A search of th…
No-Sensitive-Data-In-Logs Passed The check flags logging that may expose passwords, tokens, API keys, PII, session IDs, internal hostnames, or customer data. PR #343 (openshift-eng/edge-tooling, author pmtk, head ci-doctor-dark-theme…
No-Hardcoded-Secrets Passed The check looks for hardcoded secrets in the PR's added lines. The only changed file is plugins/shared/scripts/create-report.py (M, one file). I searched the added lines for key, token, secret, passwo…
No-Injection-Vectors Passed The pull request changes one file, plugins/shared/scripts/create-report.py (+144/-62). It converts hard-coded colors to CSS variables, adds light/dark/system theme selection, and adds three theme butt…
Ai-Attribution Passed The check applies only when AI tools were used and that use is mentioned in the PR or its commits. Evidence gathered: - The PR (openshift-eng/edge-tooling #343, author pmtk) has one commit, "Dark them…
Full details: Title check

Explanation

The title "Dark theme for CI Doctor report" matches the main change. The summary describes shared theme variables with light and dark palettes, a theme controller that selects system, light, or dark mode, and theme buttons in the report page. The title names the primary feature and is short and specific, though it does not mention the controller or the system-mode option.

Full details: No-Weak-Crypto

Explanation

The PR (openshift-eng/edge-tooling #343, author pmtk) changes one file, plugins/shared/scripts/create-report.py (+144/-62). The change adds a dark theme to the CI Doctor HTML report: CSS theme variables, a theme controller that stores the user's light/dark/system preference, chart color updates, and theme buttons. A keyword search of the full patch for MD5, SHA1/SHA-1, DES, 3DES, RC4, Blowfish, ECB, cipher, HMAC, hashlib, crypto, and secret/token/password comparison returned no matches. The diff I read covers the CSS and theme-variable edits. It contains no hashing, encryption, or secret comparison code. The check's failure conditions (weak algorithms, custom crypto, non-constant-time secret comparison) do not apply to this change.

Full details: Container-Privileges

Explanation

The check is not applicable to this pull request. The reviewed range changes one file, plugins/shared/scripts/create-report.py (status M). It has no container or Kubernetes manifests. A search of that changed file found no privileged, hostPID, hostNetwork, hostIPC, SYS_ADMIN, allowPrivilegeEscalation, runAsUser, or securityContext content. The diff adds CSS, a theme controller, and chart callbacks for a dark theme. None of these changes matches a failure condition in the container-privileges check.

Full details: No-Sensitive-Data-In-Logs

Explanation

The check flags logging that may expose passwords, tokens, API keys, PII, session IDs, internal hostnames, or customer data. PR #343 (openshift-eng/edge-tooling, author pmtk, head ci-doctor-dark-theme) changes one file, plugins/shared/scripts/create-report.py. I searched the added lines for print, console, logging/logger, sys.stderr, and storage calls. None of the added lines add a new log or print statement. The only new storage use is localStorage.getItem/setItem in the theme controller, which stores a light/dark/system preference. That value is not sensitive and is not logged. The other changes replace hard-coded colors with CSS variables, pass an onChart callback to pcpCharts.init, and inject a theme script into the report head. None of these add logging of sensitive data, so the check passes.

Full details: No-Hardcoded-Secrets

Explanation

The check looks for hardcoded secrets in the PR's added lines. The only changed file is plugins/shared/scripts/create-report.py (M, one file). I searched the added lines for key, token, secret, password, credential, private key markers, base64-like runs over 32 characters, hex runs over 32 characters, URLs, and embedded credentials. The only hit was the localStorage key name 'ci-doctor-theme' used to store the theme preference. That is a UI setting name, not a secret. No API keys, tokens, passwords, private keys, base64 secrets, or credential-bearing URLs appear in the diff. Provider-reported PR: openshift-eng/edge-tooling #343, author pmtk. The check's failure conditions are not met.

Full details: No-Injection-Vectors

Explanation

The pull request changes one file, plugins/shared/scripts/create-report.py (+144/-62). It converts hard-coded colors to CSS variables, adds light/dark/system theme selection, and adds three theme buttons. I checked the full added and removed lines for the listed injection vectors. None are present: - No SQL string building or query execution. - No subprocess, os.system, or shell=True calls. - No eval, exec, or Function constructor. - No pickle, or yaml loading. - No innerHTML, outerHTML, insertAdjacentHTML, document.write, or dangerouslySetInnerHTML. The new text nodes and style assignments use static values. The new THEME_JS block is a static Python string embedded in a <script> tag. It reads only localStorage, matchMedia, and Chart.instances, and writes only theme attributes, chart colors, and aria-pressed. It does not interpolate report data. The only new interpolation, {THEME_JS}, inserts a constant string. The PR author is pmtk (provider-reported). The author does not affect this check.

Full details: Ai-Attribution

Explanation

The check applies only when AI tools were used and that use is mentioned in the PR or its commits. Evidence gathered: - The PR (openshift-eng/edge-tooling #343, author pmtk) has one commit, "Dark theme for CI Doctor report", authored by Patryk Matuszak. Its full commit message is only that title. It has no Assisted-by, Generated-by, or Co-Authored-By trailers. - The PR title and objectives do not mention any AI tool. - The only changed file is plugins/shared/scripts/create-report.py. A case-insensitive search of the diff for claude, copilot, gpt, openai, anthropic, generated, assisted, llm, cursor, and similar terms matched only the CSS word "cursor" (cursor: pointer). No AI tool reference appears in the code. - The "AI-generated summary" in the review input comes from the review tooling. It is not a PR or commit statement that AI tools wrote the change, so I did not treat it as a mention. With no AI tool use recorded in the PR or commits, the attribution requirements do not apply. No Co-Authored-By trailer exists for an AI tool, so nothing is flagged.

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 57b54db and 3c385b7.

Files selected for processing: 1

  • plugins/shared/scripts/create-report.py

Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 11 remain after this review.

@openshift-ci openshift-ci Bot added the ready-for-human-review Indicates a PR has been reviewed by automated tools and is ready for human review label Nov 19, 2026
@agullon

agullon commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Nov 19, 2026
@openshift-merge-bot
openshift-merge-bot Bot merged commit e7534c8 into openshift-eng:main Nov 19, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. ready-for-human-review Indicates a PR has been reviewed by automated tools and is ready for human review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants