Skip to content

golangci-lint run Killed go1.13 #710

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
fredbi opened this issue Sep 17, 2019 · 1 comment
Closed

golangci-lint run Killed go1.13 #710

fredbi opened this issue Sep 17, 2019 · 1 comment
Labels
duplicate This issue or pull request already exists topic: memory Huge memory consumption
Milestone

Comments

@fredbi
Copy link

fredbi commented Sep 17, 2019

Please include the following information:
running golangci-lint run fails with "Killed" message after 40 seconds.

Notice that this works when pinning to release v1.18.0.

  1. Version of golangci-lint: golangci-lint --version (or git commit if you don't use binary distribution): fails to report on go1.13 (latest go getted master at now)
golangci-lint has version v1.18.0 built from (unknown, mod sum: "h1:XmQgfcLofSG/6AsQuQqmLizB+3GggD+o6ObBG9L+VMM=") 
  1. Config file: cat .golangci.yml
root@f5a1be35fb13:~/project# cat .golangci.yml       
linters-settings:
  govet:
    check-shadowing: true
  golint:
    min-confidence: 0
  gocyclo:
    min-complexity: 25
  maligned:
    suggest-new: true
  dupl:
    threshold: 100
  goconst:
    min-len: 3
    min-occurrences: 2

run:
  skip-dirs:
    - frontend

linters:
  enable:
    - golint
    - gocritic
    - stylecheck
    - goimports
    - gosec
    - nakedret
    - unconvert
    - unparam
  disable:
    - maligned
    - lll
    - gochecknoinits
    - gochecknoglobals

issues:
  # false negative error caused by golang-cilint
  # can be removed once the issue is fixed in golangcilint
  #  https://github:com/golangci/golangci-lint/issues/652:
  exclude:
    - "not declared by package utf8"
    - "unicode/utf8/utf8.go"
  1. Go environment: go version && go env
root@f5a1be35fb13:~/project# go version  && go env
go version go1.13 linux/amd64
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/root/.cache/go-build"
GOENV="/root/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/root/project/go.mod"
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 -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build138713511=/tmp/go-build -gno-record-gcc-switches" 
  1. Verbose output of running: golangci-lint run -v
root@f5a1be35fb13:~/project# golangci-lint run -v    
INFO [config_reader] Config search paths: [./ /root/project /root /] 
INFO [config_reader] Used config file .golangci.yml 
INFO [lintersdb] Active 18 linters: [deadcode errcheck gocritic goimports golint gosec gosimple govet ineffassign nakedret staticcheck structcheck stylecheck typecheck unconvert unparam unused varcheck] 
INFO [lintersdb] Optimized sublinters [staticcheck gosimple unused stylecheck] into metalinter megacheck 
INFO [loader] Go packages loading at mode 1023 (name|types|types_info|compiled_files|deps|exports_file|files|imports|syntax|types_sizes) took 3.361923086s 
INFO [loader] SSA repr building timing: packages building 68.486338ms, total 697.520642ms 
INFO [runner] worker.32 took 12.967µs             
INFO [runner] worker.7 took 835ns                 
INFO [runner] worker.8 took 2.667µs               
INFO [runner] worker.13 took 11.227µs             
INFO [runner] worker.9 took 502ns                 
INFO [runner] worker.28 took 29.8µs               
INFO [runner] worker.16 took 13.408µs             
INFO [runner] worker.20 took 977ns                
INFO [runner] worker.23 took 678ns                
INFO [runner] worker.4 took 495ns                 
INFO [runner] worker.14 took 18.175µs             
INFO [runner] worker.30 took 1.357µs              
INFO [runner] worker.15 took 17.468µs             
INFO [runner] worker.10 took 648ns                
INFO [runner] worker.21 took 17.416µs             
INFO [runner] worker.27 took 779ns                
INFO [runner] worker.26 took 4.809µs              
INFO [runner] worker.3 took 901ns                 
INFO [runner] worker.22 took 1.428µs              
INFO [runner] worker.2 took 1.003µs               
INFO [runner] worker.29 took 591ns                
INFO [runner] worker.19 took 5.658µs              
INFO [runner] worker.6 took 7.65763ms with stages: unconvert: 7.640161ms, typecheck: 3.623µs 
INFO [runner] worker.1 took 8.910038ms with stages: errcheck: 8.898945ms 
INFO [runner] worker.18 took 13.295328ms with stages: structcheck: 13.284892ms 
INFO [runner] worker.34 took 32.415622ms with stages: deadcode: 32.402702ms 
INFO [runner] worker.12 took 32.401323ms with stages: nakedret: 32.384942ms 
INFO [runner] worker.25 took 49.320629ms with stages: varcheck: 49.306878ms 
INFO [runner] worker.5 took 682.569249ms with stages: gocritic: 682.532482ms 
INFO [runner] worker.33 took 1.306905354s with stages: ineffassign: 1.306897547s 
INFO [runner] worker.24 took 1.593554015s with stages: unparam: 1.593527477s 
INFO [runner] worker.36 took 2.704570718s with stages: govet: 2.704558434s 
INFO [runner] worker.17 took 2.735204463s with stages: gosec: 2.735175896s 
INFO [runner] worker.35 took 9.595401785s with stages: goimports: 9.595381822s 
Killed
@jirfag jirfag added the topic: memory Huge memory consumption label Sep 24, 2019
@jirfag jirfag added this to the v1.20.0 milestone Sep 24, 2019
@jirfag
Copy link
Contributor

jirfag commented Sep 25, 2019

ok, thank you, let's continue in #337, there are too many similar issues about memory

@jirfag jirfag closed this as completed Sep 25, 2019
@tpounds tpounds added the duplicate This issue or pull request already exists label Sep 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists topic: memory Huge memory consumption
Projects
None yet
Development

No branches or pull requests

3 participants