Merge pull request #17027 from rook/mergify/bp/release-1.18/pr-17022

osd: fix updateExistingOSDs function for cancelled context (backport #17022)
This commit is contained in:
Blaine Gardner authored and GitHub committed 2026-02-05 09:41:28 -07:00
commit be28d8506a
1 file changed
+4
+4
View File
@@ -237,6 +237,10 @@ func WaitForDeploymentsToUpdate(
waitFunc := func() (done bool, err error) {
deployments, err := listFunc()
if err != nil {
// if the context got cancelled, then no need to wait or retry.
if errors.Is(err, context.Canceled) {
return true, errors.Wrap(err, "failed to list deployments due to context cancellation")
}
return false, errors.Wrap(err, "failed to list deployments")
}
if len(deployments.Items) < len(waitingOn) {