Skip to content

ci: check Jira MCP availability before staging payload reverts - #384

Merged
openshift-merge-bot[bot] merged 2 commits into
openshift-eng:mainfrom
stbenjam:must-jira
Mar 18, 2026
Merged

openshift-merge-bot[bot] merged 2 commits into
openshift-eng:mainfrom
stbenjam:must-jira

Conversation

@stbenjam

@stbenjam stbenjam commented Mar 17, 2026

Copy link
Copy Markdown
Member

Summary

  • Adds a preflight Jira MCP check (Step 1) in the stage-payload-reverts skill before launching subagents
  • If Jira MCP is unavailable, pauses and offers the user two options: fix and retry, or continue without Jira
  • When running autonomously (no user input available), defaults to continuing without Jira
  • Generalizes hardcoded MCP tool names to work with any Jira MCP server variant (official or sooperset)

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features

    • Added an interactive preflight that checks Jira availability with recovery options and graceful fallback.
    • Reworked payload-revert flow into an explicit multi-step sequence with clearer step numbering, improved error handling, and more resilient processing when Jira creation fails.
    • Expanded Jira creation inputs and clarified reporting/content for revert operations.
  • Chores

    • Version bumped to 0.0.31 across relevant manifests.

Add a preflight check (Step 1) in the stage-payload-reverts skill that
verifies the Jira MCP server is working before launching subagents. If
unavailable, the user is offered two options: fix the MCP config and
retry, or continue without Jira (skipping issue creation). When running
autonomously, defaults to continuing without Jira.

Also generalizes hardcoded MCP tool names (mcp__jira__jira_search, etc.)
to work with any Jira MCP server variant.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@openshift-ci
openshift-ci Bot requested review from LiangquanLi930 and zaneb March 17, 2026 19:03
@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 17, 2026
@coderabbitai

coderabbitai Bot commented Mar 17, 2026

Copy link
Copy Markdown
Contributor

Walkthrough

Version update from 0.0.30 to 0.0.31 across plugin manifests and docs. The stage-payload-reverts skill documentation was restructured to add a Step 1 Jira MCP availability preflight, renumber subsequent steps to Step 2–Step 5, replace specific Jira calls with generic MCP search/create tools, and update error-handling and reporting flows.

Changes

Cohort / File(s) Summary
Version Bumps
\.claude-plugin/marketplace.json, docs/data.json, plugins/ci/.claude-plugin/plugin.json
Plugin version incremented from 0.0.30 to 0.0.31 in marketplace, docs, and plugin manifest.
Skill Documentation
plugins/ci/skills/stage-payload-reverts/SKILL.md
Reworked workflow: added Step 1 preflight Jira MCP availability check with interactive recovery options; renumbered subsequent steps to 2–5; replaced specific Jira search/create calls with generic MCP search/create tools; expanded Jira creation fields; updated error-handling to continue on non-blocking failures and adjusted reporting/pr references.

Sequence Diagram(s)

sequenceDiagram
    rect rgba(220,220,255,0.5)
    participant Orchestrator
    end
    rect rgba(200,255,200,0.5)
    participant JiraMCP
    end
    rect rgba(255,220,220,0.5)
    participant Subagents
    end
    rect rgba(255,255,200,0.5)
    participant Repo
    end

    Orchestrator->>JiraMCP: Step 1 - Check MCP availability
    JiraMCP-->>Orchestrator: Available / Unavailable
    alt Available
        Orchestrator->>Subagents: Launch subagents (Steps 2–3)
        Subagents-->>Orchestrator: Candidate payloads
        Orchestrator->>JiraMCP: Search MCP / Create issue (Step 3)
        JiraMCP-->>Orchestrator: Issue key or failure
        Orchestrator->>Repo: Create revert PR (Step 4)
        Repo-->>Orchestrator: PR URL (Step 4/5)
        Orchestrator->>Orchestrator: Report results / HTML report (Step 5)
    else Unavailable
        Orchestrator->>Orchestrator: Offer recovery (Fix & retry / Continue without Jira)
        opt Continue without Jira
            Orchestrator->>Subagents: Launch subagents (Steps 2–3)
            Subagents-->>Orchestrator: Candidate payloads
            Orchestrator->>Repo: Create revert PRs without Jira (Step 4)
            Repo-->>Orchestrator: PR URLs
            Orchestrator->>Orchestrator: Report results / HTML report (Step 5)
        end
    end
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

🚥 Pre-merge checks | ✅ 8
✅ Passed checks (8 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the primary change: adding a Jira MCP availability check before staging payload reverts, which is the main objective documented in the PR.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
No Real People Names In Style References ✅ Passed Pull request contains only version bumps and expanded technical documentation with no real people names used as style references or examples.
No Assumed Git Remote Names ✅ Passed Comprehensive search of codebase found no hardcoded git remote names like 'origin' or 'upstream' used without discovery.
Git Push Safety Rules ✅ Passed Modified SKILL.md contains no git push commands, force push variants, or new autonomous push behavior. Changes add preflight Jira MCP check and reorganize steps; git push operations remain delegated to unchanged revert-pr skill.
No Untrusted Mcp Servers ✅ Passed The PR adds a preflight check for existing Jira MCP availability without installing new untrusted MCP servers or referencing arbitrary sources.
Ai-Helpers Overlap Detection ✅ Passed PR adds new preflight Jira MCP availability check with interactive recovery options; additive functionality with no overlapping patterns; overall similarity score ~15% well below 60% threshold.

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

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
📝 Coding Plan
  • Generate coding plan for human review comments

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

When the user chooses to continue without Jira, print the issue details
(project, type, summary, description, labels) for each candidate so the
user can create them manually.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@plugins/ci/skills/stage-payload-reverts/SKILL.md`:
- Around line 60-62: The fenced code block containing the JQL query (the block
that begins with ``` and has the line 'jql: project = TRT AND labels =
"trt-incident" AND description ~ "{pr_url}" ORDER BY created DESC') is missing a
language identifier and triggers markdownlint MD040; update the opening fence to
include the language identifier by changing the opening triple backticks to
specify "jql" (i.e., use ```jql) so the block is annotated correctly and the
linter warning is resolved.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 94457907-6790-4d00-bdc7-f7fd49d6aac0

📥 Commits

Reviewing files that changed from the base of the PR and between 3db197b and 57bcfde.

📒 Files selected for processing (4)
  • .claude-plugin/marketplace.json
  • docs/data.json
  • plugins/ci/.claude-plugin/plugin.json
  • plugins/ci/skills/stage-payload-reverts/SKILL.md

Comment on lines 60 to 62
```
jql: project = TRT AND labels = "trt-incident" AND description ~ "{pr_url}" ORDER BY created DESC
```

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Add a language identifier to the fenced JQL block.

Line 60 starts a fenced block without a language, which triggers markdownlint MD040.

Suggested fix
-```
+```jql
 jql: project = TRT AND labels = "trt-incident" AND description ~ "{pr_url}" ORDER BY created DESC
</details>

<details>
<summary>🧰 Tools</summary>

<details>
<summary>🪛 markdownlint-cli2 (0.21.0)</summary>

[warning] 60-60: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

</details>

</details>

<details>
<summary>🤖 Prompt for AI Agents</summary>

Verify each finding against the current code and only fix it if needed.

In @plugins/ci/skills/stage-payload-reverts/SKILL.md around lines 60 - 62, The
fenced code block containing the JQL query (the block that begins with and has the line 'jql: project = TRT AND labels = "trt-incident" AND description ~ "{pr_url}" ORDER BY created DESC') is missing a language identifier and triggers markdownlint MD040; update the opening fence to include the language identifier by changing the opening triple backticks to specify "jql" (i.e., usejql) so
the block is annotated correctly and the linter warning is resolved.


</details>

<!-- fingerprinting:phantom:poseidon:hawk -->

<!-- This is an auto-generated comment by CodeRabbit -->

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

♻️ Duplicate comments (1)
plugins/ci/skills/stage-payload-reverts/SKILL.md (1)

60-62: ⚠️ Potential issue | 🟡 Minor

Add a language identifier to the JQL fenced block.

Line 60 still uses an unlabeled fenced block; markdownlint MD040 expects a language tag (e.g., jql).

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@plugins/ci/skills/stage-payload-reverts/SKILL.md` around lines 60 - 62, The
fenced JQL block that currently contains the text "jql: project = TRT AND labels
= "trt-incident" AND description ~ "{pr_url}" ORDER BY created DESC" needs a
language identifier; update the opening triple-backtick fence to include the
language tag jql so the block becomes a labeled JQL code block (add the
identifier to the fenced block that wraps the shown JQL).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Duplicate comments:
In `@plugins/ci/skills/stage-payload-reverts/SKILL.md`:
- Around line 60-62: The fenced JQL block that currently contains the text "jql:
project = TRT AND labels = "trt-incident" AND description ~ "{pr_url}" ORDER BY
created DESC" needs a language identifier; update the opening triple-backtick
fence to include the language tag jql so the block becomes a labeled JQL code
block (add the identifier to the fenced block that wraps the shown JQL).

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 794e226b-34d5-4661-bf60-090113e9e0a0

📥 Commits

Reviewing files that changed from the base of the PR and between 57bcfde and 88b0b62.

📒 Files selected for processing (1)
  • plugins/ci/skills/stage-payload-reverts/SKILL.md

@smg247 smg247 left a comment

Copy link
Copy Markdown
Contributor

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 Mar 17, 2026
@openshift-ci

openshift-ci Bot commented Mar 17, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: smg247, stbenjam

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

@stbenjam

Copy link
Copy Markdown
Member Author

/override ci/prow/images

@openshift-ci

openshift-ci Bot commented Mar 18, 2026

Copy link
Copy Markdown
Contributor

@stbenjam: Overrode contexts on behalf of stbenjam: ci/prow/images

Details

In response to this:

/override ci/prow/images

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.

@openshift-merge-bot
openshift-merge-bot Bot merged commit 5eb0cfc into openshift-eng:main Mar 18, 2026
5 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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants