craftcms / rector

Rector rules for updating plugins and modules to Craft CMS 4.
19 stars 6 forks source link

Call to undefined method PHPStan\PhpDocParser\Ast\PhpDoc\PhpDocNode::getRequireExtendsTagValues() #18

Closed jonw-cogapp closed 7 months ago

jonw-cogapp commented 8 months ago

Description

As a dependency of Rector, PHPStan 1.10.55 created a recent issue with rector 0.18.x, which was resolved in rector 0.19.0. However craftcms/rector requires rector ^0.18.4, so it seems there isn't an upgrade pathway to mitigate this error until craftcms/rector supports rector 0.19.x.

 [ERROR] Could not process "config/app.php" file, due to:                                                               
         "Call to undefined method PHPStan\PhpDocParser\Ast\PhpDoc\PhpDocNode::getRequireExtendsTagValues()". On line:  
         330

Steps to reproduce

  1. composer require --dev rector/rector:^0.18
  2. Follow the instructions in the readme for including craftcms/rector
  3. Add a rector.php file using the given example
  4. vendor/bin/rector --dry-run

Additional info

khalwat commented 7 months ago

Ran into this today...

khalwat commented 7 months ago

Resolved via PR (#19)