Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-56825

[release-4.19] OLMv1: faulty parsing of olm.maxOpenShiftVersion allows cluster upgrades when they should be blocked

XMLWordPrintable

    • Quality / Stability / Reliability
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • Rejected
    • Lillipup Sprint 272
    • 1
    • In Progress
    • Bug Fix
    • Hide
      Previously, `OLMv1` was used to install Operators with the `olm.maxOpenShiftVersion` set to `4.19`. Due to an issue with the `OLMv1` parsing logic for floating-point formatted `olm.maxOpenShiftVersion`values, the system failed to prevent upgrades to Red Hat OpenShift 4.20. With this release, the parsing logic for `olm.maxOpenShiftVersion` has been corrected preventing upgrades to Red Hat OpenShift 4.20 when Operators with `olm.maxOpenShiftVersion:4.19` are installed. (link:https://issues.redhat.com/browse/OCPBUGS-56852[OCPBUGS-56852])
      Show
      Previously, `OLMv1` was used to install Operators with the `olm.maxOpenShiftVersion` set to `4.19`. Due to an issue with the `OLMv1` parsing logic for floating-point formatted `olm.maxOpenShiftVersion`values, the system failed to prevent upgrades to Red Hat OpenShift 4.20. With this release, the parsing logic for `olm.maxOpenShiftVersion` has been corrected preventing upgrades to Red Hat OpenShift 4.20 when Operators with `olm.maxOpenShiftVersion:4.19` are installed. (link: https://issues.redhat.com/browse/OCPBUGS-56852 [ OCPBUGS-56852 ])
    • None
    • None
    • None
    • None

      Our float parsing logic for olm.maxOpenShiftVersion has a bug related to floating-point math. For example:

      • 4.18 (float) parsed to 4.18.0 (semver), but
      • 4.19 (float) parsed to 4.20.0 (semver)

      This PR resolves that bug, adds regression tests, and also does some slight refactoring to make the overall max OCP version logic easier to understand for maintainers.

      This is reproducible on 4.19 using cluster-logging 6.2.2

       

       

              rh-ee-cchantse Catherine Chan-Tse
              openshift-crt-jira-prow OpenShift Prow Bot
              None
              None
              Xia Zhao Xia Zhao
              None
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: