Closed fmeum closed 2 weeks ago
Slightly related. Should the go.mod file be passed as dependency? For things like https://go.dev/blog/loopvar-preview the content of the go.mod file seems to determine the behavior.
From a rules_go users point of view. What is the capture behavior now when using Go 1.22+?
From a rules_go users point of view. What is the capture behavior now when using Go 1.22+?
rules_go currently always uses the Go language version corresponding to the version of the Go SDK.
Slightly related. Should the go.mod file be passed as dependency? For things like https://go.dev/blog/loopvar-preview the content of the go.mod file seems to determine the behavior.
I started working on this in https://github.com/bazel-contrib/rules_go/pull/4106, but haven't gotten around to finalizing the PR. If anyone wants to take a stab at this, please do.
What type of PR is this?
Bug fix
What does this PR do? Why is it needed?
go_tool_binary
used to non-hermetically pick up rules_go'sgo.mod
file when run unsandboxed, which resulted in it downloading a different toolchain and messing up version checks.Also make
nogo_main.go
compatible with Go 1.19 and test with nogo (which requires fixing a bunch of violations).Which issues(s) does this PR fix?
Fixes #
Other notes for review