Repository navigation
ci: let the adapter build in a release PR, and rehearse that state on every change - #47
Merged
Merged
Conversation
… every change The 0.6.0 release PR (#43) failed "kube adapter (go)": gateway/kube/go.mod requires gateway v0.6.0, whose tag does not exist until the PR merges, and workspace mode still reads the required version's go.mod ("unknown revision gateway/v0.6.0"). main never requires an untagged version, so nothing caught it. - go.work replaces the core at exactly the version the adapter requires (Go refuses an unversioned replace of a workspace module). The line carries x-release-please-version, and Release Please updates /go.work with gateway/kube/go.mod. - .github/scripts/release-rehearsal.mjs applies Release Please's own version regex to every marked line with a version that is never tagged (0.999.0), vets and builds the adapter, and restores the files. It fails if go.work and the adapter's requirement disagree. It runs in CI's kube job and in task verify. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (5)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 |
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The 0.6.0 release PR (#43) fails "kube adapter (go)". With this merged, release-please regenerates #43 and it builds.
Cause
#42 made release-please rewrite the adapter's core requirement in every release PR, and that part worked: #43 moved
gateway/kube/go.modtogateway v0.6.0by itself. But a release PR names a version whose tag doesn't exist until it merges. In workspace mode Go still reads the required version'sgo.mod, so every vet, test and lint of the adapter failed withunknown revision gateway/v0.6.0.mainnever requires an untagged version, so no check before the merge could see this. That gap was mine.Fix
go.workreplaces the core at exactly the version the adapter requires. Go refuses a version-less replace of a module that's in the workspace, so the version is written out. The line is markedx-release-please-version, andrelease-please-config.jsonlists/go.work(repo root) as a second extra-file ofgateway/kube. Consumers never seego.work..github/scripts/release-rehearsal.mjs):0.999.0);go.workand the adapter's requirement disagree.It runs as the last step of CI's kube job and in
task verify.Verification
v0.6.0fixes all three.go.workreplace, it reproduces chore: release main #43's failure (unknown revision gateway/v0.999.0). With mismatched versions, it reports the drift.task verifypasses.After merging, check the regenerated #43: it should change both
gateway/kube/go.modandgo.worktov0.6.0, and its kube job should pass.🤖 Generated with Claude Code
Summary by CodeRabbit