Summary
unused can run for a long time with no progress, partial output, or bounded completion signal, even when a small --limit is provided.
Observed
During dogfooding on the current repository, I ran:
dotnet ./src/CodeIndex/bin/Debug/net8.0/cdidx.dll unused --path src/ --exclude-tests --json --limit 50
The command produced no output after more than 90 seconds. I eventually identified the running process and killed it:
- PID:
9124
- command:
dotnet ./src/CodeIndex/bin/Debug/net8.0/cdidx.dll unused --path src/ --exclude-tests --json --limit 50
- exit after kill:
143
Expected
For expensive analysis commands, one or more of these should be true:
--limit should materially bound the work;
- JSON mode should offer progress or a clear slow-query/profile path;
- the command should emit a diagnostic explaining what phase is expensive;
- the implementation should avoid unbounded joins/scans where possible.
Impact
Agents and users cannot distinguish a legitimate long-running analysis from a hang. This interrupts code-search-driven audits and makes unused hard to trust in automation.
Summary
unusedcan run for a long time with no progress, partial output, or bounded completion signal, even when a small--limitis provided.Observed
During dogfooding on the current repository, I ran:
dotnet ./src/CodeIndex/bin/Debug/net8.0/cdidx.dll unused --path src/ --exclude-tests --json --limit 50The command produced no output after more than 90 seconds. I eventually identified the running process and killed it:
9124dotnet ./src/CodeIndex/bin/Debug/net8.0/cdidx.dll unused --path src/ --exclude-tests --json --limit 50143Expected
For expensive analysis commands, one or more of these should be true:
--limitshould materially bound the work;Impact
Agents and users cannot distinguish a legitimate long-running analysis from a hang. This interrupts code-search-driven audits and makes
unusedhard to trust in automation.