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
Upgrade to Go 1.20.1 #44620
Upgrade to Go 1.20.1 #44620
Conversation
Hm... 🤔
Oh! Wonder if they (for the fallback) try to download |
`Not found in manifest. Falling back to download directly from Go' let version = makeSemver(candidate.version); goFile = candidate.files.find(file => {
core.debug(
`${file.arch}===${archFilter} && ${file.os}===${platFilter}`
);
return file.arch === archFilter && file.os === platFilter; So, hm.. at a cursory glance; they download https://go.dev/dl/?mode=json&include=all
|
LOL; this one is even more funny; this is the failure on Windows setting up Go;
"You had one job..." |
It looks like this is fundamentally actions/setup-go#63, which is pretty stalled out upstream. We can use the RC by modifying our version strings to match GHA's expectations, but I think this is another case for my plan to centralize the Go version somewhere and plumb it through with scripts. |
e56cbab
to
7d08fda
Compare
Okay, this is ready for review in the sense that while it should not be merged, we are seeing the real CI failures and can start addressing them. |
7d33e86
to
ece4f68
Compare
This one failure looks possibly genuine; I kicked ci at least once, but think it was the same failure first time;
|
Golangci-lint failure is likely because golangci is not yet compatible with go1.20 |
It looks like the OOM killer to me, though I'm not sure how to get dmesg from GHA without adding it as an explicit step (I'll try that next). I don't think golangci-lint should need explicit compatibility with Go 1.20, and there are no open issues on their tracker that correlate. Is this typical behavior during a Go upgrade? |
Haven't looked closely at the output. Perhaps you're right and I made the wrong assumption. It is common though that golangci-lint fails to complete successfully on Go updates (although usually it gives an informative error message). We could try running it locally in a go1.20 container |
The test failure could be string matching; I think those status code are based on output of "why the command failed" (it's ugly, but don't think there's better solutions for some of that); perhaps the error response from Golang was updated. I recently made some updates in that area in #43248 edit: code is here; Lines 183 to 201 in 6d212fa
|
rc3 is available now |
daemon/errors.go
Outdated
// syscall.EACCESS to syscall.EISDIR. Unfortunately docker/cli checks | ||
// whether the error message contains syscall.EACCESS.Error() to | ||
// determine whether to exit with code 126 or 125, so we have little |
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.
For reference, this is the offending docker/cli code.
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.
Oh my god, when I glanced at this failure, I thought it might be something like that, but I did not fully comprehend the magnitude of coupling.
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.
daemon/errors.go
Outdated
// Go 1.20 changed the error for attempting to execute a directory from | ||
// syscall.EACCESS to syscall.EISDIR. Unfortunately docker/cli checks |
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.
This is a compatibility issue which manifests when runc is compiled against Go 1.20, irrespective of the Go version that Moby is compiled with.
The |
Some questions;
|
Yes, through a long causal chain. golangci-lint had to be bumped to a version which supports Go 1.20. The bumped golangci-lint flagged a loop-closure bug in the
That depends on your opinions on test-driven development. I feel it would be dishonest to invert the history, fixing things before they could have been known to be broken.
Yes, all the changes could be backported. |
Only in this case, such changes were not due to the Go update, but because we updated a linter? I can see where you're coming from, but I think "rewriting history" is already something we done with our rebase+squash/cleanup based workflow, that that should not be an issue. W.r.t. an "honest history"; where suitable, we can of course still include a mention of Go and/or Golang-CI versions in the commit message ("Older versions of GolangCI did not catch this error", or "In preparation of newer Go versions, which no longer allow this") What we tended to do in the past is to;
Most of the time we did the preparation steps in a separate PR, both for visibility, as well as make backporting those changes to release branch(es) non-ambiguous (including it in the same PR as the Go update could otherwise mean "this is a partial backport, with commits X Y and Z omitted"). In this approach;
|
@thaJeztah you make a very compelling argument. I've captured that in the repo wiki for the benefit of the next person to take on the task of bumping the Go version. |
Signed-off-by: Bjorn Neergaard <bneergaard@mirantis.com> Co-authored-by: Cory Snider <csnider@mirantis.com> Signed-off-by: Cory Snider <csnider@mirantis.com>
Signed-off-by: Cory Snider <csnider@mirantis.com>
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
LGTM |
Changes to enable Go 1.20; @corhere has taken over this PR.
Prerequisites: