Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Che operator olm files are mangled since 7.16.0 #17480

Closed
nickboldt opened this issue Jul 24, 2020 · 2 comments
Closed

Che operator olm files are mangled since 7.16.0 #17480

nickboldt opened this issue Jul 24, 2020 · 2 comments
Assignees
Labels
area/che-operator Issues and PRs related to Eclipse Che Kubernetes Operator kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.
Milestone

Comments

@nickboldt
Copy link
Contributor

nickboldt commented Jul 24, 2020

Comparing nightly olm file vs. 7.16.0, we see the formatting for embedded annotations has been mangled:

image

Also further down in the file we see another mangled formatting:

image

(this is comparing 7.15.2 and 7.16.0, so evidently this change happened some time after 7.15.2 was released.)

This looks to me like someone applied a yq transformation without using the yq -yY flags to preserve whitespace formatting.

@nickboldt nickboldt added the kind/bug Outline of a bug - must adhere to the bug report template. label Jul 24, 2020
@che-bot che-bot added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Jul 24, 2020
@nickboldt
Copy link
Contributor Author

nickboldt commented Jul 24, 2020

I think the reason the diff generator isn't reporting this problem is that we compute the diff BEFORE running addDigests.sh:

  cp ${LAST_NIGHTLY_CRD} ${RELEASE_CRD}
  if [[ $platform == "openshift" ]]; then
    yq -riSY  '.spec.preserveUnknownFields = false' ${RELEASE_CRD}
    yq -riSY  '.spec.validation.openAPIV3Schema.type = "object"' ${RELEASE_CRD}
    eval head -10 ${LAST_NIGHTLY_CRD} | cat - ${RELEASE_CRD} > tmp && mv tmp ${RELEASE_CRD}
  fi

  sed -e "s/${lastPackagePreReleaseVersion}/${RELEASE}/" "${packageFilePath}" > "${packageFilePath}.new"
  mv "${packageFilePath}.new" "${packageFilePath}"

  diff -u ${PRE_RELEASE_CSV} ${RELEASE_CSV} > ${RELEASE_CSV}".diff" || true
  diff -u ${PRE_RELEASE_CRD} ${RELEASE_CRD} > ${RELEASE_CRD}".diff" || true
done
cd "${CURRENT_DIR}"

source ${BASE_DIR}/addDigests.sh -w ${BASE_DIR} \
                -r "eclipse-che-preview-.*\.v${RELEASE}.*yaml" \
                -t ${RELEASE}

-- https://github.com/eclipse/che-operator/blob/master/olm/release-olm-files.sh

@tolusha tolusha removed their assignment Jul 24, 2020
@amisevsk amisevsk added severity/P1 Has a major impact to usage or development of the system. area/che-operator Issues and PRs related to Eclipse Che Kubernetes Operator and removed status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. labels Jul 24, 2020
@amisevsk
Copy link
Contributor

Setting as P1 since even though it does not impact usage, it's a build issue that could bite us.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/che-operator Issues and PRs related to Eclipse Che Kubernetes Operator kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.
Projects
None yet
Development

No branches or pull requests

5 participants