Michael Matloob
Michael Matloob
cc @griesemer
AddNewRequire is documented to add the require to the last block and I think we should be careful when making changes to behavior like this. The go command only creates...
SetRequire and SetRequireSeparateIndirect are meant to be used by the go command. I think users that need to manually edit a `go.mod` file should use `AddRequire` but then run `go...
I don't think AddRequire should maintain the `// indirect` blocks. `go mod tidy` should do that. It should be okay to had AddRequire add an `// indirect` requirement to the...
We expect the `go` command to be used to tidy a `go.mod` file before it's released. That's the main supported use case. We provide the `x/mod` library to allow programatic...
I agree that the methods should result in a file that `go mod tidy` will handle. We should fix go mod tidy to move direct dependencies that appear in the...
Yes, we changed how the go command invokes the compiler: https://go.dev/cl/593156 changes the go command to always pass in a language version (which in gopath mode it sets to the...
> @matloob I think it would be more helpful if there were a way for us to specify the language version to the compiler in GOPATH mode. > > For...
cc @samthanawalla @rittneje I'm sorry, you're right. Looking at #60915, we decided to keep passing in language version go1.21 for GOPATH mode to avoid breaking compatibility. We'll fix this.
@rittneje That's a good point. My instinct is that we should still use "go1.21" as the language version passed to the compiler but I think there's no clear answer unfortunately....