Skip to content

Add release-info plugin#458

Open
enxebre wants to merge 1 commit into
openshift-eng:mainfrom
enxebre:enxebre/release-info-plugin
Open

Add release-info plugin#458
enxebre wants to merge 1 commit into
openshift-eng:mainfrom
enxebre:enxebre/release-info-plugin

Conversation

@enxebre
Copy link
Copy Markdown
Collaborator

@enxebre enxebre commented May 11, 2026

Summary

  • Adds release-info plugin with four capabilities for OCP release lifecycle queries:
    • Product Pages MCP server for schedules, milestones, GA dates, and contacts
    • pr-to-release-version skill to trace a GitHub PR to its first shipped z-stream
    • upgrade-path skill to query Cincinnati for available upgrade paths between versions
    • update-graph skill to generate links to the interactive upgrade graph visualizer

Examples

Ask in natural language — the plugin picks the right tool automatically.

Release schedules and milestones (Product Pages)

  • "When is the GA date for OCP 4.18?"
  • "What's the feature freeze date for 4.17?"
  • "Show me the full schedule for OCP 4.21"
  • "Who is the TPM for OpenShift Container Platform?"
  • "What releases are currently in development?"

Tracing a PR to a release (pr-to-release-version)

Upgrade paths (upgrade-path)

  • "What upgrades are available from 4.16.3?"
  • "Can a cluster on 4.16.3 upgrade to 4.17.8?"
  • "Is 4.17.12 in the stable channel?"
  • "Show upgrade paths from 4.14.10 on arm64"

Upgrade graph visualization (update-graph)

  • "Show me the upgrade graph for 4.17"
  • "Visualize the fast channel for 4.16"

Combining tools

  • "My fix is in PR #7685 on openshift/hypershift. Has it shipped in 4.21, and can customers on 4.21.10 upgrade to get it?"
  • "When is 4.18 GA, and what does the current upgrade graph look like for the stable channel?"

Test plan

  • Enable the plugin and verify Product Pages MCP tools are available after auth
  • Run pr-to-release-version with a known merged PR and verify correct z-stream output
  • Run upgrade-path with a known version and verify Cincinnati results
  • Ask for upgrade graph visualization and verify correct ctron.github.io URL is generated
  • Verify make lint passes with zero errors and warnings

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features

    • Introduced release-info plugin with three capabilities: trace GitHub PRs to their first shipped OCP z-stream release, query OpenShift upgrade paths and available updates, and generate links to the interactive OCP update graph visualizer.
  • Documentation

    • Added comprehensive documentation for the release-info plugin and its skills.

@openshift-ci openshift-ci Bot requested review from Prashanth684 and brandisher May 11, 2026 10:47
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented May 11, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: enxebre

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 May 11, 2026
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 11, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 2d58b897-9466-487b-8de1-200575f00143

📥 Commits

Reviewing files that changed from the base of the PR and between f5d8f77 and 4fd71e8.

📒 Files selected for processing (11)
  • .claude-plugin/marketplace.json
  • .skillsaw.yaml
  • docs/data.json
  • plugins/release-info/.claude-plugin/plugin.json
  • plugins/release-info/.mcp.json
  • plugins/release-info/README.md
  • plugins/release-info/skills/pr-to-release-version/SKILL.md
  • plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh
  • plugins/release-info/skills/update-graph/SKILL.md
  • plugins/release-info/skills/upgrade-path/SKILL.md
  • plugins/release-info/skills/upgrade-path/upgrade-path.sh
✅ Files skipped from review due to trivial changes (6)
  • plugins/release-info/.claude-plugin/plugin.json
  • .claude-plugin/marketplace.json
  • plugins/release-info/README.md
  • .skillsaw.yaml
  • plugins/release-info/skills/update-graph/SKILL.md
  • plugins/release-info/skills/upgrade-path/SKILL.md
🚧 Files skipped from review as they are similar to previous changes (4)
  • plugins/release-info/.mcp.json
  • plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh
  • docs/data.json
  • plugins/release-info/skills/upgrade-path/upgrade-path.sh

Walkthrough

Adds a new "release-info" Claude plugin (v0.0.1): registers the plugin, adds MCP config for Product Pages, documentation, three auto-applying skills (pr-to-release-version, upgrade-path, update-graph), two shell scripts (PR tracing and Cincinnati queries), and a minor skillsaw allowlist change.

Changes

Release-Info Plugin Addition

Layer / File(s) Summary
Plugin Manifest
plugins/release-info/.claude-plugin/plugin.json
New manifest: name: release-info, description, version: 0.0.1, author.name: github.com/openshift-eng.
Marketplace Registry
.claude-plugin/marketplace.json
Adds release-info entry pointing to ./plugins/release-info with description and version 0.0.1.
MCP Configuration
plugins/release-info/.mcp.json
Adds mcpServers.productpages HTTP target https://productpages.redhat.com/mcp with header X-MCP-Realm: urn:mcp:realm:private-core.
Docs Index
docs/data.json
Adds release-info plugin entry (version 0.0.1) with three skills: pr-to-release-version, update-graph, upgrade-path (no commands).
Plugin README
plugins/release-info/README.md
New README describing plugin capabilities, usage examples, prerequisites, and example prompts.
PR→Release Skill Doc
plugins/release-info/skills/pr-to-release-version/SKILL.md
Documents inputs, outputs, prerequisites, workflow and examples for locating the first z-stream that shipped a PR.
PR→Release Script
plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh
New Bash script: validates oc/gh/jq/curl and pull-secret, accepts PR URL/number + OCP minor (optional --repo), fetches PR via gh, maps repo→component via oc adm release info, enumerates z-streams for the minor, binary-searches z-streams comparing commits via GitHub API to find first shipped z-stream, prints verification URL.
Upgrade-Path Doc
plugins/release-info/skills/upgrade-path/SKILL.md
Documents Cincinnati-based upgrade-path skill, inputs (version, optional --channel/--arch/--to), outputs, and prerequisites.
Upgrade-Path Script
plugins/release-info/skills/upgrade-path/upgrade-path.sh
New Bash script: validates x.y.z version, derives default channel (stable-), requires curl/jq, fetches Cincinnati graph JSON, verifies source node, lists direct upgrade targets or checks reachability to --to, prints node/edge counts and visualizer link.
Update-Graph Doc
plugins/release-info/skills/update-graph/SKILL.md
Documents constructing links to the interactive update graph and channel naming conventions.
Lint/Policy Config
.skillsaw.yaml
Adds productpages to rules > mcp-prohibited > allowlist.

Sequence Diagrams

sequenceDiagram
    participant User
    participant PRScript as pr-to-release-version.sh
    participant GH as GitHub API
    participant OCP as OpenShift APIs
    participant Output

    User->>PRScript: PR URL/number + OCP minor
    PRScript->>PRScript: Validate tools & pull-secret
    PRScript->>GH: Fetch PR metadata
    GH->>PRScript: PR state, merge SHA
    PRScript->>OCP: Query release stream tags for minor
    OCP->>PRScript: Tags & payload pullspecs
    PRScript->>OCP: Map repo -> component (oc adm release info)
    OCP->>PRScript: Component name / payload commits
    PRScript->>PRScript: Enumerate candidate z-streams
    loop binary search over z-streams
        PRScript->>OCP: Get component commit from payload
        OCP->>PRScript: Commit reference
        PRScript->>GH: Compare merge commit vs payload commit
        GH->>PRScript: Comparison result
    end
    PRScript->>Output: First z-stream + payload commit + verify URL
