build: lint nested Go modules, and fix their findings #4809
All Vouch review confidence checks passed
Residual risk 0.17 = Change Risk (0.42) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.42 · 339 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.349
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #4809"
general
weight: 0.35
markmandel
<!-- Thanks for sending a pull request! Here are some tips for you:
1. If this is your first time, please read our contributor guidelines: https://github.com/agones-dev/agones/blob/main/CONTRIBUTING.md and developer guide https://github.com/agones-dev/agones/blob/main/build/README.md
2. Please label this pull request according to what type of issue you are addressing.
3. Ensure you have added or ran the appropriate tests for your PR: https://github.com/agones-dev/agones/blob/main/build/README.md#testing-and-building
-->
What type of PR is this?
/kind cleanup
What this PR does / Why we need it:
golangci-lint run ./...stops at module boundaries, so the 16 nested Go modules (examples, build tooling, site, test/upgrade) were never linted.make lintnow discovers every tracked nestedgo.modand lints each module from its own directory against the root config, withNESTED_LINT_EXCLUDEas an explicit opt-out, so new modules are linted by default.examples/autoscaler-wasmis linted for wasip1/wasm. The redundantgolangci-lint run ./examples/...pass is dropped, since./...already covers the examples in the root module.Fixes the findings in each module. Real bugs among them:
examples/autoscaler-webhook: missing return afterhttp.Errorled to a nil dereference on a bad request.test/upgrade: fivefmt.Errorfcalls dropped the wrapped error.build/scripts/k8s-export-openapi: the readiness probe leaked response bodies, and close errors on written files were ignored.buffer_sizeand autoscaler-webhookfixedReplicassilently overflowed int32; both now parse with a 32-bit limit.Rebuilds
examples/autoscaler-wasm/plugin.wasm, and bumps the versions of the examples whose source changed, along with the image references to them: allocation-endpoint 0.19, autoscaler-webhook 0.24, crd-client 0.27, custom-controller 0.15, simple-game-server 0.45, supertuxkart 0.26 and xonotic 2.9.Which issue(s) this PR fixes:
<!--
*Automatically closes linked issue when PR is merged.
Usage:
Closes #<issue number>, orCloses (paste link of issue).Use "Work on #<issue number>" if you wish to reference the issue without closing it.
-->
Work on #4421
Did you use AI tools in preparing this PR?:
<!--
If you used AI tools in preparing your PR, you must disclose this in the description of your PR.
--->
Y
Special notes for your reviewer:
Sorry about the large PR, couldn't think of another way to do it.