Skip to content

Conversation

@Cali0707
Copy link
Collaborator

On our current default version of golangci-lint there was a bug that led to panics sometimes when running the analysis. On my machine, I saw:

panic: close of closed channel

goroutine 190 [running]:
github.com/golangci/golangci-lint/v2/pkg/goanalysis.(*loadingPackage).analyze(0x140028e2720, 0x140027778f0, 0x2, 0x14002777880)
	github.com/golangci/golangci-lint/v2/pkg/goanalysis/runner_loadingpackage.go:110 +0x278
github.com/golangci/golangci-lint/v2/pkg/goanalysis.(*loadingPackage).analyzeRecursive.func1()
	github.com/golangci/golangci-lint/v2/pkg/goanalysis/runner_loadingpackage.go:61 +0x194
sync.(*Once).doSlow(0x1400045f910?, 0x1040f1c70?)
	sync/once.go:78 +0xf0
sync.(*Once).Do(...)
	sync/once.go:69
github.com/golangci/golangci-lint/v2/pkg/goanalysis.(*loadingPackage).analyzeRecursive(0x1400045f910?, 0x14002245ba0?, 0x1040f1c70?, 0x14000633a70?)
	github.com/golangci/golangci-lint/v2/pkg/goanalysis/runner_loadingpackage.go:45 +0x50
github.com/golangci/golangci-lint/v2/pkg/goanalysis.(*runner).analyze.func2(0x4?)
	github.com/golangci/golangci-lint/v2/pkg/goanalysis/runner.go:273 +0x34
created by github.com/golangci/golangci-lint/v2/pkg/goanalysis.(*runner).analyze in goroutine 1
	github.com/golangci/golangci-lint/v2/pkg/goanalysis/runner.go:272 +0x4c4
make: *** [lint] Error 2

This PR updates the version to 2.5.0 to avoid this issue. I tested and this bump fixed the panic for me

@Cali0707 Cali0707 requested review from manusa and matzew October 20, 2025 17:25
Copy link
Member

@manusa manusa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thx!

@manusa manusa added this to the 0.1.0 milestone Oct 21, 2025
@manusa manusa merged commit c3bc991 into containers:main Oct 21, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants