fix: Address go:generate flakiness by locally vendoring the used templates#15
Merged
fix: Address go:generate flakiness by locally vendoring the used templates#15
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR addresses CI flakiness by locally vendoring gowrap templates instead of fetching them from remote URLs during go:generate execution. The change prevents 403 errors that occur when the gowrap binary attempts to fetch templates from the gowrap repository during CI runs.
- Vendors timeout and retry templates locally in the
internal/adapter/helm/templates/directory - Updates
go:generatedirectives to reference local template files instead of remote URLs - Updates generated file headers to reflect the new local template paths
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| internal/adapter/helm/templates/timeout | Adds locally vendored timeout template for gowrap code generation |
| internal/adapter/helm/templates/retry | Adds locally vendored retry template for gowrap code generation |
| internal/adapter/helm/helm_timeout_gen.go | Updates template reference in generated file header to point to local path |
| internal/adapter/helm/helm_retry_gen.go | Updates template reference in generated file header to point to local path |
| internal/adapter/helm/helm.go | Updates go:generate directives to use local template files |
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.
This addresses an issue where go:generate sometimes fails during CI due to a 403. The cause comes from the gowrap binary fetching the template from the gowrap repo. The fix just vendors those templates locally.