Dead simple Python dead code detection. Current version 2.1.0 (released 2024-12-08). Checks for unused functions, classes, variables, and imports. Release cadence is irregular, typically a few times a year. Compatible with Python >=3.9.
pip install deadVerified import paths — ran on the pinned version, not inferred.
Run dead via command line. There is no stable Python API; use subprocess.
Update CLI calls: replace '--exclude' with '--ignore'. Remove any direct Python imports of dead internals.
Use dead as a quick check but complement with mypy's --unused-ignore or pyright's unused expression checks for deeper analysis.
Replace '--min-version' with '--target-version'.