I faced a problem when trying to configure the PHPStan report as a JSON file.
Sonar Cloud is retrieve the file but it’s can’t analyze it.
I got this issue as in image
Failed to resolve 1305 file path(s) in PHPStan phpstan_report.json report. No issues imported related to file(s): C:\laragon\www\XYZ\Override\haruncpi\laravel-id-generator\src\IdGenerator.php;C:\laragon\www\XYZ\Override\haruncpi\laravel-id-generator\src\IdGeneratorServiceProvider.php;C:\laragon\www\XYZ\Override\haruncpi\laravel-id-generator\tests\Unit\IdGenerateTest.php;C:\laragon\www\XYZ\app\Classes\Chan
Indeed, making sure that the paths are the same as the sonar scanner will see them is the first step. This is what you did fix already.
The second problem is something we did miss when implementing the import mechanism. I did create the ticket SONARPHP-1262 to keep track of this.
Until we handle the ticket, the only solution I see is to do a search-replace over the report and remove all strings matching \s\(in context of [^)]*\).