-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Fix error message being lost when upgrading #6815
base: master
Are you sure you want to change the base?
Conversation
Fixes an issue where an error message was being discarded. Occurs when upgrading a bundle. Signed-off-by: Sebastian Soto <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
@saifshaikh48: changing LGTM is restricted to collaborators In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
@@ -451,7 +451,7 @@ func (c IndexImageCatalogCreator) UpdateCatalog(ctx context.Context, cs *v1alpha | |||
// check if index image adopts File-Based Catalog or SQLite index image format | |||
isFBCImage, err := fbcutil.IsFBC(ctx, c.IndexImage) | |||
if err != nil { | |||
return fmt.Errorf("error in upgrading the bundle %q that was installed traditionally", c.BundleImage) | |||
return fmt.Errorf("unable to determine if index image adopts File-Based Catalog or SQLite format: %v", err) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
consider including the index image in the error message.
e.g.
fmt.Errorf("unable to determine if index image %q adopts File-Based Catalog or SQLite format: %v", c.IndexImage, err)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if so, also update here
operator-sdk/internal/olm/operator/registry/index_image.go
Lines 429 to 433 in d2366be
// check if index image adopts File-Based Catalog or SQLite index image format | |
isFBCImage, err := fbcutil.IsFBC(ctx, c.IndexImage) | |
if err != nil { | |
return fmt.Errorf("unable to determine if index image adopts File-Based Catalog or SQLite format: %v", err) | |
} |
Issues go stale after 90d of inactivity. Mark the issue as fresh by commenting If this issue is safe to close now please do so with /lifecycle stale |
Description of the change:
Fixes an issue where an error message was being discarded. Occurs when upgrading a bundle.
Motivation for the change:
Checklist
If the pull request includes user-facing changes, extra documentation is required:
changelog/fragments
(seechangelog/fragments/00-template.yaml
)website/content/en/docs