PHPStan is a static analysis tool for PHP.Documentation Index
Fetch the complete documentation index at: https://docs.coderabbit.ai/llms.txt
Use this file to discover all available pages before exploring further.
Files
PHPStan will run on files with the following extensions:.php
Configuration
PHPStan supports the following config files:phpstan.neonphpstan.neon.distphpstan.dist.neon
What CodeRabbit runs
PHPStan runs in a sandbox with the project config if present. If a project config is present, we parse and validate the config before execution.Security policy and restrictions
- We reject
phpstan.neon/phpstan.neon.distthat declarebootstrapFileorbootstrapFilesto prevent executing arbitrary project bootstrap code. - Blocked configuration keys include:
bootstrapFilesbootstrapFile
When we skip PHPStan
CodeRabbit will skip running PHPStan when:- The config file does not contain a
paths:parameter. - The config contains
bootstrapFileorbootstrapFiles. - PHPStan is already running in GitHub workflows.
- Config parsing fails or appears unsafe.