Loading
sequenceDiagram
    participant User
    participant UpgradeScript as upgrade-path.sh
    participant Cincinnati as Cincinnati API
    participant Output

    User->>UpgradeScript: Source version + [--channel/--arch/--to]
    UpgradeScript->>UpgradeScript: Validate version & set defaults
    UpgradeScript->>Cincinnati: Fetch channel graph JSON
    Cincinnati->>UpgradeScript: Nodes & edges
    UpgradeScript->>UpgradeScript: Verify source node present
    alt --to provided
        UpgradeScript->>UpgradeScript: Check direct path to target
        UpgradeScript->>Output: Reachability + metadata
    else no target
        UpgradeScript->>UpgradeScript: List direct upgrade targets
        UpgradeScript->>Output: Available upgrades
    end
    UpgradeScript->>Output: Node/edge counts + visualizer link
Loading

Estimated Code Review Effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

🚥 Pre-merge checks | ✅ 9 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 12.50% 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 'Add release-info plugin' directly and clearly summarizes the main change: introducing a new release-info plugin with multiple capabilities (Product Pages MCP, pr-to-release-version, upgrade-path, update-graph skills).
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 Real People Names In Style References ✅ Passed No real people names used as style references. Only "ctron" (GitHub username) appears as technical attribution to an external visualization tool URL, not as style guidance.
No Assumed Git Remote Names ✅ Passed No hardcoded git remote names. Scripts use gh CLI and GitHub APIs. No git operations assume "origin" or "upstream".
Git Push Safety Rules ✅ Passed PR adds release-info plugin with three read-only skills for querying OCP release data. No git push, force push, or push to main/master operations found in any files.
No Untrusted Mcp Servers ✅ Passed PR introduces one HTTP MCP server (productpages.redhat.com) from trusted Red Hat domain. No npm packages, arbitrary installations, or untrusted sources. Server properly whitelisted.
Ai-Helpers Overlap Detection ✅ Passed No overlapping functionality. Three new skills use distinct APIs/purposes. Similarity scores: 46%, 18%, <10%. All 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

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


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

@enxebre enxebre closed this May 11, 2026
@enxebre enxebre reopened this May 11, 2026
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 7

🧹 Nitpick comments (3)
plugins/release-info/skills/upgrade-path/upgrade-path.sh (1)

64-67: ⚡ Quick win

Consider adding a timeout to the curl command.

Network issues could cause the script to hang indefinitely. Adding a timeout improves reliability.

Proposed fix
-if ! curl --silent --location --fail --header 'Accept:application/json' \
+if ! curl --silent --location --fail --max-time 30 --header 'Accept:application/json' \
   "${UPSTREAM}?channel=${CHANNEL}&arch=${ARCH}" -o "$OUTPUT"; then
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@plugins/release-info/skills/upgrade-path/upgrade-path.sh` around lines 64 -
67, The curl call that fetches the graph using UPSTREAM/CHANNEL/ARCH currently
has no timeout and can hang; update the curl invocation in upgrade-path.sh (the
command using variables UPSTREAM, CHANNEL, ARCH, OUTPUT) to include timeouts
such as --connect-timeout (e.g., 10) and --max-time (e.g., 30) and optionally a
small --retry (e.g., 3) so the script fails fast and then let the existing die
"Failed to fetch graph..." handle the error.
plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh (1)

78-79: ⚡ Quick win

Add timeout to curl command.

Network issues could cause the script to hang indefinitely when fetching release stream tags.

Proposed fix
-TAGS_JSON=$(curl -sf "${RELEASE_CONTROLLER}/api/v1/releasestream/4-stable/tags") \
+TAGS_JSON=$(curl -sf --max-time 30 "${RELEASE_CONTROLLER}/api/v1/releasestream/4-stable/tags") \
   || die "Failed to fetch release stream from ${RELEASE_CONTROLLER}"
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh`
around lines 78 - 79, The curl call that populates TAGS_JSON can hang on network
issues; update the TAGS_JSON assignment (the curl command used to fetch
"${RELEASE_CONTROLLER}/api/v1/releasestream/4-stable/tags") to include a timeout
option (e.g., curl --connect-timeout and/or --max-time or -m) so the command
fails fast and triggers the die fallback; ensure the added timeout values are
reasonable for your environment and keep the existing -s and -f flags so
failures still cause die "Failed to fetch release stream from
${RELEASE_CONTROLLER}".
plugins/release-info/README.md (1)

