Skip to content

USHIFT-6847: Switch MicroShift CI doctor to use edge-tooling repository#77676

Merged
openshift-merge-bot[bot] merged 5 commits into
openshift:mainfrom
ggiguash:ci-doctor-edge-tooling
Apr 16, 2026
Merged

USHIFT-6847: Switch MicroShift CI doctor to use edge-tooling repository#77676
openshift-merge-bot[bot] merged 5 commits into
openshift:mainfrom
ggiguash:ci-doctor-edge-tooling

Conversation

@ggiguash

@ggiguash ggiguash commented Apr 11, 2026

Copy link
Copy Markdown
Contributor

Summary by CodeRabbit

  • Refactor

    • Renamed temp workdir prefix and added a centralized exit handler to consolidate artifact/report copying, archive session data, and signal availability only on success; handler now fails if no HTML report is produced.
  • Chores

    • Updated CI tooling source and job invocation behavior, added execution flag for approve/restart runs, and tightened AI integration permissions via a settings allowlist.
  • Bug Fixes

    • Normalized default AI model identifier.

@openshift-ci

openshift-ci Bot commented Apr 11, 2026

Copy link
Copy Markdown
Contributor

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@openshift-ci openshift-ci Bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Apr 11, 2026
@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash ggiguash force-pushed the ci-doctor-edge-tooling branch from 43bd361 to 40dd82d Compare April 11, 2026 06:16
@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash ggiguash force-pushed the ci-doctor-edge-tooling branch from 40dd82d to ae7ef75 Compare April 11, 2026 06:54
@coderabbitai

coderabbitai Bot commented Apr 11, 2026

Copy link
Copy Markdown
Contributor

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

Walkthrough

Consolidates exit handling into an atexit handler, renames WORKDIR prefix, expands artifact copying and session/report signaling, writes a Claude settings.json allowlist, changes Claude tool invocation and MCP scope, switches tooling repo to openshift-eng/edge-tooling, updates prow script invocations, and trims CLAUDE_MODEL default.

Changes

