Skip to content

Conversation

@grokspawn
Copy link
Contributor

Description

claude's uncoached solution for 1022. While this represents a compliant solution and possibly a minimalist one, it nonetheless establishes a new dimension instead of refactoring the existing mechanism to include the scenario.

Reviewer Checklist

  • API Go Documentation
  • Tests: Unit Tests (and E2E Tests, if appropriate)
  • Comprehensive Commit Messages
  • Links to related GitHub Issue(s)

Signed-off-by: grokspawn <jordan@nimblewidget.com>
Copilot AI review requested due to automatic review settings January 9, 2026 15:12
@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jan 9, 2026
@openshift-ci
Copy link

openshift-ci bot commented Jan 9, 2026

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign thetechnick for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@netlify
Copy link

netlify bot commented Jan 9, 2026

Deploy Preview for olmv1 ready!

Name Link
🔨 Latest commit 9bc40c9
🔍 Latest deploy log https://app.netlify.com/projects/olmv1/deploys/69611ae4909ce90008cc6438
😎 Deploy Preview https://deploy-preview-2436--olmv1.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR improves error messaging for resolution failures when upgrade constraints prevent finding a valid successor bundle. The implementation adds a new field to track whether upgrade policy enforcement is active and provides a more specific error message in this scenario.

  • Adds UpgradePolicyEnforced field to resolutionError struct to track when upgrade constraints are being applied
  • Implements specialized error message logic that clearly indicates when a desired version range doesn't match any valid successor
  • Updates test expectation to reflect the new, more descriptive error message format

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
internal/operator-controller/resolve/catalog.go Adds UpgradePolicyEnforced field to resolutionError and implements new error message path for upgrade constraint violations
internal/operator-controller/resolve/catalog_test.go Updates test expectation to match new error message format for upgrade constraint failure scenario

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Channels []string
InstalledBundle *ocv1.BundleMetadata
ResolvedBundles []foundBundle
UpgradePolicyEnforced bool
Copy link

Copilot AI Jan 9, 2026

Choose a reason for hiding this comment

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

The new field UpgradePolicyEnforced introduces additional state tracking into the error structure. While this field is correctly computed based on the upgrade policy and presence of an installed bundle, this represents adding a new dimension to track state that could alternatively be derived from existing fields (InstalledBundle != nil and comparing against the policy enum). Consider whether this field is necessary or if the error message generation logic could make the same determination from the existing fields to avoid redundant state tracking.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant