Skip to content

fix(sdk): add validation to SetAnnotation to prevent infinite retry loop#4417

Merged
igooch merged 3 commits intoagones-dev:mainfrom
indurireddy-TF:fix/set-annotation-validation
Jan 14, 2026
Merged

fix(sdk): add validation to SetAnnotation to prevent infinite retry loop#4417
igooch merged 3 commits intoagones-dev:mainfrom
indurireddy-TF:fix/set-annotation-validation

Conversation

@indurireddy-TF
Copy link
Copy Markdown
Collaborator

What type of PR is this?

Uncomment only one /kind <> line, press enter to put that in a new line, and remove leading whitespace from that line:

/kind breaking

/kind bug

/kind cleanup
/kind documentation
/kind feature
/kind hotfix
/kind release

What this PR does / Why we need it:

Which issue(s) this PR fixes:

Closes #4409

Special notes for your reviewer:

@indurireddy-TF indurireddy-TF requested a review from igooch January 13, 2026 10:07
@github-actions github-actions bot added kind/bug These are bugs. size/S labels Jan 13, 2026
@agones-bot
Copy link
Copy Markdown
Collaborator

Build Succeeded 🥳

Build Id: 3ead908e-1d7a-48d7-9746-532fb1f04cef

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

git fetch https://github.com/googleforgames/agones.git pull/4417/head:pr_4417 && git checkout pr_4417
helm install agones ./install/helm/agones --namespace agones-system --set agones.image.registry=us-docker.pkg.dev/agones-images/ci --set agones.image.tag=1.55.0-dev-3c83d58

Copy link
Copy Markdown
Collaborator

@igooch igooch left a comment

Choose a reason for hiding this comment

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

LGTM. Waiting to officially approve and merge until after today's release.

return nil, status.Error(codes.InvalidArgument, "annotation key/value cannot be nil")
}

if errs := validation.IsQualifiedName(kv.Key); len(errs) > 0 {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

FYI: validation.IsQualifiedName will be deprecated in k8s.io/apimachinery v0.35. We are currently on v0.33 to align with our middle supported version of Kubernetes 1.33. We should migrate to the new function once our middle supported version shifts to 1.35, as the new function is not available until v0.35.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

@igooch Added TODO comments for post–Kubernetes 0.35 migration and will create a new issue to track this.

@indurireddy-TF indurireddy-TF self-assigned this Jan 14, 2026
@agones-bot
Copy link
Copy Markdown
Collaborator

Build Succeeded 🥳

Build Id: ca5d8ed1-49cb-49dc-8739-0613a19d52a5

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

git fetch https://github.com/googleforgames/agones.git pull/4417/head:pr_4417 && git checkout pr_4417
helm install agones ./install/helm/agones --namespace agones-system --set agones.image.registry=us-docker.pkg.dev/agones-images/ci --set agones.image.tag=1.56.0-dev-2cc4d85

Copy link
Copy Markdown
Collaborator

@igooch igooch left a comment

Choose a reason for hiding this comment

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

LGTM

@igooch igooch merged commit c5e95fd into agones-dev:main Jan 14, 2026
5 checks passed
mnthe pushed a commit to mnthe/agones that referenced this pull request Mar 23, 2026
…oop (agones-dev#4417)

* fix(sdk): add validation to SetAnnotation to prevent infinite retry loop

* add TODO for IsQualifiedName deprecation in k8s v0.35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/bug These are bugs. size/S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(sdk): validate labels in SetAnnotation to prevent retry loops

3 participants