Closed frankful closed 3 months ago
Hello, thank you for the bug report!
I'm confused by this error because I don't see any build comments in that file. Line 11 is an import of a package that also does not appear to have buildcomments.
I tried go install
and it works for me. Which version of Go are you running, and on which OS/arch ?
kubernetes 1.20 gitlab runner, ubuntu 18.04, golang 1.17.9
I tried this and it installed properly without any errors.
$ docker run -ti golang:1.17.9 go install gotest.tools/gotestsum@latest
It sounds like the error is described in this issue: https://github.com/golang/go/issues/51436
And this does reproduce it:
$ docker run -ti golang:1.16.9 go install gotest.tools/gotestsum@latest
Both Go1.16 and Go1.17 are past their EOL. The only supported Go versions are 1.21 and 1.20. I think the fix is to upgrade your version of Go.
Going to close this issue since I was not able to reproduce it.
$ go install gotest.tools/gotestsum@latest go: downloading gotest.tools/gotestsum v1.11.0 go: downloading gotest.tools v1.4.0 go: downloading gotest.tools v2.2.0+incompatible go: downloading github.com/dnephin/pflag v1.0.7 go: downloading github.com/fatih/color v1.15.0 go: downloading golang.org/x/tools v0.11.0 go: downloading github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 go: downloading github.com/bitfield/gotestdox v0.2.1 go: downloading golang.org/x/sync v0.3.0 go: downloading golang.org/x/term v0.10.0 go: downloading github.com/fsnotify/fsnotify v1.5.4 go: downloading golang.org/x/sys v0.10.0 go: downloading github.com/mattn/go-colorable v0.1.13 go: downloading github.com/mattn/go-isatty v0.0.19 go: downloading golang.org/x/text v0.11.0 go: downloading golang.org/x/mod v0.12.0 .go/pkg/mod/gotest.tools/gotestsum@v1.11.0/testjson/format.go:11:2: //go:build comment without // +build comment