Importing math/rand/v2, GCI wants the import in the second, no-standard-library, import block which is wrong:
Running [/home/runner/golangci-lint-1.56.2-linux-amd64/golangci-lint run --out-format=colored-line-number,github-actions --timeout 5m] in [] ...
provider/mqtt/client.go:6: File is not `gci`-ed with --skip-generated -s standard -s default (gci)
"math/rand/v2"
provider/mqtt/client.go:15: File is not `gci`-ed with --skip-generated -s standard -s default (gci)
"github.com/evcc-io/evcc/util/request"
hems/ocpp/ocpp.go:5: File is not `gci`-ed with --skip-generated -s standard -s default (gci)
"math/rand/v2"
Error: File is not `gci`-ed with --skip-generated -s standard -s default (gci)
Error: File is not `gci`-ed with --skip-generated -s standard -s default (gci)
Error: File is not `gci`-ed with --skip-generated -s standard -s default (gci)
Welcome
Description of the problem
Importing
math/rand/v2
, GCI wants the import in the second, no-standard-library, import block which is wrong:Running with
--fix
produces imports like:Reproed locally, so not depending on action.
Version of golangci-lint
Configuration
.
Go environment
Verbose output of running
A minimal reproducible example or link to a public repository
https://github.com/evcc-io/evcc/commit/ad0c6d5eb1363e2ba554c3bbb30aac07798171f9
Validation