phpstan-drupal icon indicating copy to clipboard operation
phpstan-drupal copied to clipboard

Extension for PHPStan to allow analysis of Drupal code.

Results 161 phpstan-drupal issues
Sort by recently updated
recently updated
newest added

# Feature request This will trigger the 1.2.0 release. RenderCallbackRule inspects render array callables. It should be split apart for: * `AccessCallbackRule` for `#access_callback` * `LazyBuilderCallbackRule` for `#lazy_builder` * `RenderCallbackRule`...

enhancement

I'm facing this issue on the latest stable release while checking entityQuery code: ``` #0 phar:///app/vendor/phpstan/phpstan/phpstan.phar/src/Analyser/MutatingScope.php(3468): mglaman\PHPStanDrupal\Type\EntityQuery\EntityQueryDynamicReturnTypeExtension->getTypeFromMethodCall(Object(PHPStan\Reflection\ResolvedMethodReflect ion), Object(PhpParser\Node\Expr\MethodCall), Object(PHPStan\Analyser\MutatingScope)) #1 phar:///app/vendor/phpstan/phpstan/phpstan.phar/src/Analyser/MutatingScope.php(1386): PHPStan\Analyser\MutatingScope->methodCallReturnType(Object(mglaman\PHPStanDrupal\Type\EntityQuery\ContentEntityQueryType), 'execute', Object(PhpPa rser\Node\Expr\MethodCall)) #2 phar:///app/vendor/phpstan/phpstan/phpstan.phar/src/Analyser/MutatingScope.php(1392): PHPStan\Analyser\MutatingScope->PHPStan\Analyser\{closure}() #3...

bug
needs details
postponed

Lets add an extension to dynamically detect the return type for `\Drupal\Core\Entity\EntityRepositoryInterface::loadEntityByUuid` We already have `entityMapping` in phpstan.neon, I think the 'class' property from these can be safely reused for...

enhancement

This can cause serialization issues in PHPUnit or other areas.

enhancement
Rule

We should document how to leverage the feature added in https://github.com/mglaman/phpstan-drupal/pull/478

help wanted
good first issue

# Bug report Phpstan is failing due to code updated in the webflo : https://github.com/webflo/drupal-finder/pull/65/files Phpstan is using the this module error : Fatal error: Uncaught TypeError: is_link(): Argument #1...

bug

Adding the fix for the webflow fixes #756

Managing this project would be much easier if PHP 7.4 and PHP 8.0 were dropped. This would also stop Drupal 9 testing; or a Drupal 9 job could be created...

# Feature request When troubleshooting parts of a page that don't update correctly jr developers will often end up setting max-age on blocks or render arrays, see the problem is...

enhancement