-
| Hi, Do you see any problem with command below and the reason why it runs soooo slow? Thanks docker run \
	--rm \
	--tty \
	--workdir /source \
	--volume ${PWD}:/source:ro \
	--volume ${PWD}/tmp/golangci:/root/.cache:rw \
	golangci/golangci-lint:v1.60.3 golangci-lint run --verbose --config golangci.yamllogsINFO golangci-lint has version 1.60.3 built with go1.23.0 from c2e095c0 on 2024-08-22T21:51:56Z 
INFO [config_reader] Used config file golangci.yaml 
INFO [lintersdb] Active 50 linters: [asciicheck bidichk bodyclose containedctx decorder dogsled dupl durationcheck errcheck errname errorlint exhaustive forbidigo forcetypeassert funlen gochecknoglobals gochecknoinits gocognit goconst gocritic gocyclo godot goimports gosec gosimple govet ineffassign interfacebloat lll makezero misspell nakedret nestif nilerr nilnil nlreturn noctx nonamedreturns prealloc rowserrcheck sloglint sqlclosecheck stylecheck tenv unconvert unparam unused usestdlibvars wastedassign whitespace] 
INFO [loader] Go packages loading at mode 575 (deps|exports_file|files|imports|compiled_files|name|types_sizes) took 38.010156635s 
INFO [runner/filename_unadjuster] Pre-built 0 adjustments in 155.602521ms 
INFO [linters_context/goanalysis] analyzers took 5m28.949602817s with top 10 stages: buildir: 2m16.073312749s, exhaustive: 40.022216746s, printf: 33.911185s, ctrlflow: 33.010373316s, fact_purity: 23.831024044s, bidichk: 9.075444414s, wastedassign: 7.982315882s, dupl: 5.634203254s, gocritic: 5.360372371s, goimports: 4.725916441s 
INFO [runner] Issues before processing: 214, after processing: 0 
INFO [runner] Processors filtering stat (in/out): skip_files: 214/214, skip_dirs: 214/214, exclude: 85/85, filename_unadjuster: 214/214, exclude-rules: 85/0, invalid_issue: 214/214, path_prettifier: 214/214, identifier_marker: 85/85, cgo: 214/214, autogenerated_exclude: 214/85 
INFO [runner] processing took 440.312744ms with stages: path_prettifier: 315.281196ms, autogenerated_exclude: 116.739199ms, identifier_marker: 5.144875ms, exclude-rules: 2.400753ms, skip_dirs: 591.211µs, invalid_issue: 96.411µs, cgo: 24.371µs, filename_unadjuster: 16.628µs, nolint: 5.708µs, sort_results: 5.537µs, uniq_by_line: 1.245µs, skip_files: 1.035µs, max_same_issues: 949ns, fixer: 932ns, exclude: 766ns, source_code: 719ns, max_from_linter: 417ns, path_shortener: 238ns, diff: 212ns, max_per_file_from_linter: 124ns, path_prefixer: 112ns, severity-rules: 106ns 
INFO [runner] linters took 1m8.075126192s with stages: goanalysis_metalinter: 1m7.631139507s 
INFO File cache stats: 58 entries of total size 103.0KiB 
INFO Memory: 917 samples, avg is 215.8MB, max is 464.4MB 
INFO Execution took 1m46.282639685s$ tree tmp/
tmp/
├── golangci
│   ├── 00
│   │   ├── 000ab77b0ae7fe5ddc06f61d80dd9c8bc4fcc5a999479869292c216e7bfa2e1e-d
│   │   ├── ....
│   │   └── 00dedcbaf5dd36c49447863279d4bf0649eb1838d56074e8076fc688dff92fca-d
│   ├── 01
│   │   ├── 01140c8cf7100baa02be88890391dc695717b5cc4895d160e9fc29fd84d984b0-d
....configrun:
  concurrency: 4
  timeout: 5m
  tests: true
  modules-download-mode: readonly
  allow-parallel-runners: true
  go: "1.23.0"
output:
  sort-results: true
linters-settings:
  decorder:
    dec-order:
      - const
      - var
      - type
      - func
  errcheck:
    check-blank: true
    exclude-functions:
      - (github.com/jackc/pgx/v5.Tx).Rollback(context.Context)
      - (*github.com/me/pkg/xrest.Response).Write
  funlen:
    lines: 100
    statements: 50
  gocognit:
    min-complexity: 20
  gocyclo:
    min-complexity: 20
  misspell:
    locale: UK
  nestif:
    min-complexity: 2
  sloglint:
    context: "all"
    static-msg: true
    args-on-sep-lines: true
    forbidden-keys:
      - time
      - level
      - message
      - log.time
      - log.level
      - log.message
      - log.caller
      - svc.name
      - svc.env
      - svc.ver
linters:
  disable-all: true
  enable:
    - asciicheck
    - bidichk
    - bodyclose
    - containedctx
    - decorder
    - dogsled
    - dupl
    - durationcheck
    - errcheck
    - errname
    - errorlint
    - exhaustive
    - forbidigo
    - forcetypeassert
    - funlen
    - gochecknoglobals
    - gochecknoinits
    - gocognit
    - goconst
    - gocritic
    - gocyclo
    - godot
    - goimports
    - gosimple
    - gosec
    - govet
    - ineffassign
    - interfacebloat
    - lll
    - makezero
    - misspell
    - nakedret
    - nestif
    - nilerr
    - nilnil
    - nlreturn
    - noctx
    - nonamedreturns
    - rowserrcheck
    - prealloc
    - sloglint
    - sqlclosecheck
    - stylecheck
    - tenv
    - typecheck
    - unconvert
    - unparam
    - unused
    - usestdlibvars
    - wastedassign
    - whitespace
issues:
  max-issues-per-linter: 0
  max-same-issues: 0
  exclude-rules:
    - path: main.go
      linters:
        - forbidigo
        - funlen
        - sloglint
    - path: _test.go
      linters:
        - funlen | 
Beta Was this translation helpful? Give feedback.
      
      
          Answered by
          
            ldez
          
      
      
        Sep 9, 2024 
      
    
    Replies: 2 comments 32 replies
-
| I can see several elements: 
 | 
Beta Was this translation helpful? Give feedback.
                  
                    4 replies
                  
                
            -
| Hi @ldez I've just started upgraded to  The only change I have in my config is  Thanks INFO golangci-lint has version 1.61.0 built with go1.23.1 from a1d6c560 on 2024-09-09T17:44:42Z
INFO [config_reader] Used config file golangci.yaml
INFO [lintersdb] Active 49 linters: [asciicheck bidichk bodyclose containedctx decorder dogsled dupl durationcheck errcheck errname errorlint exhaustive forbidigo forcetypeassert funlen gochecknoinits gocognit goconst gocritic gocyclo godot goimports gosec gosimple govet ineffassign interfacebloat lll makezero misspell nakedret nestif nilerr nilnil nlreturn noctx nonamedreturns prealloc rowserrcheck sloglint sqlclosecheck stylecheck tenv unconvert unparam unused usestdlibvars wastedassign whitespace]
INFO [loader] Go packages loading at mode 575 (imports|types_sizes|compiled_files|exports_file|files|name|deps) took 22.372097144s
INFO [runner/filename_unadjuster] Pre-built 0 adjustments in 98.836487ms
INFO [linters_context/goanalysis] analyzers took 0s with no stages
INFO [runner] Issues before processing: 280, after processing: 0
INFO [runner] Processors filtering stat (in/out): skip_dirs: 280/150, autogenerated_exclude: 150/150, identifier_marker: 150/150, skip_files: 280/280, path_prettifier: 280/280, cgo: 280/280, filename_unadjuster: 280/280, invalid_issue: 280/280, exclude: 150/150, exclude-rules: 150/0
INFO [runner] processing took 174.186539ms with stages: autogenerated_exclude: 157.718964ms, identifier_marker: 5.234305ms, skip_dirs: 3.257696ms, exclude-rules: 3.11851ms, cgo: 2.64356ms, path_prettifier: 2.124401ms, invalid_issue: 40.304µs, filename_unadjuster: 34.942µs, nolint: 4.639µs, sort_results: 4.544µs, max_same_issues: 1.551µs, skip_files: 513ns, exclude: 424ns, uniq_by_line: 414ns, fixer: 375ns, diff: 307ns, source_code: 261ns, max_from_linter: 244ns, path_shortener: 230ns, max_per_file_from_linter: 122ns, severity-rules: 119ns, path_prefixer: 114ns
INFO [runner] linters took 1.269203973s with stages: goanalysis_metalinter: 1.094818933s
INFO File cache stats: 0 entries of total size 0B
INFO Memory: 1024 samples, avg is 22.2MB, max is 79.1MB
INFO Execution took 1m42.312926137s | 
Beta Was this translation helpful? Give feedback.
                  
                    28 replies
                  
                
            
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
This element
--volume ${PWD}/tmp/golangci:/root/.cache:rwimplies this:And because
--volume ${PWD}:/source:ro, the${PWD}/tmp/golangcifolder is also 2 times inside the container:So
tmpfolder is inside the project, like the other project files.You should remove this folder and using something like that:
docker run \ --rm \ --tty \ --workdir /source \ --volume ${PWD}:/source:ro \ --volume /t…