Remove superseded and dead utility functions#195
Conversation
Behavior-preserving cleanup of functions unreachable even from tests: - tools.CoreWriteTools / CoreShellTools — superseded by the …Scoped variants. - workspaceindex.MaxFileDepth — unused helper. - tui.indentText — unused string util. - tuiTheme.onPanel2 + the now-orphaned colorPanel2 const — unused style helper. deadcode -test=false: 114 -> 109; truly-dead: 23 -> 18. Scoped to genuine cruft only — the remaining dead funcs are dormant/intended-but-unwired features (owner wire-vs-delete), not blind deletes.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
💤 Files with no reviewable changes (4)
WalkthroughRemoves four dead-code identifiers — ChangesDead code removal across tools, TUI, and workspace index
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~5 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Zero automated PR reviewVerdict: No blockers found Blockers
Validation
ScopeHead: This deterministic review checks validation status and basic diff hygiene. A human reviewer still owns product judgment and design quality. |
Summary
Behavior-preserving removal of dead utility code — functions unreachable from
cmd/*and from the test suite (deadcode -test ./...), so deleting them changes no behavior.Removed:
tools.CoreWriteTools/CoreShellTools— superseded by the…Scopedvariants (the live registration path).workspaceindex.MaxFileDepth— unused helper.tui.indentText— unused string utility.tuiTheme.onPanel2+ the now-orphanedcolorPanel2const — unused style helper.Scope (deliberately narrow)
This is the safe-cleanup slice only — genuine cruft with no feature intent. The other ~18 truly-dead funcs are dormant/intended-but-unwired features (e.g.
tui/composer.goline-editing,tui/mcp_view.gohelpers,sessions.ReplayEvents,agentevalscoring). Those are wire-vs-delete decisions for their owners, not blind deletes, so they're intentionally left out.Verification
go build ./...,go vet ./...,gofmt -lclean; fullgo test ./...green.deadcode -test=false ./...: 114 → 109; truly-dead: 23 → 18.sandbox/seccomp_other.go: ApplyUnixSocketBlockintentionally kept (non-Linux no-op stub).Summary by CodeRabbit