File parse error don't make the gate fail

  • which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension)

SonarQube :, SonarPhp :, SonarQube Scanner

  • what are you trying to achieve

When my project is analyzed (in preview mode), in the log of sonarscanner i get a file parse error because one of the developper forgot a closing brace. The analyze keep on and my gateway passed. I would like to get notify that I have one file that can’t be analyzed and that it generate a issue or at least that the gate fails.

Thanks in advance for any help.

Best regards.


Hello Al,

You could maybe enable rule S2260 - PHP parser failure, which is not part of default Sonar Way profile for PHP, and configure its severity in order to make your quality gate fail.



Hello Michael,

Thanks a lot for your reply. Didn’t see that rule, i’m going to try this.