This repository has been archived by the owner on Oct 10, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 192
[Tooling] Remove use of -compat flag for go mod #3570
Merged
Merged
Conversation
This file contains 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
randomvariable
approved these changes
Oct 6, 2022
anujc25
approved these changes
Oct 6, 2022
We're going to hold on this as the change to Go 1.18 may be reverted by #3571 |
vuil
approved these changes
Oct 7, 2022
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!
Fixes vmware-tanzu#3569 Now that we use go.18 for all our modules, the -compat flag is no longer useful. Signed-off-by: Marc Khouzam <kmarc@vmware.com>
62c551a
to
6ef7f9c
Compare
Now that #3577 has been merged, we should go ahead and do this cleanup. |
Codecov Report
@@ Coverage Diff @@
## main #3570 +/- ##
==========================================
- Coverage 46.31% 45.44% -0.88%
==========================================
Files 400 425 +25
Lines 39583 41147 +1564
==========================================
+ Hits 18334 18698 +364
- Misses 19563 20747 +1184
- Partials 1686 1702 +16
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
# for free
to subscribe to this conversation on GitHub.
Already have an account?
#.
Labels
CI
cla-not-required
ok-to-merge
PRs should be labelled with this before merging
priority/critical-urgent
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.
What this PR does / why we need it
Stop using the go mod
-compat
flag which was only useful when using Go 1.17.When we were using go 1.17, we decided to use the
-compat=1.17
flag ofgo mod
so as to use the pruned Go module graph introduced by Go 1.17. Details can be found in this Stack Overflow answer and in the Go documentation.Now that we are running Go 1.18 thanks to #3577,
go mod
will build the dependency graph for go 1.18 and 1.17, which both use the pruned graph.We therefore don't need to use the
-compat=1.17
flag anymore.Which issue(s) this PR fixes
Fixes #3569
Describe testing done for PR
Make sure to be running Go 1.18.
Apply this PR and run
make modules
and see that no files are changed.