Repository navigation
Count skip-matched files in blink run summary - #198
Merged
Merged
Conversation
ECS counts every discovered .php file in its run summary, skip-matched ones included, then applies no rules to them. blink counted only the files it processed, so its summary was lower than ECS's on projects with path skips (e.g. 2652 vs 3305 on rector-src). Finder now reports the pre-skip discovered total alongside the files to process; the summary uses it while only the non-skipped files are checked.
filepath.Join produces backslash paths on Windows, so the forward-slash skip glob did not match there. Use filepath.FromSlash so the pattern matches the walked paths on every OS.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
ecs check --blinkon rector-src reported// 2652 files, while the PHP engine reported// 3305 filesfor the same config.Cause
ECS counts every
.phpfile discovered in the configured paths in its run summary, including files matched by a path skip (*/Fixture/*,*/Source/*, …); it simply applies no rules to the skipped ones. blink dropped skip-matched files in the finder, so they never reached the summary and the count came out lower on any project with path skips.To confirm this is purely a counting-semantics difference: the set of files blink actually checks already matches ECS exactly (the 2652 non-skipped files), and the parity harness, which diffs fixed trees, was unaffected.
Fix
finder.Findnow returns the pre-skip discovered total alongside the files to process. The run summary reports the discovered total (matching ECS); only the non-skipped files are checked, as before.After the fix, blink on rector-src reports
// 3305 files, matching the PHP engine.