You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yes, I'm using a binary release within 2 latest major releases. Only such installations are supported.
Yes, I've searched similar issues on GitHub and didn't find any.
Yes, I've included all information below (version, config, etc).
Please include the following information:
Version of golangci-lint
$ golangci-lint --versiongolangci-lint has version 1.27.0 built from fb74c2e on 2020-05-13T18:45:55Z
Config file
$ cat .golangci.ymlcat: .golangci.yml: No such file or directory
Go environment
$ go version && go envgo version go1.12 darwin/amd64GOARCH="amd64"GOBIN=""GOCACHE="/Users/eskwayrd/Library/Caches/go-build"GOEXE=""GOFLAGS=""GOHOSTARCH="amd64"GOHOSTOS="darwin"GOOS="darwin"GOPATH="/Users/eskwayrd/go"GOPROXY=""GORACE=""GOROOT="/usr/local/go"GOTMPDIR=""GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64"GCCGO="gccgo"CC="clang"CXX="clang++"CGO_ENABLED="1"GOMOD=""CGO_CFLAGS="-g -O2"CGO_CPPFLAGS=""CGO_CXXFLAGS="-g -O2"CGO_FFLAGS="-g -O2"CGO_LDFLAGS="-g -O2"PKG_CONFIG="pkg-config"GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/lj/fgm_6fb14qg5qc7871zj_9f80000gn/T/go-build790526519=/tmp/go-build -gno-record-gcc-switches -fno-common"
Verbose output of running
First run, no output specified:
$ golangci-lint cache clean
$ golangci-lint run test.goWARN [runner] Can't run linter goanalysis_metalinter: S1012: failed prerequisites: [(inspect@command-line-arguments, isgenerated@command-line-arguments): analysis skipped: errors in package: [/Users/eskwayrd/test.go:13:10: err declared but not used]] WARN [runner] Can't run linter unused: buildir: analysis skipped: errors in package: [/Users/eskwayrd/test.go:13:10: err declared but not used] ERRO Running error: buildir: analysis skipped: errors in package: [/Users/eskwayrd/test.go:13:10: err declared but not used]
Second run, setting the output format to json:
$ golangci-lint run --out-format json test.goWARN [runner] Can't run linter goanalysis_metalinter: S1033: failed prerequisites: [(inspect@command-line-arguments, isgenerated@command-line-arguments): analysis skipped: errors in package: [/Users/eskwayrd/test.go:13:10: err declared but not used]] WARN [runner] Can't run linter unused: buildir: analysis skipped: errors in package: [/Users/eskwayrd/test.go:13:10: err declared but not used] ERRO Running error: buildir: analysis skipped: errors in package: [/Users/eskwayrd/test.go:13:10: err declared but not used]
I would expect JSON output summarizing the errors, but no JSON is emitted.
Similarly, specifying any of the available output format causes the same output (as shown above) to be emitted every time.
If I'm doing something wrong, what is it?
The text was updated successfully, but these errors were encountered:
Only issue results are printed to stdout in the out format you choose. Errors are printed too stderr like in your example. I think what you are looking for is similar to this issue: #1043
Thank you for creating the issue!
Please include the following information:
Version of golangci-lint
Config file
Go environment
Verbose output of running
First run, no output specified:
Second run, setting the output format to
json
:I would expect JSON output summarizing the errors, but no JSON is emitted.
Similarly, specifying any of the available output format causes the same output (as shown above) to be emitted every time.
If I'm doing something wrong, what is it?
The text was updated successfully, but these errors were encountered: