I need to change the go version in go.mod from 1.22.3 to 1.22
Or write like this:
module main
go 1.22
toolchain go1.22.3
req...
After that, run go build, but when manually changing go build, it outputs:
go: updates to go.mod needed; to update it: go mod tidy
important: I can’t use 1.22.3, I need exactly 1.22 for the static analyzer, otherwise it won’t work.
I tried changing it with my hands or setting different flags during assembly. There is simply no ignoring this requirement. I can’t change the file just like that either, the go mod tidy requirement still appears.
user25297385 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.