Hi,
I am trying to setup Sonarqube with Azure DevOps pipeline. But getting the below error. Any idea, what causing this issue.
Prepare Code Analysis Logs:
2022-07-26T09:12:50.7770282Z ##[section]Starting: Run Code Analysis
2022-07-26T09:12:50.8210040Z ==============================================================================
2022-07-26T09:12:50.8210587Z Task : Run Code Analysis
2022-07-26T09:12:50.8210993Z Description : Run scanner and upload the results to the SonarQube server.
2022-07-26T09:12:50.8211347Z Version : 5.6.1
2022-07-26T09:12:50.8211608Z Author : sonarsource
2022-07-26T09:12:50.8212365Z Help : Version: 5.6.1. This task is not needed for Maven and Gradle projects since the scanner should be run as part of the build.
[More Information](http://redirect.sonarsource.com/doc/install-configure-scanner-tfs-ts.html)
2022-07-26T09:12:50.8213251Z ==============================================================================
Run Code Analysis Logs:
2022-07-26T09:12:51.2674997Z [command]C:\agent\_work\_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\5.6.1\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe end
2022-07-26T09:12:51.4267384Z SonarScanner for MSBuild 5.6
2022-07-26T09:12:51.4269132Z Using the .NET Framework version of the Scanner for MSBuild
2022-07-26T09:12:51.4948082Z Post-processing started.
2022-07-26T09:12:51.6448727Z ##[error]09:12:51.629 The SonarScanner for MSBuild integration failed: SonarQube was unable to collect the required information about your projects.
Possible causes:
1. The project has not been built - the project must be built in between the begin and end steps
2. An unsupported version of MSBuild has been used to build the project. Currently MSBuild 14.0.25420.1 and higher are supported.
3. The begin, build and end steps have not all been launched from the same folder
4. None of the analyzed projects have a valid ProjectGuid and you have not used a solution (.sln)
2022-07-26T09:12:51.6464453Z 09:12:51.629 The SonarScanner for MSBuild integration failed: SonarQube was unable to collect the required information about your projects.
2022-07-26T09:12:51.6467596Z Possible causes:
2022-07-26T09:12:51.6468862Z 1. The project has not been built - the project must be built in between the begin and end steps
2022-07-26T09:12:51.6472203Z 2. An unsupported version of MSBuild has been used to build the project. Currently MSBuild 14.0.25420.1 and higher are supported.
2022-07-26T09:12:51.6473519Z 3. The begin, build and end steps have not all been launched from the same folder
2022-07-26T09:12:51.6474707Z 4. None of the analyzed projects have a valid ProjectGuid and you have not used a solution (.sln)
2022-07-26T09:12:51.6475763Z 09:12:51.629 Generation of the sonar-properties file failed. Unable to complete the analysis.
2022-07-26T09:12:51.6502730Z ##[error]09:12:51.644 Post-processing failed. Exit code: 1
2022-07-26T09:12:51.6506769Z 09:12:51.644 Post-processing failed. Exit code: 1
2022-07-26T09:12:51.6726346Z ##[error]The process 'C:\agent\_work\_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\5.6.1\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe' failed with exit code 1
2022-07-26T09:12:51.6845851Z ##[section]Finishing: Run Code Analysis