Skip to content

Conversation

@samsonasik
Copy link
Member

Reproduced at CodeIgniter4 project

https://github.com/codeigniter4/CodeIgniter4/blob/f16bf8763e4edcf77282cece9375bb7690da1825/tests/system/Validation/StrictRules/CreditCardRulesTest.php#L69

It got error:

1 test triggered 1 PHP warning:

1) /Users/samsonasik/www/rector-src/vendor/phpunit/phpunit/src/Framework/Constraint/String/StringMatchesFormatDescription.php:48
preg_match(): Compilation failed: regular expression is too large at offset 34583

Triggered by:

* Rector\Tests\TypeDeclarationDocblocks\Rector\Class_\AddReturnDocblockDataProviderRector\AddReturnDocblockDataProviderRectorTest::test#3
  /Users/samsonasik/www/rector-src/rules-tests/TypeDeclarationDocblocks/Rector/Class_/AddReturnDocblockDataProviderRector/AddReturnDocblockDataProviderRectorTest.php:14

@samsonasik
Copy link
Member Author

Closing for now, on unit test, this is due to phpunit, on rector side, it show

 [ERROR] Could not process                                                                                              
         "/Users/samsonasik/www/CodeIgniter4/tests/system/Validation/StrictRules/CreditCardRulesTest.php" file, due to: 
         "System error: "Undefined array key 0"                                                                         
         Run Rector with "--debug" option and post the report here: https://github.com/rectorphp/rector/issues/new". On line: 662

but can't reproduce yet on fixture.

@samsonasik samsonasik closed this Sep 27, 2025
@samsonasik samsonasik deleted the skip-big-array branch September 27, 2025 17:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants