Commit 2a463f1
committed
fix: declare nikic/php-parser as runtime require, drop PhpParser whitelist
src/PHPStan/Rules/* uses PhpParser\Node\* classes at runtime. These were
previously satisfied transitively (via phpstan/phpstan) and the unknown
symbols whitelisted in qaConfig/composerRequireChecker.json to silence
composer-require-checker.
The new "DO NOT WHITELIST DEV-DEPENDENCY SYMBOLS" guidance correctly
flagged the recently introduced PhpParser\Node\Stmt\Property usage in
RequireReadonlyServiceRule.php (this symbol was not in the whitelist).
Correct fix per the new policy:
- Add nikic/php-parser ^5.0 to require (it IS a runtime dependency of
the rules shipped in src/)
- Drop the now-unnecessary PhpParser\* whitelist entries
Verified locally: bin/qa -t cr -> "There were no unknown symbols found."
CI break (composer-require-checker exit 1) is now resolved.1 parent c542ad7 commit 2a463f1
3 files changed
Lines changed: 2 additions & 36 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | 27 | | |
63 | 28 | | |
64 | 29 | | |
| |||
0 commit comments