New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Baseline output is not stable #5085
Comments
This bug report is missing a link to reproduction on phpstan.org. It will most likely be closed after manual review. |
/cc @dktapps |
... To be honest, I was already inclined to point to a change in PHP's own behaviour to blame for this in the first place, considering that the errors were already sorted, and especially now considering the fact that the errors are now sorted immediately before output, first by file, then by message pattern. So if this still didn't fix it, then I'm out of answers. |
On closer inspection, I noticed this: https://github.com/phpstan/phpstan-src/blob/master/src/Command/ErrorFormatter/BaselineNeonErrorFormatter.php#L64 This makes me think that the sorting order change is something to do with the directory separators in the original path (since it would likely be absolute), which might explain the ordering difference. I guess it would make sense to alter the algorithm to sort based on the normalized relative path, instead of the original path. |
Fixed by phpstan/phpstan-src#536 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Bug report
Code snippet that reproduces the problem
run on 2 different machines, one linux (CI, multicpu) and one Windows (with 1 CPU)
Expected output
baseline output must always be stable
The text was updated successfully, but these errors were encountered: