SonarQube.Old.Bootstrapper has stopped working

257 Views Asked by At

I got this crash while executing command: SonarQube.Scanner.MSBuild.exe end:

SonarQube.Old.Bootstrapper has stopped working

More logs:

enter code here SonarQube Scanner for MSBuild 2.3.1
Default properties file was found at C:\SonarQube\SonarQube.Analysis.xml
Loading analysis properties from C:\SonarQube\SonarQube.Analysis.xml
Post-processing started.

Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
   at SonarScanner.Shim.PropertiesWriter.WriteSettingsForProject(ProjectInfo project, IEnumerable`1 files, String fxCopReportFilePath, String codeCoverageFilePath)
   at SonarScanner.Shim.PropertiesFileGenerator.ProcessProjectInfoFiles(IEnumerable`1 projects, PropertiesWriter writer, ILogger logger, String projectBaseDir, String globalSourceEncoding)
   at SonarScanner.Shim.PropertiesFileGenerator.GenerateFile(AnalysisConfig config, ILogger logger, IRoslynV1SarifFixer fixer)
   at SonarScanner.Shim.SonarScannerWrapper.Execute(AnalysisConfig config, IEnumerable`1 userCmdLineArguments, ILogger logger)
   at 


  SonarQube.TeamBuild.PostProcessor.MSBuildPostProcessor.InvokeSonarScanner(IAnalysisPropertyProvider cmdLineArgs, AnalysisConfig config)
   at 
     SonarQube.TeamBuild.PostProcessor.MSBuildPostProcessor.Execute(String[]args, AnalysisConfig config, ITeamBuildSettings settings)
     at SonarQube.Bootstrapper.BootstrapperClass.PostProcess()
     at SonarQube.Bootstrapper.BootstrapperClass.Execute()
     at SonarQube.Bootstrapper.Program.Execute(String[] args, ILogger logger)
     at SonarQube.Bootstrapper.Program.Main(String[] args)
1

There are 1 best solutions below

0
On

I had the exact same issue. I found a link (Unfortunately I cannot find it again), saying that its because sonar cannot derive the source file encoding.

I added the Sonar.SourceEncoding=UTF8 property, and everything went by, just fine.