Skip to content

fix(daemon): make wire publication context cancellation explicit - #293

Merged
zhoushoujianwork merged 1 commit into
mainfrom
fix/wire-publication-cancel-vet
Oct 30, 2026
Merged

zhoushoujianwork merged 1 commit into
mainfrom
fix/wire-publication-cancel-vet

Conversation

@zhoushoujianwork

Copy link
Copy Markdown
Owner

Go 1.26 的 lostcancel 分析无法证明可变 cancel 函数经外层闭包在所有路径释放,导致全量 go vet ./... 失败。将取消的 defer 紧跟在首次创建 wire-publication timeout context 后登记,保留只创建一次、有界只读回查、失败不重写的行为。

原实现已有延迟取消,未确认真实泄漏;本改动明确取消函数的生命周期并消除静态检查失败。

验证:GOMAXPROCS=2 go vet -p=1 ./... 通过;GOMAXPROCS=2 go test -p=1 ./internal/daemon -run 'Geometry|WirePublication' -count=1 通过。

@zhoushoujianwork
zhoushoujianwork merged commit fa23e4d into main Oct 30, 2026
5 checks passed
@zhoushoujianwork
zhoushoujianwork deleted the fix/wire-publication-cancel-vet branch October 31, 2026 15:43
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.

1 participant