Skip to content

2.3.0

Choose a tag to compare

@mglaman mglaman released this 05 Nov 18:29
· 15 commits to main since this release
517b460

Upgrading

phpstan-drupal 2.3.0 requires phpstan/phpstan: ^2.3. If you're on an older PHPStan, Composer keeps you on phpstan-drupal 2.2.x until you upgrade PHPStan.

Fixes stale results on PHPStan 2.3

On PHPStan 2.3, phpstan-drupal 2.2.x and earlier never invalidate the result cache when the Drupal site changes. After a services.yml change, a schema change, or adding or removing a module, PHPStan could keep reporting old results until the cache was cleared. If you're on PHPStan 2.3, upgrade to this release.

Smarter result cache

Changes to your Drupal site now re-analyze only the files they affect:

Change Files re-analyzed
A service definition Files using that service
A service's arguments or tags, or a new service nothing uses None
A schema file Files reading config schema
An .info.yml edit None
A loadInclude() file created or changed Files loading it
A module or theme added, removed, or moved All

What's Changed

  • Track result cache dependencies instead of a site-wide hash by @mglaman in #1071

Full Changelog: 2.2.3...2.3.0