62-64: ⚡ Quick win

Add prerequisites documentation for the update-graph skill.

The pr-to-release-version (line 54) and upgrade-path (line 60) skills both document their prerequisites, but update-graph does not. For consistency and completeness, add a prerequisites line even if none are required (e.g., "Prerequisites: None (generates links only)").

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@plugins/release-info/README.md` around lines 62 - 64, Add a prerequisites
line under the "update-graph" section in README.md to match other skills; edit
the "### update-graph" block and insert a line like "Prerequisites: None
(generates links only)" immediately after the description so the section
documents prerequisites consistently with pr-to-release-version and
upgrade-path.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@plugins/release-info/.mcp.json`:
- Around line 1-11: The pipeline fails because the MCP server entry
"productpages" under the "mcpServers" object is not allowlisted; either remove
the "productpages" entry from the plugins/release-info .mcp.json mcpServers
object if Product Pages capability isn't needed for this release, or add
"productpages" to the central MCP server allowlist (the skillsaw/config that
holds allowed MCP servers) and coordinate any required approvals so the lint
will accept the new server name.

In `@plugins/release-info/README.md`:
- Around line 48-64: Add a new Skills subsection called "product-pages-mcp"
under the existing Skills section alongside pr-to-release-version, upgrade-path,
and update-graph; describe the Product Pages MCP capability and list
prerequisites (authentication requirements from the PR test plan such as
kubeconfig or token and any CLI/tools), include necessary setup steps for the
MCP server (install/configure MCP service, required config files, ports, and how
to authenticate), and reference the examples/overview so users can map the
documented prerequisites and setup to the Product Pages MCP examples shown
earlier.
- Line 27: The example under pr-to-release-version uses a Jira ID
("OCPBUGS-76447") which conflicts with the skill description for
pr-to-release-version that expects GitHub PR references; either replace that
example with a GitHub PR reference consistent with the other examples (e.g., use
a "PR `#1234`" style identifier) or explicitly document that Jira ticket lookups
are supported and describe how a Jira ID is resolved/mapped to the underlying
GitHub PR (add the mapping/lookup behavior and any required configuration).
Ensure the change updates the example line and the pr-to-release-version usage
description so examples and docs remain consistent.

In `@plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh`:
- Around line 33-38: The argument parsing loop handling the --repo flag does not
validate that a value follows the flag; update the while/case parsing (the case
for "--repo" that assigns REPO="$2") to check that $2 exists and is not another
flag before shifting; if the value is missing or looks like another option, call
usage (or print a clear error) and exit non-zero. Ensure you update the same
parsing block so REPO is only set when a valid value is present and the script
fails with a clear message when --repo is supplied without an argument.

