Skip to content

Latest commit

 

History

History
100 lines (83 loc) · 5.4 KB

File metadata and controls

100 lines (83 loc) · 5.4 KB

Dead Code Finder - Project Plan

Purpose & Vision

The Dead Code Finder extension identifies unused code in software projects, helping developers maintain clean codebases by detecting dead methods and functions. The primary goals are:

  • Reduce technical debt by identifying unused code
  • Improve maintainability and readability of codebases
  • Prevent unnecessary bloat in projects
  • Integrate seamlessly with VSCode's development workflow

Progress Summary

Completed Features

  • ✅ Core architecture with analyzer interfaces
  • ✅ Python analyzer with Vulture integration
  • ✅ TreeView UI for result visualization
  • ✅ Command handlers for analyzing workspace and files
  • ✅ Navigation to dead code locations
  • ✅ Custom SVG icons for tree items
  • ✅ Whitelist generation for intentional dead code
  • ✅ Diagnostics provider for inline warnings
  • ✅ Sample Python project with intentional dead code
  • ✅ Unit tests for core components
  • ✅ UI improvements for the Dead Code panel (icon buttons)
  • ✅ Fixed Vulture installation process

Current Context

The extension can now detect dead code in Python projects using Vulture, display results in both a tree view and as inline diagnostics, and generate whitelists for intentional dead code. The core architecture is extensible for adding support for additional languages in the future.

Recent improvements have fixed UI issues with the panel buttons, which now use icons instead of text to save space. The Vulture installation process has also been enhanced with better error handling, fallback methods, and clearer user guidance.

Next Steps

Short-term Tasks

  1. ✅ Fix UI issues with the Dead Code panel buttons
  2. ✅ Fix Vulture installation issue
  3. Create a README.md for the extension
  4. Add more comprehensive unit tests
  5. Implement error handling for edge cases
  6. Add icons for the extension in the marketplace
  7. Set up a CI pipeline for automated testing

Medium-term Tasks

  1. Support for additional languages (JavaScript/TypeScript)
  2. Add statistics view for dead code metrics
  3. Improve configuration options for analysis
  4. Create a changelog for version tracking

Long-term Vision

  1. Machine learning to reduce false positives
  2. Integration with other code quality tools
  3. Automatic refactoring suggestions for dead code removal
  4. Support for advanced language-specific features

Implementation Tasks

Task Status Priority Notes
Set up development environment ✅ Done High Webpack, TypeScript, ESLint configured
Create extension scaffolding ✅ Done High Basic structure implemented
Implement analyzer interface ✅ Done High Common interface for all analyzers
Python dead code detection ✅ Done High Using Vulture for detection
TreeView implementation ✅ Done High Shows results grouped by file
Diagnostics provider ✅ Done Medium Shows inline warnings in editor
Whitelist system ✅ Done Medium Generate whitelist for Vulture
Resource files for icons ✅ Done Low Custom icons for tree items
Sample projects ✅ Done Medium Python examples with intentional dead code
Unit tests 🔶 In Progress Medium Basic tests implemented, need more coverage
Replace panel buttons with icons ✅ Done High Converted text buttons to icon buttons with proper placement
Fix Vulture installation process ✅ Done High Improved installation with better error handling and user guidance
Extension README ⬜ To Do High Documentation for installation and usage
Extension icons ⬜ To Do Low Icons for marketplace listing
CI/CD setup ⬜ To Do Medium Automated testing and publishing

Unit Tests

  • ✅ Analyzer interface tests
  • ✅ Vulture output parsing tests
  • ⬜ Command handler tests
  • ⬜ TreeView provider tests
  • ⬜ Whitelist generation tests
  • ⬜ Diagnostics provider tests
  • ⬜ End-to-end integration tests

Code Quality Standards

  • No deprecated code
  • Comprehensive error handling
  • Consistent code style
  • TypeScript types for all components
  • Detailed documentation

Next Milestone: Publishing Preparation

With the critical issues now resolved, focus on making the extension ready for publication to the VSCode Marketplace:

  1. Complete the README with installation and usage instructions
  2. Create extension icons
  3. Expand test coverage
  4. Conduct user testing with sample projects
  5. Optimize performance for larger codebases

Last updated: Fri Apr 4 18:12:05 CEST 2025