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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about deleting this version definition?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assuming that if the version is not set, the latest one will be used, I don't think it's a good idea, because this will mean that over time our CI will break on its own (as newer golangci-lint will update or add more linters which may result in linter warnings).
By pinning the version, we avoid that breakage. When we update the version, we check that everything works fine, or fix the new issues found. In the meantime, the CI works.
It's basically the same argument as in commit b24fc9d
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note though that I don't specify the patch version, meaning the latest patch version will be used (for example, when I specify v2.1, it will use v2.1.5 as of today). This is because I hope that the patch version bump won't introduce any breakage (while the minor version bump, such as switching from v2.2 to v2.3, might).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make sense, thanks your explanation.