Cohort / File(s) Summary
CI Doctor Script Refactor & Exit Handling
ci-operator/step-registry/openshift/microshift/claude/ci-doctor/openshift-microshift-claude-ci-doctor-commands.sh
Replaced copy_reports() + trap with atexit_handler() and trap atexit_handler EXIT TERM INT. Renamed WORKDIR prefix to /tmp/microshift-ci-claude-workdir.... Moved artifact copying and HTML presence check into exit handler; copies *.html, *.json, *.txt to ${ARTIFACT_DIR}, *.html also to ${SHARED_DIR}, archives ${CLAUDE_HOME}/projects/ into ${ARTIFACT_DIR} and touches ${SHARED_DIR}/claude-session-available only on successful archive. Signals ${SHARED_DIR}/claude-report-available only if at least one HTML exists; otherwise reports error and returns non-zero. Removed inline post-run HTML check from main flow.
Claude Configuration & Permissions
ci-operator/step-registry/openshift/microshift/claude/ci-doctor/openshift-microshift-claude-ci-doctor-commands.sh
Disabled set -x while configuring credentials. Writes ${CLAUDE_HOME}/settings.json allowlist (tmp read/write, selected plugins/microshift-ci/scripts/* globs, certain shell utilities, and Skill(microshift-ci:...) entries). Adds --scope user to claude mcp add. Changes doctor invocation path from /analyze-ci:doctor to /microshift-ci:doctor.
Source & Automation Tooling Path Updates
ci-operator/step-registry/openshift/microshift/claude/ci-doctor/openshift-microshift-claude-ci-doctor-commands.sh
Stops cloning openshift/microshift; clones openshift-eng/edge-tooling into /tmp/edge-tooling and checks out the specific commit. Sets EXE_DIR under plugins/microshift-ci/scripts. Updates prow job script calls to use "${EXE_DIR}/prow-jobs-for-pull-requests.sh" and adds --execute to --mode approve and --mode restart invocations.
Step Ref YAML: CLAUDE_MODEL default
ci-operator/step-registry/openshift/microshift/claude/ci-doctor/openshift-microshift-claude-ci-doctor-ref.yaml
Changed environment variable default CLAUDE_MODEL from "claude-opus-4-6[1m]" to "claude-opus-4-6".

Sequence Diagram(s)

sequenceDiagram
    participant Runner as CI Script
    participant Repo as edge-tooling Repo / EXE_DIR
    participant Claude as Claude tool
    participant FS as Filesystem (WORKDIR / CLAUDE_HOME)
    participant Artifacts as ARTIFACT_DIR
    participant Shared as SHARED_DIR

    rect rgba(100,150,240,0.5)
    Runner->>Repo: clone `openshift-eng/edge-tooling` (set EXE_DIR)
    end

    rect rgba(120,200,140,0.5)
    Runner->>Claude: invoke `/microshift-ci:doctor` with `${CLAUDE_HOME}/settings.json`
    Claude->>FS: write projects and outputs (*.html, *.json, *.txt)
    end

    rect rgba(240,180,80,0.5)
    Note over Runner,Claude: On EXIT/TERM/INT atexit_handler runs
    Runner->>FS: archive `${CLAUDE_HOME}/projects/` → tarball in `${ARTIFACT_DIR}`
    Runner->>Artifacts: copy `*.html`, `*.json`, `*.txt`
    Runner->>Shared: copy `*.html`
    Runner->>Shared: touch `claude-session-available` (if archive ok)
    Runner->>Shared: touch `claude-report-available` (if HTML exists) else error
    end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

🚥 Pre-merge checks | ✅ 9 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 20.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (9 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title directly and clearly refers to the primary change: switching the MicroShift CI doctor to use the edge-tooling repository, which is the main modification across both modified files.
Stable And Deterministic Test Names ✅ Passed This PR contains only CI configuration files (bash script and YAML) with no Go test files or Ginkgo test definitions.
Test Structure And Quality ✅ Passed The PR modifies only shell scripts and YAML configuration files for MicroShift CI doctor tooling, not Ginkgo test code.
Microshift Test Compatibility ✅ Passed This PR contains only CI configuration and automation files (bash scripts and YAML registry configs), not Ginkgo test code.
Single Node Openshift (Sno) Test Compatibility ✅ Passed This pull request does not add any new Ginkgo e2e tests. The changes are limited to CI infrastructure and tooling configuration.
Topology-Aware Scheduling Compatibility ✅ Passed Files are CI/Prow infrastructure configuration for test execution with no Kubernetes deployment manifests, operator code, or scheduling constraints.
Ote Binary Stdout Contract ✅ Passed The OTE Binary Stdout Contract check is not applicable to this PR as it modifies bash scripts and YAML configuration files, not Go test code.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed The PR modifies CI/CD infrastructure files (shell script and YAML configuration) only; no new Ginkgo e2e tests are added.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@ggiguash ggiguash marked this pull request as ready for review April 11, 2026 06:55
@openshift-ci openshift-ci Bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Apr 11, 2026
@ggiguash ggiguash marked this pull request as draft April 11, 2026 06:55
@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-ci openshift-ci Bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Apr 11, 2026
@openshift-ci openshift-ci Bot requested review from agullon and jerpeter1 April 11, 2026 06:55
@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash ggiguash force-pushed the ci-doctor-edge-tooling branch from e581ff5 to ad47f52 Compare April 12, 2026 05:58
@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash ggiguash force-pushed the ci-doctor-edge-tooling branch from ad47f52 to 2a30cbd Compare April 12, 2026 06:21
@ggiguash ggiguash force-pushed the ci-doctor-edge-tooling branch from 133fdd7 to 49f9db5 Compare April 16, 2026 08:11
@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

[REHEARSALNOTIFIER]
@ggiguash: the pj-rehearse plugin accommodates running rehearsal tests for the changes in this PR. Expand 'Interacting with pj-rehearse' for usage details. The following rehearsable tests have been affected by this change:

Test name Repo Type Reason
periodic-ci-openshift-microshift-main-ci-doctor N/A periodic Registry content changed
Interacting with pj-rehearse

Comment: /pj-rehearse to run up to 5 rehearsals
Comment: /pj-rehearse skip to opt-out of rehearsals
Comment: /pj-rehearse {test-name}, with each test separated by a space, to run one or more specific rehearsals
Comment: /pj-rehearse more to run up to 10 rehearsals
Comment: /pj-rehearse max to run up to 25 rehearsals
Comment: /pj-rehearse auto-ack to run up to 5 rehearsals, and add the rehearsals-ack label on success
Comment: /pj-rehearse list to get an up-to-date list of affected jobs
Comment: /pj-rehearse abort to abort all active rehearsals
Comment: /pj-rehearse network-access-allowed to allow rehearsals of tests that have the restrict_network_access field set to false. This must be executed by an openshift org member who is not the PR author

Once you are satisfied with the results of the rehearsals, comment: /pj-rehearse ack to unblock merge. When the rehearsals-ack label is present on your PR, merge will no longer be blocked by rehearsals.
If you would like the rehearsals-ack label removed, comment: /pj-rehearse reject to re-block merging.

@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@ggiguash ggiguash marked this pull request as ready for review April 16, 2026 12:08
@openshift-ci openshift-ci Bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Apr 16, 2026
@openshift-ci openshift-ci Bot requested review from pmtk and vanhalenar April 16, 2026 12:09
@ggiguash

Copy link
Copy Markdown
Contributor Author

/pj-rehearse ack

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

@ggiguash: now processing your pj-rehearse request. Please allow up to 10 minutes for jobs to trigger or cancel.

@openshift-merge-bot openshift-merge-bot Bot added the rehearsals-ack Signifies that rehearsal jobs have been acknowledged label Apr 16, 2026
@openshift-ci

openshift-ci Bot commented Apr 16, 2026

Copy link
Copy Markdown
Contributor

@ggiguash: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/rehearse/periodic-ci-openshift-microshift-main-ci-doctor 49f9db5 link unknown /pj-rehearse periodic-ci-openshift-microshift-main-ci-doctor

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@pmtk pmtk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Apr 16, 2026
@openshift-ci

openshift-ci Bot commented Apr 16, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ggiguash, 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-merge-bot openshift-merge-bot Bot merged commit 0b974dc into openshift:main Apr 16, 2026
11 of 12 checks passed
@ggiguash ggiguash deleted the ci-doctor-edge-tooling branch April 16, 2026 16:56
HarshwardhanPatil07 pushed a commit to HarshwardhanPatil07/release that referenced this pull request Apr 23, 2026
…ry (openshift#77676)

* Switch MicroShift CI doctor to use edge-tooling repository

* Change model to claude-opus-4-6

* Disable tracing in configure_claude function

* Add execute flag when restarting / approving PRs

* Add Claude tool error check
Prucek pushed a commit to Prucek/release that referenced this pull request Apr 29, 2026
…ry (openshift#77676)

* Switch MicroShift CI doctor to use edge-tooling repository

* Change model to claude-opus-4-6

* Disable tracing in configure_claude function

* Add execute flag when restarting / approving PRs

* Add Claude tool error check
BATMAN-JD pushed a commit to BATMAN-JD/release that referenced this pull request May 1, 2026
…ry (openshift#77676)

* Switch MicroShift CI doctor to use edge-tooling repository

* Change model to claude-opus-4-6

* Disable tracing in configure_claude function

* Add execute flag when restarting / approving PRs

* Add Claude tool error check
fjglira pushed a commit to fjglira/release that referenced this pull request Jun 3, 2026
…ry (openshift#77676)

* Switch MicroShift CI doctor to use edge-tooling repository

* Change model to claude-opus-4-6

* Disable tracing in configure_claude function

* Add execute flag when restarting / approving PRs

* Add Claude tool error check
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. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged. rehearsals-ack Signifies that rehearsal jobs have been acknowledged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants