When trying to upgrade the Magento version to 2.4.5-p14. Upgraded successfully. But when i compile, i got an error like
strpos(): Argument #1 ($haystack) must be of type string, bool given#0 setup/src/Magento/Setup/Module/Di/Code/Reader/ClassesScanner.php(71)
I tried the following code to get a list of files that have a parsing error
find app/code vendor -type f -name "*.php" -exec php -l {} ; | grep -B1 "Errors parsing"
I'm using PHP version 8.1. & "astock/stock-api-libphp" - "version": "1.1.6"
PHP 8 removed curly brace syntax for arrays/strings. But the following file still uses {} for an array
PHP Fatal error: Array and string offset access syntax with curly braces is no longer supported in vendor/astock/stock-api-libphp/libs/phpcs-psr2-stock/PSR2Stock/Sniffs/Methods/ValidFunctionNameSniff.php on line 133