You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit b98431a
Browse filesBrowse the repository at this point in the historyBrowse files
Invalidate only package-dependent files when a Composer package changes
Today any change to composer.lock or installed.json marks the whole
result cache as outdated and forces a full re-analysis, even when the
bumped package is a dev tool or a transitive dependency that no analysed
file uses.
This records, per file, the project-vendor packages whose code the file
reflected during analysis. The edges reuse the reflection dependencies
NodeDependencies already collects for file-to-file incremental
invalidation (instead of discarding the vendor entries at
NodeDependencies::getFileDependencies), so the no-under-invalidation
property is inherited: if a file's analysis reflected a package's code,
the file is recorded against that package. Packages are resolved through
the project's installed.php install paths and scoped to the analysed
project's vendor, so PHPStan's own bundled dependencies (already covered
by CACHE_VERSION and the PHP version) are excluded.
When the only meta difference is composerLocks/composerInstalled, the
result cache now diffs the per-package versions, seeds only the files
that depend on a changed package, and falls through into the existing
incremental loop, which still adds content-changed files and propagates
dependents on a signature change. Any other meta difference still
triggers a full re-analysis, and an unreadable or unexpectedly shaped
installed.php falls back to the full nuke, so the change never
under-invalidates.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
0 commit comments