Skip to content

🐛 fix(olm): improve error logging for missing olm.managed label #3558

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

Merged

Conversation

camilamacedo86
Copy link
Contributor

Previously, nonconforming CRDs (missing the label) were logged as INFO, but this caused the to enter a CrashLoopBackOff state due to unhandled inconsistencies.

This commit raises the log level to and enhances the message with actionable advice, clarifying that users should either delete CRDs for uninstalled solutions or label them appropriately.

The root cause of the scenario is: From an old release (ocp 4.15) the component managed by OLM should have the label olm.managed: true added to comply with the new checks.

@camilamacedo86 camilamacedo86 requested a review from bentito April 25, 2025 02:31
Previously, nonconforming CRDs (missing the  label) were logged as INFO,
but this caused the  to enter a CrashLoopBackOff state due to unhandled inconsistencies.

This commit raises the log level to  and enhances the message with actionable advice,
clarifying that users should either delete CRDs for uninstalled solutions or label them appropriately.

The root cause of the scenario is: From an old release (ocp 4.15) the component managed by OLM should have the label olm.managed: true added to comply with the new checks.
Copy link
Contributor Author

@camilamacedo86 camilamacedo86 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @tmshort and @bentito,

Since you preferred not to include the suggestion on how to fix the scenario, that part has been removed. However, just a few points to highlight:

  • The information about the GVR is already present
  • We should not remove the phrase "found nonconforming items", as that is essential for users to find the related KCS article and resolve the issue: KCS 7112019.

With these adjustments, I hope we can move forward with this small fix.
Could you please let me know if it has your LGTM/approval?

Thank you very much for your help and collaboration!

@bentito
Copy link
Contributor

bentito commented Apr 28, 2025

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Apr 28, 2025
@perdasilva perdasilva added this pull request to the merge queue Apr 28, 2025
github-merge-queue bot pushed a commit that referenced this pull request Apr 28, 2025
Previously, nonconforming CRDs (missing the  label) were logged as INFO,
but this caused the  to enter a CrashLoopBackOff state due to unhandled inconsistencies.

This commit raises the log level to  and enhances the message with actionable advice,
clarifying that users should either delete CRDs for uninstalled solutions or label them appropriately.

The root cause of the scenario is: From an old release (ocp 4.15) the component managed by OLM should have the label olm.managed: true added to comply with the new checks.
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Apr 28, 2025
@camilamacedo86 camilamacedo86 added this pull request to the merge queue Apr 28, 2025
Merged via the queue into operator-framework:master with commit 1d9eafd Apr 28, 2025
12 checks passed
@camilamacedo86 camilamacedo86 deleted the fix-message-error branch April 28, 2025 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants