Update PHPStan to 1.9.9 to fix 10.x "updated deps" Drupal CI runs

Created on 12 January 2023, almost 2 years ago
Updated 26 January 2023, almost 2 years ago

Problem/Motivation

PHPStan 1.9.9 was released.

Looking at the "updated deps" TestBot runs lately we can see it apparently fixes two false negatives:

Running PHPStan on *all* files.
 ------ -------------------------------------------------------------------- 
  Line   core/lib/Drupal/Component/Utility/Color.php                         
 ------ -------------------------------------------------------------------- 
         Ignored error pattern #^Variable \$rgb might not be defined\.$# in  
         path /var/www/html/core/lib/Drupal/Component/Utility/Color.php was  
         not matched in reported errors.                                     
 ------ -------------------------------------------------------------------- 

 ------ ----------------------------------------------------------------------- 
  Line   core/modules/system/tests/src/Functional/Form/CheckboxTest.php         
 ------ ----------------------------------------------------------------------- 
         Ignored error pattern #^Variable \$checked might not be defined\.$#    
         in path                                                                
         /var/www/html/core/modules/system/tests/src/Functional/Form/CheckboxT  
         est.php was not matched in reported errors.                            
 ------ ----------------------------------------------------------------------- 

 [ERROR] Found 2 errors                                                         


PHPStan: failed                     

Note: IN the meantime PHPStan released 1.9.11, I checked, but there are no other false negatives removed, so we can stick with version 1.9.9.

Steps to reproduce

Proposed resolution

- Update phpstan/phpstan to 1.9.9
- Create a new baseline
- Bump version of PHPStan in composer.json to 1.9.9, since the newly created baseline won't pass on 1.9.3

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

📌 Task
Status

Fixed

Version

10.0

Component
Other 

Last updated about 2 hours ago

Created by

🇳🇱Netherlands spokje

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024