{"categories":[{"label":"Quality Assurance","url":"https://skillfed.io/packages/category/software-development-quality-assurance/3"}],"enrichment":{"capability":"Scans Python codebases to find and optionally remove unused variables, functions, classes, methods, attributes, imports, and other dead code expressions.","skillfed_tags":["static-analysis","code-cleanup","linting"],"use_cases":["Clean up legacy codebases by identifying and removing unused functions, classes, and variables across the entire project","Automate code hygiene in CI/CD pipelines by detecting dead code and optionally fixing it with --fix","Reduce false positives from other linters by filtering out test base classes, mixins, and framework-specific patterns","Find empty Python files and unreachable code blocks after refactoring","Maintain code quality in large teams by catching accumulated dead code before it accumulates further"],"what_it_does":"Deadcode is a static analysis tool that identifies unused code at the module level across a Python codebase. Unlike linters such as ruff or flake8 which only detect unused local variables, deadcode finds global-scope dead code: unused variables, functions, classes, methods, attributes, imports, properties, and empty files. It can also detect unreachable code blocks and commented-out code. The tool runs as a command-line scanner and optionally removes detected dead code automatically.\n\nIt integrates with pyproject.toml for configuration and supports fine-grained filtering through command-line options and inline noqa comments. You can exclude directories, ignore specific names or patterns, skip code in certain files, and ignore definitions that inherit from particular base classes or use specific decorators. The tool is designed to complement other static checkers rather than replace them.","worth_installing":"Yes, if you need global-scope dead code detection. The tool fills a gap that ruff and flake8 don't cover, has low install friction, active maintenance, and no known vulnerabilities. The AGPL v3 license is the main consideration: acceptable for open-source and internal tools, but requires careful evaluation in proprietary contexts. Start with --dry mode to evaluate false positives in your codebase."},"id":"deadcode","links":{"html":"https://skillfed.io/packages/deadcode","md":"https://skillfed.io/packages/deadcode.md","pypi":"https://pypi.org/project/deadcode/"},"maintenance":{"status":"active"},"meta":{"latest_release":"2024-08-09","license_spdx":null,"license_treatment":"agpl","name":"deadcode","python_support":"supports_current","summary":"Find and remove dead code."},"popularity":{"monthly_downloads":218491,"position":9340,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"2.4.1"}