In `@plugins/release-info/skills/pr-to-release-version/SKILL.md`:
- Around line 48-55: Update the fenced code block in SKILL.md to include a
language specifier so the linter stops warning; specifically change the opening
triple backticks that precede the PR example to ```text (the block containing
the PR/Merged/Component/First z-stream/Payload commit/Verification lines) so the
example is treated as plain text by the renderer and linter.

In `@plugins/release-info/skills/update-graph/SKILL.md`:
- Around line 22-24: The fenced code block in SKILL.md containing the URL
template lacks a language specifier; update that fenced block (the
triple-backtick block showing
"https://ctron.github.io/openshift-update-graph#<channel>") to include a
language token such as "text" or "plaintext" (e.g., change ``` to ```text) so
the linter warning is resolved.

In `@plugins/release-info/skills/upgrade-path/upgrade-path.sh`:
- Around line 39-46: The flag parsing in upgrade-path.sh currently does blind
shift 2 for --channel/--arch/--to which breaks under set -u when the next
argument is missing; update the case block that handles --channel, --arch and
--to to validate that a non-empty $2 exists and does not begin with -- before
performing shift 2, otherwise call usage or print a clear error like "Missing
value for --channel" and exit; reference the variables CHANNEL, ARCH, TARGET and
the usage function in your change so the script fails fast with a helpful
message rather than causing an undefined-variable error.

---

Nitpick comments:
In `@plugins/release-info/README.md`:
- Around line 62-64: Add a prerequisites line under the "update-graph" section
in README.md to match other skills; edit the "### update-graph" block and insert
a line like "Prerequisites: None (generates links only)" immediately after the
description so the section documents prerequisites consistently with
pr-to-release-version and upgrade-path.

In `@plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh`:
- Around line 78-79: The curl call that populates TAGS_JSON can hang on network
issues; update the TAGS_JSON assignment (the curl command used to fetch
"${RELEASE_CONTROLLER}/api/v1/releasestream/4-stable/tags") to include a timeout
option (e.g., curl --connect-timeout and/or --max-time or -m) so the command
fails fast and triggers the die fallback; ensure the added timeout values are
reasonable for your environment and keep the existing -s and -f flags so
failures still cause die "Failed to fetch release stream from
${RELEASE_CONTROLLER}".

In `@plugins/release-info/skills/upgrade-path/upgrade-path.sh`:
- Around line 64-67: The curl call that fetches the graph using
UPSTREAM/CHANNEL/ARCH currently has no timeout and can hang; update the curl
invocation in upgrade-path.sh (the command using variables UPSTREAM, CHANNEL,
ARCH, OUTPUT) to include timeouts such as --connect-timeout (e.g., 10) and
--max-time (e.g., 30) and optionally a small --retry (e.g., 3) so the script
fails fast and then let the existing die "Failed to fetch graph..." handle the
error.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: e8f183ae-a29b-468f-a3da-feb084cd1c18

📥 Commits

Reviewing files that changed from the base of the PR and between 0948119 and d2e7b04.

📒 Files selected for processing (9)
  • .claude-plugin/marketplace.json
  • plugins/release-info/.claude-plugin/plugin.json
  • plugins/release-info/.mcp.json
  • plugins/release-info/README.md
  • plugins/release-info/skills/pr-to-release-version/SKILL.md
  • plugins/release-info/skills/pr-to-release-version/pr-to-release-version.sh
  • plugins/release-info/skills/update-graph/SKILL.md
  • plugins/release-info/skills/upgrade-path/SKILL.md
  • plugins/release-info/skills/upgrade-path/upgrade-path.sh

Comment thread plugins/release-info/.mcp.json
Comment thread plugins/release-info/README.md
Comment thread plugins/release-info/README.md
Comment thread plugins/release-info/skills/pr-to-release-version/SKILL.md Outdated
Comment thread plugins/release-info/skills/update-graph/SKILL.md Outdated
Comment thread plugins/release-info/skills/upgrade-path/upgrade-path.sh
@enxebre enxebre force-pushed the enxebre/release-info-plugin branch from a468e28 to f5d8f77 Compare May 11, 2026 10:52
…ths, and PR-to-release tracing

Provides four capabilities for OCP release lifecycle queries:
- Product Pages MCP server for schedules, milestones, GA dates, and contacts
- pr-to-release-version skill to trace a PR to its first shipped z-stream
- upgrade-path skill to query Cincinnati for available upgrade paths
- update-graph skill to link to the interactive upgrade graph visualizer

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@enxebre enxebre force-pushed the enxebre/release-info-plugin branch from f5d8f77 to 4fd71e8 Compare May 11, 2026 11:01
@openshift-ci openshift-ci Bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label May 15, 2026
@openshift-ci
Copy link
Copy Markdown

openshift-ci Bot commented May 15, 2026

PR needs rebase.

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.

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. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant