Skip to content

NO-ISSUE: Remove dead code#6203

Open
pablintino wants to merge 1 commit into
openshift:mainfrom
pablintino:remove-deadcode
Open

NO-ISSUE: Remove dead code#6203
pablintino wants to merge 1 commit into
openshift:mainfrom
pablintino:remove-deadcode

Conversation

@pablintino

@pablintino pablintino commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

- What I did

This change removes dead code used for installed packages detection removed in
#5654.

- How to verify it

CI is enough.

- Description for the changelog

Remove dead code.

Summary by CodeRabbit

  • Refactor
    • Internal OS version detection and handling components have been reorganized to streamline the codebase.

This change removes dead code used for installed packages detection
removed in
openshift#5654.

Signed-off-by: Pablo Rodriguez Nava <git@amail.pablintino.eu>
@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: LGTM 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 Jun 17, 2026
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@pablintino: This pull request explicitly references no jira issue.

Details

In response to this:

- What I did

This change removes dead code used for installed packages detection removed in
#5654.

- How to verify it

CI is enough.

- Description for the changelog

Remove dead code.

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.

@coderabbitai

coderabbitai Bot commented Jun 17, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 1d9dd8c1-1d0a-45ee-b35a-19d9ad7d3ac0

📥 Commits

Reviewing files that changed from the base of the PR and between d0c3a5e and a552644.

📒 Files selected for processing (1)
  • pkg/daemon/rpm-ostree.go
💤 Files with no reviewable changes (1)
  • pkg/daemon/rpm-ostree.go

Walkthrough

Removes the exported DeploymentVersion struct, the NewTargetOSVersionFromDeployment constructor function, and the BaseVersionMajor, IsEL, and IsEL10 methods from pkg/daemon/rpm-ostree.go. No replacement declarations are introduced in this file.

Changes

DeploymentVersion Removal

Layer / File(s) Summary
Remove DeploymentVersion type and helpers
pkg/daemon/rpm-ostree.go
Deletes the exported DeploymentVersion struct, NewTargetOSVersionFromDeployment constructor, and BaseVersionMajor, IsEL, IsEL10 methods (32 lines removed, no replacements added).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~5 minutes

🚥 Pre-merge checks | ✅ 15
✅ Passed checks (15 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: removing dead code from the codebase, which aligns with the PR objectives.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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 All 218 Ginkgo test titles in the PR use stable, descriptive static strings with no dynamic content like generated suffixes, timestamps, UUIDs, or variable interpolation. Test names are compliant.
Test Structure And Quality ✅ Passed The PR only modifies non-test daemon code (pkg/daemon/rpm-ostree.go) and does not touch any Ginkgo test code. The custom check for Ginkgo test quality is not applicable to this PR.
Microshift Test Compatibility ✅ Passed PR removes dead code and adds only a standard unit test (not Ginkgo e2e tests), so the MicroShift e2e test compatibility check is not applicable.
Single Node Openshift (Sno) Test Compatibility ✅ Passed This PR removes dead code from pkg/daemon/rpm-ostree.go and does not add any new Ginkgo e2e tests. The SNO compatibility check only applies to PRs adding new tests.
Topology-Aware Scheduling Compatibility ✅ Passed PR removes dead code from rpm-ostree.go daemon utility. File contains no scheduling constraints, pod affinity, nodeSelectors, or topology-aware code. Not applicable to this check.
Ote Binary Stdout Contract ✅ Passed The PR removes dead code (DeploymentVersion struct and methods) from pkg/daemon/rpm-ostree.go. The file contains no process-level stdout writes (no init, main, TestMain, BeforeSuite/AfterSuite, or...
Ipv6 And Disconnected Network Test Compatibility ✅ Passed No new Ginkgo e2e tests are added in this PR. The PR only removes dead code (+0/-32) from pkg/daemon/rpm-ostree.go. The check is not applicable.
No-Weak-Crypto ✅ Passed The PR removes dead code (DeploymentVersion struct and related methods) unrelated to cryptography. Current rpm-ostree.go contains no weak crypto (MD5, SHA1, DES, RC4, 3DES, Blowfish, ECB), custom i...
Container-Privileges ✅ Passed PR removes dead code from Go source file (pkg/daemon/rpm-ostree.go), not container/K8s manifests. No privileged container configurations (privileged: true, hostPID, hostNetwork, hostIPC, SYS_ADMIN,...
No-Sensitive-Data-In-Logs ✅ Passed No sensitive data logging found. Removed code contains no logging statements; remaining logging statements in file are safe and appropriate.

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

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

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

@openshift-ci openshift-ci Bot requested review from ptalgulk01 and sergiordlr June 17, 2026 15:50
@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 17, 2026

@isabella-janssen isabella-janssen 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 Jun 18, 2026
@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Scheduling tests matching the pipeline_run_if_changed or not excluded by pipeline_skip_if_only_changed parameters:
/test e2e-aws-ovn
/test e2e-aws-ovn-upgrade
/test e2e-gcp-op-ocl-part1
/test e2e-gcp-op-ocl-part2
/test e2e-gcp-op-part1
/test e2e-gcp-op-part2
/test e2e-gcp-op-single-node
/test e2e-hypershift

@openshift-ci

openshift-ci Bot commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: isabella-janssen, pablintino

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:
  • OWNERS [isabella-janssen,pablintino]

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 Jun 18, 2026

Copy link
Copy Markdown
Contributor

@pablintino: The following tests 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/prow/e2e-gcp-op-ocl-part1 a552644 link true /test e2e-gcp-op-ocl-part1
ci/prow/e2e-gcp-op-part2 a552644 link true /test e2e-gcp-op-part2
ci/prow/e2e-aws-ovn-upgrade a552644 link true /test e2e-aws-ovn-upgrade
ci/prow/e2e-gcp-op-part1 a552644 link true /test e2e-gcp-op-part1
ci/prow/e2e-gcp-op-ocl-part2 a552644 link true /test e2e-gcp-op-ocl-part2
ci/prow/e2e-gcp-op-single-node a552644 link true /test e2e-gcp-op-single-node

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.

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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants