-
Notifications
You must be signed in to change notification settings - Fork 10.2k
Use gomodguard to forbid dependencies #20748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use gomodguard to forbid dependencies #20748
Conversation
Signed-off-by: Ivan Valdes <[email protected]>
/cc @ahrtr @serathius /hold |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted filessee 29 files with indirect coverage changes @@ Coverage Diff @@
## main #20748 +/- ##
==========================================
+ Coverage 69.08% 69.17% +0.08%
==========================================
Files 422 422
Lines 34817 34819 +2
==========================================
+ Hits 24054 24086 +32
+ Misses 9360 9336 -24
+ Partials 1403 1397 -6 Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
5fb4af4
to
5c2cef3
Compare
I like this PR, and it is much better than #20721. One question: I see that https://github.com/ryancurrah/gomodguard has already been integrated into golangci-lint. Is it possible to define all the rules in .golangci.yaml? Note: I am not asking you to make the change. It's just a pure question for curiosity. |
Please refer to #20721 (comment)
|
Signed-off-by: Ivan Valdes <[email protected]>
5c2cef3
to
3062d2b
Compare
+1 for this change. that yaml configuration looks clean and straightforward. |
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.
LGTM
Thanks for keeping driving this. Great work!
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ahrtr, fuweid, ivanvc The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
As discussed in yesterday community, merging this PR, thx |
Alternative to depguard (#20721). Follow up on #20721 (comment).
Uses gomodguard stand-alone, as we can't hook it with golangci-lint, as it doesn't support receiving a list of modules or files to check.
I verified the linter fails, by doing #19423 (comment):
Result:
Please read https://github.com/etcd-io/etcd/blob/main/CONTRIBUTING.md#contribution-flow.