The Wire · Showcase
GOPLS CLEARS PROTOCOL CLUTTER WHILE TOOLS CHAIN TACKLES MODULE MODERNIZATION
By RepoJournal · Filed · About Go
gopls shipped a cleanup that removes hand-written protocol overrides, clearing technical debt just as the modernize analyzer gains new teeth to strip obsolete import comments from module-based Go code.
The tools team took out redundant manual renames in gopls' protocol layer [1], eliminating code that was already handled by generation. Meanwhile, the modernize analyzer got a new importcomment pass [2] that removes canonical import path comments, which are dead weight in any module-based project. The go command never enforced them post-modules anyway, so this cleanup is overdue. gopls is also gaining a memoryLimit setting [3] that lets you trade CPU cycles for lower steady-state memory usage via runtime/debug.SetMemoryLimit, though the feature is still experimental and needs careful tuning to avoid GC thrashing. On the test reliability front, two flaky gopls tests got fixed [4] by building the module index deterministically instead of relying on background goroutines to finish in time. pkg.go.dev is already testing Go 1.27rc1 in Cloud Build [6], and http/3 support landed ResponseController methods for deadline and flush control [5], closing a gap between HTTP/3 and standard net/http semantics.
Action items
- → Review your gopls memory usage if you run on resource-constrained machines, test the new memoryLimit setting golang/tools [plan]
- → Run go/analysis/passes/modernize on your codebase to auto-remove stale import comments golang/tools [plan]
- → Monitor gopls test suite stability on latest commit golang/tools [monitor]
References
- [1] gopls/internal/protocol/generate: remove manual rename overwritten golang/tools
- [2] go/analysis/passes/modernize: add importcomment analyzer golang/tools
- [3] gopls/internal/server: add memoryLimit setting golang/tools
- [4] gopls/internal/test/misc: Fix two flaky tests golang/tools
- [5] internal/http3: add net/http.ResponseController support golang/net
- [6] deploy: update Cloud Build Go version to 1.27rc1 golang/pkgsite
FAQ
- What changed in Go on July 7, 2026?
- gopls shipped a cleanup that removes hand-written protocol overrides, clearing technical debt just as the modernize analyzer gains new teeth to strip obsolete import comments from module-based Go code.
- What should Go teams do about it?
- Review your gopls memory usage if you run on resource-constrained machines, test the new memoryLimit setting • Run go/analysis/passes/modernize on your codebase to auto-remove stale import comments • Monitor gopls test suite stability on latest commit
- Which Go repositories shipped on July 7, 2026?
- golang/tools, golang/net, golang/pkgsite