Skip to content

feat: diagnose slow reference analysis - #22

Open
NickSdot wants to merge 2 commits into
mainfrom
feat/scan-performance-diagnostics
Open

NickSdot wants to merge 2 commits into
mainfrom
feat/scan-performance-diagnostics

Conversation

@NickSdot

@NickSdot NickSdot commented Sep 26, 2026 •

Copy link
Copy Markdown
Member

Generated PHP caches can become reference candidates and make a move appear stuck. This adds a progress message after five seconds of reference analysis, with periodic updates while analysis continues.

The report records the analysis duration, the number of selected reference candidates, and the largest candidate when relevant. Text output gets a Performance section, and JSON output gets structured diagnostics. When the largest candidate resembles a PHPStan cache, the hint uses its observed path to suggest an optional .refactorlah.json exclusion. The command does not change scan scope automatically.

Verified with bin/format.sh and bin/test.sh. Tests cover candidate accounting, cache path hints, progress output, and text and JSON reporting.

This branch has not been deployed

No deployments
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.

1 participant