Skip to content

OKD-443: Fix pre-OSImageStreams node OS validation for OKD - #31621

Open
pskrbasu wants to merge 1 commit into
openshift:mainfrom
pskrbasu:fix-osimagestream-okd-main
Open

OKD-443: Fix pre-OSImageStreams node OS validation for OKD#31621
pskrbasu wants to merge 1 commit into
openshift:mainfrom
pskrbasu:fix-osimagestream-okd-main

Conversation

@pskrbasu

@pskrbasu pskrbasu commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Make validatePreOSImageStreamsNodeOS OKD-aware: check CoreOS 10 for OKD clusters instead of hardcoding CoreOS 9
  • Fixes the [sig-ci] [Early] prow job name should match os version test failure during 4.22→5.x OKD upgrades

Details

The validatePreOSImageStreamsNodeOS function hardcoded "CoreOS 9." which is correct for OCP (RHEL 9) but wrong for OKD, which was already using CoreOS 10 in pre-OSImageStreams versions like 4.22. During 4.22→5.0 OKD upgrades, the test correctly identified the cluster as pre-OSImageStreams (< 4.23) but then failed because the nodes were running CentOS Stream CoreOS 10, not CoreOS 9.

This is the main branch counterpart of openshift/origin#31592 (targeting release-5.0). The change is identical.

OCP behavior is unchanged — isOKD is false for OCP clusters, so targetVersion remains 9.

Test plan

  • go vet passes
  • Verify OKD SCOS upgrade jobs pass with this change
  • Verify OCP upgrade jobs are unaffected

References

Summary by CodeRabbit

  • Bug Fixes
    • Updated pre-OSImageStreams validation to correctly recognize the expected CoreOS version for OKD clusters.
    • Improved standalone node validation across supported cluster types by applying the appropriate operating system version expectations.

The validatePreOSImageStreamsNodeOS function hardcoded a check for
"CoreOS 9." which is correct for OCP but wrong for OKD, which was
already using CoreOS 10 in pre-OSImageStreams versions like 4.22.

This caused the "prow job name should match os version" test to fail
during 4.22→5.0 OKD upgrades: the test correctly identified the
cluster as pre-OSImageStreams (< 4.23) but then failed because the
nodes were running CentOS Stream CoreOS 10, not CoreOS 9.

Make validatePreOSImageStreamsNodeOS OKD-aware by accepting an isOKD
parameter and checking CoreOS 10 for OKD clusters. OCP behavior is
unchanged.
@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: automatic mode

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Sep 8, 2026
@openshift-ci-robot

openshift-ci-robot commented Sep 8, 2026

Copy link
Copy Markdown

@pskrbasu: This pull request references OKD-443 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "5.1.0" version, but no target version was set.

Details

In response to this:

Summary

  • Make validatePreOSImageStreamsNodeOS OKD-aware: check CoreOS 10 for OKD clusters instead of hardcoding CoreOS 9
  • Fixes the [sig-ci] [Early] prow job name should match os version test failure during 4.22→5.x OKD upgrades

Details

The validatePreOSImageStreamsNodeOS function hardcoded "CoreOS 9." which is correct for OCP (RHEL 9) but wrong for OKD, which was already using CoreOS 10 in pre-OSImageStreams versions like 4.22. During 4.22→5.0 OKD upgrades, the test correctly identified the cluster as pre-OSImageStreams (< 4.23) but then failed because the nodes were running CentOS Stream CoreOS 10, not CoreOS 9.

This is the main branch counterpart of openshift/origin#31592 (targeting release-5.0). The change is identical.

OCP behavior is unchanged — isOKD is false for OCP clusters, so targetVersion remains 9.

Test plan

  • go vet passes
  • Verify OKD SCOS upgrade jobs pass with this change
  • Verify OCP upgrade jobs are unaffected

References

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci
openshift-ci Bot requested review from deads2k and sjenning September 8, 2026 05:50
@coderabbitai

coderabbitai Bot commented Sep 8, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository YAML (base), Central YAML (inherited)

Review profile: CHILL

Plan: Advanced

Run ID: a90f0db5-3539-405e-a8b6-a0d0ad792a1b

📥 Commits

Reviewing files that changed from the base of the PR and between 514803e and 2d58875.

📒 Files selected for processing (1)
  • test/extended/ci/job_names.go

Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review.


Walkthrough

The pre-OSImageStreams node OS validation now selects CoreOS 10 for OKD clusters and CoreOS 9 for other clusters. The standalone node OS validation passes the cluster type to the updated validator.

Changes

Node OS validation

Layer / File(s) Summary
Dynamic CoreOS version validation
test/extended/ci/job_names.go
validatePreOSImageStreamsNodeOS accepts isOKD and builds the expected CoreOS version dynamically. validateStandaloneNodeOS passes the cluster type to this function. Comments reflect the OCP and OKD operating systems.

Estimated code review effort: 2 (Simple) | ~10 minutes

Merge Risk: ⚪ Minimal · up to 2d588

This updates OKD pre-OSImageStreams validation to expect CoreOS 10 while preserving CoreOS 9 validation for OCP. No current merge-blocking risk is evident.

Suggested reviewers: pablintino

🚥 Pre-merge checks | ✅ 14 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 1 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (14 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: fixing pre-OSImageStreams node OS validation for OKD.
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.
Stable And Deterministic Test Names ✅ Passed PASS. The pull request changes only test/extended/ci/job_names.go function logic, comments, and a call argument. The Describe and It titles are unchanged from the parent revision, and all titles…
Test Structure And Quality ✅ Passed The change does not introduce a failure under the stated test-quality rules. It updates one existing OS-version validation helper and its caller; it does not add an It block, resource creation, cleanu…
Microshift Test Compatibility ✅ Passed PASS: The pull request adds no new Ginkgo e2e tests. The diff only changes the existing validatePreOSImageStreamsNodeOS helper and its existing call site in test/extended/ci/job_names.go. Therefor…
Single Node Openshift (Sno) Test Compatibility ✅ Passed PASS: The pull request changes only test/extended/ci/job_names.go and adds no new Ginkgo It, Describe, Context, or When test. It updates the existing should match os version test's helper …
Topology-Aware Scheduling Compatibility ✅ Passed PASS: The pull request changes only test/extended/ci/job_names.go. It updates a test validation function to select CoreOS 9 or 10 based on isOKD and updates its call site. The diff adds no deploym…
Ote Binary Stdout Contract ✅ Passed The patch changes only test/extended/ci/job_names.go. It adds an isOKD parameter, computes a version, formats a Gomega assertion message, and updates a call inside `g.It("should match os version")…
Ipv6 And Disconnected Network Test Compatibility ✅ Passed PASS: The commit does not add a new Ginkgo test. It changes the existing should match os version test path and its helper to select CoreOS 9 or 10 based on isOKD. The added code contains no IPv4 l…
No-Weak-Crypto ✅ Passed PASS: The commit changes only test/extended/ci/job_names.go. It adds an isOKD boolean and selects CoreOS 9 or 10 with fmt.Sprintf; it adds no weak-crypto algorithm, custom cryptography, or secre…
Container-Privileges ✅ Passed PASS: The pull request changes only test/extended/ci/job_names.go. The added code changes OS-version validation and a function argument. The patch adds no container or Kubernetes manifest and contai…
No-Sensitive-Data-In-Logs ✅ Passed PASS: The pull request changes only OS-version validation logic and the related function call. It adds no logging or output of passwords, tokens, API keys, PII, session IDs, hostnames, or customer dat…
  • Fix all pre-merge checks with AI
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@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 Sep 8, 2026
@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Scheduling required tests:
/test e2e-metal-ipi-ovn-ipv6
/test e2e-vsphere-ovn
/test e2e-vsphere-ovn-upi

@pablintino

Copy link
Copy Markdown
Contributor

/lgtm

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

openshift-ci Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: pablintino, pskrbasu
Once this PR has been reviewed and has the lgtm label, please assign miyadav for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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 commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

@pskrbasu: all tests passed!

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.

@pskrbasu

pskrbasu commented Sep 8, 2026

Copy link
Copy Markdown
Contributor Author

/cc @miyadav

@openshift-ci
openshift-ci Bot requested a review from miyadav September 8, 2026 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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. 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.

3 participants