Highlighting errors should not be fatal

Currently if a plugin adds analysis support for a language, but the highlighting part throws an exception, it yields a fatal error in the scanner and the analysis stops. I don’t understand why it has to be a fatal error, in worst case I would rather see no highlighting at all in the GUI. Because otherwise, people who could still make use of the analysis results could suffer, potentially for a long time. Feel free to correct me if I’m wrong.

Example: https://github.com/sonar-perl/sonar-perl/issues/103

Using SonarQube 7.9 Enterprise.

Hey there.

It’s 100% possible to not fail the analysis on a syntax highlighting issue, but that’s up to the plugin supporting the language (here, the community-supported sonar-perl). It’s a change we recently made in our own COBOL analyzer (SONARCOBOL-1551).

You should raise that with the maintainer if it’s still a concern. I’ve moved this topic to the Plugin Development category.

1 Like