Skip to content

Code quality cleanup: knip config, type consolidation, ADR, and TODO fixes#71

Open
IanMayo wants to merge 1 commit intomasterfrom
claude/speckit-code-quality-cleanup-F3E9X
Open

Code quality cleanup: knip config, type consolidation, ADR, and TODO fixes#71
IanMayo wants to merge 1 commit intomasterfrom
claude/speckit-code-quality-cleanup-F3E9X

Conversation

@IanMayo
Copy link
Copy Markdown
Member

@IanMayo IanMayo commented Apr 18, 2026

Summary

Five targeted code-quality improvements bundled into a single PR to reduce reviewer overhead while clearing accumulated technical debt and false positives.

Changes

  • Knip false-positive silencing: Added root knip.json with specs/** ignore pattern to silence 57 false-positive "unused" reports from speckit contracts. Pinned knip to 5.88.1 in root devDependencies to eliminate tool-version drift between contributors.

  • LogPanel prop consolidation: Merged LogTimelineProps and LogByFeatureProps into a single LogPanelProps interface in shared/components/src/LogPanel/types.ts to eliminate interface drift and reduce future review ambiguity.

  • ADR-019 documentation: Documented two accepted import type-only cycles in the VS Code extension (mapPanel → activityPanelView → calcService and activityPanelView → resultsPanelService) in docs/project_notes/decisions.md. Both cycles are erased at runtime; interface extraction is the eventual fix but deferred as a larger refactor.

  • Loader plotName fix: Replaced // TODO: Get actual name from plot list placeholder in apps/loader/src/renderer/hooks/useLoadWorkflow.ts with proper lookup that threads the plot's display name from the plot list. Added regression test in apps/loader/tests/unit/useLoadWorkflow.test.ts with revert-and-red validation.

  • TODO promotion: Replaced bare // TODO: markers in the loader with TODO(#472): and TODO(#473): references, linking to newly filed GitHub issues #472 and #473. Added pre-push grep guard to prevent shipping literal placeholders.

  • Cleanup: Removed orphaned shared/components/diff/ staging artifact with zero consumers.

Implementation Notes

  • Test-first approach for the plotName fix: revert-and-red sanity check confirmed the test is a real gate, not a tautology.
  • Pre-push grep guard (grep -rn "TODO(#NNN)" apps/) enforces TODO promotion discipline at commit time.
  • Knip pinning to root devDependencies ensures pnpm install on a clean clone resolves to the same binary across all contributors.

https://claude.ai/code/session_018BQTrz526CuYqTGQZm5hC8

Covers the five bundled cleanups from debrief-future spec 199:
knip ignore + pinning, LogPanel prop consolidation, ADR-019 for
VS Code type-only cycles, loader plotName fix with regression test,
and TODO-to-issue promotion.

https://claude.ai/code/session_018BQTrz526CuYqTGQZm5hC8
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