![]() ![]() I will report the problem to the Go team.īeta Was this translation helpful? Give feedback. Nothing can be done inside golangci-lint because it's related to the management of transitive dependencies and remote download.įYI if you try to do a local go install. I suspect there's something that could be done about it within golangci-lint to avoid the issue. # /x/exp/constraints embedding interface element ~int|~int8|~int16|~int32|~int64 requires go1.18 or later (-lang was set to go1.16 check go.mod) embedding interface element ~uint|~uint8|~uint16|~uint32|~uint64|~uintptr requires go1.18 or later (-lang was set to go1.16 check go.mod) embedding interface element Signed|Unsigned requires go1.18 or later (-lang was set to go1.16 check go.mod) embedding interface element ~float32|~float64 requires go1.18 or later (-lang was set to go1.16 check go.mod) embedding interface element ~comple圆4|~complex128 requires go1.18 or later (-lang was set to go1.16 check go.mod) embedding interface element Integer|Float|~string requires go1.18 or later (-lang was set to go1.16 check go.mod) Im using golangci-lint version 1.32.2 This linter contains exhaustivestruct linter that I want to use (I dont want to exclude it). Can anyone recommend any solutions? I have reverted the version to 1.47.2 so it is okay at the moment for the pipeline. I have checked the library which presumably causing the error also has the go version 1.18 set in the mod file. Make: *** Error 2Įrror: Process completed with exit code 2. All options for golangci-lint are listed in this example. ![]() Main.Error: embedding interface element ~int|~int8|~int16|~int32|~int64 requires go1.18 or later (-lang was set to go1.16 check go.mod)Įrror: embedding interface element ~uint|~uint8|~uint16|~uint32|~uint64|~uintptr requires go1.18 or later (-lang was set to go1.16 check go.mod)Įrror: embedding interface element Signed|Unsigned requires go1.18 or later (-lang was set to go1.16 check go.mod)Įrror: embedding interface element ~float32|~float64 requires go1.18 or later (-lang was set to go1.16 check go.mod)Įrror: embedding interface element ~comple圆4|~complex128 requires go1.18 or later (-lang was set to go1.16 check go.mod)Įrror: embedding interface element Integer|Float|~string requires go1.18 or later (-lang was set to go1.16 check go.mod) golangci.yml in the root directory of the project allows for configuration of golangci-lint. Main.go:8:1: ''add' function first params should be Context (firstparamcontext) % ./golangci-lint/golangci-lint run -E firstparamcontext firstparamcontext: Checks that functions first param type is Context Disabled by your configuration linters: Linter.NewConfig(golinters.NewfirstparamcontextCheck()). We recommend using the nolint directive that we provide inside golangci-lint. The lint directive is something mainly specific to 'staticcheck the binary'. And all functions are not exported in 'staticcheck'. 紧接着在learn/json/linter/golangci-lint/pkg/lint/lintersdb/manager.go中引入,否则在命令行中看不到 Inside golangci-lint we use the sets of rules, not the binary. ).WithLoadMode(goanalysis.LoadModeSyntax) ![]() For example, you could use -s standard,default before, but now you must use -s standard -s default. Since v0.10.0, the -s and -section flag can only be used multiple times to specify multiple sections.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |