test(deps): name a talos/machinery version skew instead of failing inside talos - #7199
Conversation
…side talos talos and talos/pkg/machinery are released together and talos compiles against machinery's config API, but machinery is only an indirect requirement here. Any dependency that needs a newer machinery raises it silently, and the build then fails inside talos's own source with an error that never mentions the skew. A go.mod contract test now fails such a graph with both versions and the command that fixes it. It catches the live skew on the talos group PR (talos v1.15.0-alpha.0 against machinery at a later pseudo-version). Part of #6734 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011Aut24ni8XbKPYyY5mYrbb
Evidence at head
|
✅MegaLinter analysis: Success✅ Linters with no issuesactionlint, bash-exec, git_diff, hadolint, jscpd, jsonlint, lychee, markdown-table-formatter, markdownlint, prettier, prettier, shellcheck, shfmt, stylelint, syft, trivy-sbom, trufflehog, v8r, v8r, yamllint Notices
See detailed reports in MegaLinter artifacts
|
machinery is a direct requirement in the root go.mod, not an indirect one. The drift comes from minimal version selection treating every requirement as a floor, so the doc comment now says that. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011Aut24ni8XbKPYyY5mYrbb
Evidence at head
|
@coderabbitai review Generated by Claude Code |
|
✅ Action performedReview finished.
|
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Organization UI (inherited) Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review. 📜 Recent review details🧰 Additional context used📓 Path-based instructions (3)Use Go 1.26.1 or newer, matching the version declared in `go.mod`.📄 CodeRabbit inference engine (AGENTS.md) Files:
Generated files must not be hand-edited; run `make generate` as the canonical regeneration command.📄 CodeRabbit inference engine (AGENTS.md) Files:
Add regression tests for confident bug fixes and run flaky-test candidates repeatedly with `go test -run -count=10 ./...`.📄 CodeRabbit inference engine (AGENTS.md) Files:
🔇 Additional comments (3)
📝 WalkthroughWalkthroughThe change adds tests that compare the effective versions of the Talos and Talos machinery modules in Priority: ⬇️ Low Merge Risk: ⚪ Minimal · up to This change adds a test that fails with a clear message when the Talos SDK and Talos machinery module versions drift apart. It also adds explanatory comments. Runtime behavior and shipped code are unchanged, so there is no user or production impact, and the change is ready to merge. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 62.50% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 8 functions across 2 files. (1 skipped: 1 unsupported.) Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |

Why
The Talos SDK and its companion config module ship together and have to stay on the same version. Other dependencies can quietly move one of them forward without the other. When that happens, the build fails deep inside Talos's own code with an error that never says the two versions drifted apart, so every run has to work out the cause again from scratch.
What
Adds a check that fails as soon as the two versions differ. Its message names both versions and the command that fixes the drift. It already catches the drift on the open Talos group update.
Upgrading Talos itself and adapting to its new config layout remain blocked by the Kubernetes 0.37 wall (#7167 / #6728). This change delivers only the issue's anti-recurrence guard.
Part of #6734
🤖 Generated with Claude Code
https://claude.ai/code/session_011Aut24ni8XbKPYyY5mYrbb
Generated by Claude Code