Skip to content

Conversation

blyxxyz
Copy link
Contributor

@blyxxyz blyxxyz commented Jul 29, 2025

Stub files from vendor directories aren't validated. But the stub files that ship with PHPstan itself weren't excluded, and they were hitting the checkMissingOverrideMethodAttribute check.

This didn't happen when PHPstan was installed through composer, since then the stub files happened to be in a vendor directory. But it did happen when PHPstan ran as a phar.

Resolves phpstan/phpstan#11907.

@blyxxyz blyxxyz force-pushed the stub-overrides branch 5 times, most recently from f2839be to dbb93bd Compare July 29, 2025 14:07
Stub files from vendor directories aren't validated. But the stub
files that ship with PHPstan itself weren't excluded, and they were
hitting the `checkMissingOverrideMethodAttribute` check.

This didn't happen when PHPstan was installed through composer, since
then the stub files happened to be in a vendor directory. But it did
happen when PHPstan ran as a phar.

Resolves phpstan/phpstan#11907.
@ondrejmirtes ondrejmirtes merged commit b36bcb2 into phpstan:2.1.x Oct 10, 2025
535 of 550 checks passed
@ondrejmirtes
Copy link
Member

Thank you!

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.

Running a downloaded phpstan phar with checkMissingOverrideMethodAttribute set to true prints errors in the phpstan stubs.

2 participants