-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Description
Welcome
- 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.).
- Yes, I've tried with the standalone linter if available (e.g., gocritic, go vet, etc.). (https://golangci-lint.run/usage/linters/)
Description of the problem
I tried this command from the documentation:
docker run --rm -v $(pwd):/app -v ~/.cache/golangci-lint/v1.52.2:/root/.cache -w /app golangci/golangci-lint:v1.52.2 golangci-lint run -v
and got:
docker run --rm -v :/app -v ~/.cache/golangci-lint/v1.52.2:/root/.cache -w /app golangci/golangci-lint:v1.52.2 golangci-lint run -v
level=info msg="[config_reader] Config search paths: [./ /app / /root]"
level=info msg="[lintersdb] Active 7 linters: [errcheck gosimple govet ineffassign staticcheck typecheck unused]"
level=info msg="[loader] Go packages loading at mode 575 (compiled_files|imports|deps|exports_file|files|name|types_sizes) took 8.145338ms"
level=info msg="[runner/filename_unadjuster] Pre-built 0 adjustments in 22.205µs"
level=error msg="[linters_context] typechecking error: pattern ./...: directory prefix . does not contain main module or its selected dependencies"
level=info msg="[linters_context/goanalysis] analyzers took 1.759882ms with top 10 stages: buildir: 287.268µs, fact_deprecated: 111.557µs, buildtag: 54.626µs, SA6005: 31.153µs, cgocall: 28.985µs, inspect: 28.296µs, asmdecl: 26.018µs, typecheck: 24.053µs, tests: 23.741µs, ineffassign: 23.476µs"
level=info msg="[runner] processing took 4.438µs with stages: max_same_issues: 868ns, nolint: 501ns, cgo: 409ns, skip_dirs: 331ns, max_from_linter: 254ns, source_code: 175ns, diff: 153ns, filename_unadjuster: 150ns, autogenerated_exclude: 145ns, exclude: 139ns, path_prettifier: 137ns, identifier_marker: 137ns, max_per_file_from_linter: 136ns, sort_results: 126ns, skip_files: 122ns, fixer: 115ns, severity-rules: 114ns, path_prefixer: 114ns, exclude-rules: 113ns, path_shortener: 102ns, uniq_by_line: 97ns"
level=info msg="[runner] linters took 4.255825ms with stages: goanalysis_metalinter: 4.074913ms"
level=info msg="File cache stats: 0 entries of total size 0B"
level=info msg="Memory: 2 samples, avg is 29.2MB, max is 31.4MB"
level=info msg="Execution took 15.36737ms"
make: *** [Makefile:23: lint-with-docker] Error 7
Docker logs:
time="2023-04-17T14:04:47.941844705+04:00" level=info msg="loading plugin \"io.containerd.event.v1.publisher\"..." runtime=io.containerd.runc.v2 type=io.containerd.event.v1
time="2023-04-17T14:04:47.941925337+04:00" level=info msg="loading plugin \"io.containerd.internal.v1.shutdown\"..." runtime=io.containerd.runc.v2 type=io.containerd.internal.v1
time="2023-04-17T14:04:47.941937421+04:00" level=info msg="loading plugin \"io.containerd.ttrpc.v1.task\"..." runtime=io.containerd.runc.v2 type=io.containerd.ttrpc.v1
time="2023-04-17T14:04:47.942049490+04:00" level=info msg="starting signal loop" namespace=moby path=/run/docker/containerd/daemon/io.containerd.runtime.v2.task/moby/091af21e3964551e840e60633bd21f18ab268884d3914f8fb70e0d2344d0b158 pid=4759 runtime=io.containerd.runc.v2
WARN[0000] file does not exist: /proc/sys/net/ipv6/conf/all/disable_ipv6 : stat /proc/sys/net/ipv6/conf/all/disable_ipv6: no such file or directory Has IPv6 been disabled in this node's kernel?
INFO[2023-04-17T14:04:48.318990863+04:00] shim disconnected id=091af21e3964551e840e60633bd21f18ab268884d3914f8fb70e0d2344d0b158
WARN[2023-04-17T14:04:48.319080572+04:00] cleaning up after shim disconnected id=091af21e3964551e840e60633bd21f18ab268884d3914f8fb70e0d2344d0b158 namespace=moby
INFO[2023-04-17T14:04:48.319103760+04:00] cleaning up dead shim
INFO[2023-04-17T14:04:48.319356812+04:00] ignoring event container=091af21e3964551e840e60633bd21f18ab268884d3914f8fb70e0d2344d0b158 module=libcontainerd namespace=moby topic=/tasks/delete type="*events.TaskDelete"
WARN[2023-04-17T14:04:48.329644274+04:00] cleanup warnings time="2023-04-17T14:04:48+04:00" level=info msg="starting signal loop" namespace=moby pid=5038 runtime=io.containerd.runc.v2
time="2023-04-17T14:06:55.995354180+04:00" level=info msg="loading plugin \"io.containerd.event.v1.publisher\"..." runtime=io.containerd.runc.v2 type=io.containerd.event.v1
time="2023-04-17T14:06:55.995444824+04:00" level=info msg="loading plugin \"io.containerd.internal.v1.shutdown\"..." runtime=io.containerd.runc.v2 type=io.containerd.internal.v1
time="2023-04-17T14:06:55.995468166+04:00" level=info msg="loading plugin \"io.containerd.ttrpc.v1.task\"..." runtime=io.containerd.runc.v2 type=io.containerd.ttrpc.v1
time="2023-04-17T14:06:55.995584723+04:00" level=info msg="starting signal loop" namespace=moby path=/run/docker/containerd/daemon/io.containerd.runtime.v2.task/moby/7bc375c054015e1ea19896ae5bfca1d658652b104f945e4c0fcf0f49142a283c pid=9998 runtime=io.containerd.runc.v2
WARN[0000] file does not exist: /proc/sys/net/ipv6/conf/all/disable_ipv6 : stat /proc/sys/net/ipv6/conf/all/disable_ipv6: no such file or directory Has IPv6 been disabled in this node's kernel?
Version of golangci-lint
1.52.2
Configuration file
Details
# https://golangci-lint.run/usage/configuration/#output-configuration
linters-settings:
gocyclo:
min-complexity: 25
goconst:
min-len: 2
min-occurrences: 3
misspell:
locale: UK
ignore-words:
- serialized # serialized is written with 'z' in the Nedap urls
- color # color is written like that in responses from Nedap APIs
- customized # customized is written like that in Nedap OpenAPI specs
- organization # organization is written like that in Nedap OpenAPI specs
- center # one of the libraries that we use have a word center
gosec:
config:
G101:
pattern: "(?i)passwd|pass|password|pwd|secret|token|apiKey|bearer|cred" # Default gosec pattern is used here, excluding `pw` match, because of false positives on variables with names like `nedaPWebhook` (https://github.com/securego/gosec/blob/2a4064d45d18fb7f192281f10dcff762629dca2c/rules/hardcoded_credentials.go#L120)
ignore_entropy: false
entropy_threshold: "80.0"
per_char_threshold: "3.0"
truncate: "16"
goimports:
local-prefixes: github.com/River-Island/svi-services
revive:
ignore-generated-header: true
lll:
# max line length, lines longer will be reported. Default is 120.
# '\t' is counted as 1 character by default, and can be changed with the tab-width option
line-length: 120
# tab width in spaces. Default to 1.
tab-width: 4
linters:
disable-all: true
enable:
- errcheck
- govet
- gocyclo
- unused
- ineffassign
- unconvert
- goconst
- gosimple
- staticcheck
- gosec
- tparallel
- nakedret
- gofmt
- gocognit
- godot
- misspell
- noctx
- nolintlint
- goimports
- revive
- lll
run:
deadline: 10m
skip-dirs:
- ".*\\testdata"
- ".*proto"
skip-files:
- ".*pb\\.go"
- ".*pb\\.gw\\.go"
- assets.go
output:
# colored-line-number|line-number|json|tab|checkstyle, default is "colored-line-number"
# format: checkstyle:lint-report.out
# print lines of code with issue, default is true
print-issued-lines: true
# print linter name in the end of issue text, default is true
print-linter-name: true
service:
golangci-lint-version: 1.50.x # use fixed version to not introduce new linters unexpectedly
prepare:
- echo "here I can run custom commands, but no preparation needed"Go environment
Details
go version go1.20.3 linux/amd64
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/vitaly/.cache/go-build"
GOENV="/home/vitaly/.config/go/env"
GOEXE=""
GOEXPERIMENT=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/home/vitaly/go/pkg/mod"
GONOPROXY="github.com/River-Island/*"
GONOSUMDB="github.com/River-Island/*"
GOOS="linux"
GOPATH="/home/vitaly/go"
GOPRIVATE="github.com/River-Island/*"
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/lib/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/lib/go/pkg/tool/linux_amd64"
GOVCS=""
GOVERSION="go1.20.3"
GCCGO="gccgo"
GOAMD64="v1"
AR="ar"
CC="x86_64-pc-linux-gnu-gcc"
CXX="x86_64-pc-linux-gnu-g++"
CGO_ENABLED="1"
GOMOD="/home/vitaly/p/ri/svi/serv/go.mod"
GOWORK=""
CGO_CFLAGS="-O2 -g"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-O2 -g"
CGO_FFLAGS="-O2 -g"
CGO_LDFLAGS="-O2 -g"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2250815872=/tmp/go-build -gno-record-gcc-switches"Verbose output of running
...
Code example or link to a public repository
The code is private.
Metadata
Metadata
Assignees
Labels
No labels