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

[release-4.18] 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
    • Done
    • Bug Fix
    • Hide
      * Before this update, `OLMv1` was used to install Operators with the `olm.maxOpenShiftVersion` set to `4.19`. Because of an issue with the `OLMv1` parsing logic for floating-point formatted `olm.maxOpenShiftVersion`values, the system failed to prevent upgrades to {product-title} 4.20. With this release, the parsing logic for `olm.maxOpenShiftVersion` is corrected. As a result, this correction prevents upgrades to {product-title} 4.20 when Operators that include `olm.maxOpenShiftVersion:4.19` are installed. (link:https://issues.redhat.com/browse/OCPBUGS-57767[OCPBUGS-57767])
      Show
      * Before this update, `OLMv1` was used to install Operators with the `olm.maxOpenShiftVersion` set to `4.19`. Because of an issue with the `OLMv1` parsing logic for floating-point formatted `olm.maxOpenShiftVersion`values, the system failed to prevent upgrades to {product-title} 4.20. With this release, the parsing logic for `olm.maxOpenShiftVersion` is corrected. As a result, this correction prevents upgrades to {product-title} 4.20 when Operators that include `olm.maxOpenShiftVersion:4.19` are installed. (link: https://issues.redhat.com/browse/OCPBUGS-57767 [ OCPBUGS-57767 ])
    • None
    • None
    • None
    • None

      This is a clone of issue OCPBUGS-56825. The following is the description of the original issue:

      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: