Hi All,
Hope everyone is staying safe.
I am facing below issue when i try to build pipepline after adding the task run code analysis for sonarqube integration with .net code.
SonarErrorLog.txt (3.1 KB)
Any help is appreciated.
Thanks,
Vishnu
Hi All,
Hope everyone is staying safe.
I am facing below issue when i try to build pipepline after adding the task run code analysis for sonarqube integration with .net code.
SonarErrorLog.txt (3.1 KB)
Any help is appreciated.
Thanks,
Vishnu
Hi Vishnu,
Welcome to the community!
For the record, it’s better to include the text of your logs in the post itself & just apply code formatting.
Here’s the relevant part of your error log:
2021-02-15T07:57:36.5266562Z ##[error]07:57:36.467 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 ste
2021-02-15T07:57:36.5271741Z 07:57:36.467 The SonarScanner for MSBuild integration failed: SonarQube was unable to collect the required information about your projects.
2021-02-15T07:57:36.5272693Z Possible causes:
2021-02-15T07:57:36.5274309Z ##[error]ps
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
2021-02-15T07:57:36.5276311Z ps
2021-02-15T07:57:36.5276969Z 2. An unsupported version of MSBuild has been used to build the project. Currently MSBuild 14.0.25420.1 and higher are supported.
2021-02-15T07:57:36.5277752Z 3. The begin, build and end steps have not all been launched from the same folder
2021-02-15T07:57:36.5278833Z ##[error]have a valid ProjectGuid and you have not used a solution (.sln)
2021-02-15T07:57:36.5283246Z have a valid ProjectGuid and you have not used a solution (.sln)
This looks to me like the standard, generic error. Have you checked these possible error conditions?
Ann
Hi Ann,
Thanks for the invite.
I have checked the possible causes and verified the same.
For my understanding the MSBuild version is 15 which is compatible and even i pointed the .sln of my local project as well.
Created environment variables for the sonar scanner and have set the properties in the sonar-scanner.properties file where it points the code path to get the analysis with the help of sonarqube.
Not sure which part was missing.
Hey @vishnu_G, are you getting this issue while building in a CI pipeline somewhere or locally on your machine?
I had this issue with a self-hosted agent pool in Azure DevOps where a single VM would run multiple builds in parallel. There’s an issue where the sonar scanner is installed globally to the machine and that scanner gets removed after code analysis is completed. This obviously creates a race condition when running multiple scans in parallel.
Could be related to Make Azure DevOps build tasks atomic to the agent
Hi Simon,
It seems my current situation matches with your inputs.
I am working on the single pipeline by creating self hosted agent in the single vm where sonarqube is hosted.
when i set the environment variables and sonar-scanner.properties with reference to code path like .sln,i am facing the issue of MSbuild(solution version is 15).
Not sure where its getting broke.
Regards,
Vishnu
Any Update or help on the above request.
Dealing with this almost a week.
Thanks in Advance!
Vishnu.
hi @vishnu_G
BEGIN
and END
command (please run SonarScanner.MSBuild.exe begin /k:“MyProject” /d:sonar.verbose=true
as the begin step, and please attach the output of BEGIN and END steps)Hi Andrei,
Sonarqube version - 8.6.1
I have set all parameters in the classic editor of the pipeline after adding the task,Prepare analysis configuration.
When i try to run the commands i am facing this
Please refer the overall issue with pipeline
Thanks in Advance.
Hi @vishnu_G
MSBuild.SonarQube.Runner.exe doesn’t exist anymore, please use SonarScanner.MSBuild.exe instead.
Also, Can you share the full log of your build please ? Including prepare analysis configuration and eventually the msbuild log.
Thanks in advance.
Thanks Caro For the update,i installed MSBuild for sonar scanner and i am able to run the begin command without any issues.
When i run the end command i am facing below issue.
I have made the settings as per requirement for SonarQubeAnalysisConfig.xml file.
Here goes the settings
Name=“sonar.login”>admin
Name=“sonar.password”>********
Name=“sonar.projectVersion”>1.0
Name=“sonar.host.url”>http://localhost:8000
Name=“sonar.projectKey”>8454156ee61c8f6913ba7500be0f08ff749a175f
SonarProeject
C:/Users/VishnuPra (F3107DF5)/Downloads/DotnetProjects/SocialGoal-master/source
Here goes the complete Run code analysis build pipeline issue details
2021-02-26T08:16:37.0408793Z ##[section]Starting: Run Code Analysis
2021-02-26T08:16:58.8593917Z ==============================================================================
2021-02-26T08:16:58.8594309Z Task : Run Code Analysis
2021-02-26T08:16:58.8594601Z Description : Run scanner and upload the results to the SonarQube server.
2021-02-26T08:16:58.8594842Z Version : 4.17.0
2021-02-26T08:16:58.8595043Z Author : sonarsource
2021-02-26T08:16:58.8595537Z Help : Version: 4.17.0. This task is not needed for Maven and Gradle projects since the scanner should be run as part of the build.
More Information
2021-02-26T08:16:58.8596070Z ==============================================================================
2021-02-26T08:17:00.5042502Z [command]“C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe” end
2021-02-26T08:17:00.5043642Z SonarScanner for MSBuild 5.0.4
2021-02-26T08:17:00.5044078Z Using the .NET Framework version of the Scanner for MSBuild
2021-02-26T08:17:00.5044498Z Post-processing started.
2021-02-26T08:17:00.5046200Z ##[error]08:17:00.429 The SonarScanner for MSBuild integration failed: SonarQube was unable to collect the required information about your projects.
Possible causes:
Hi,
Can you share also the Prepare analysis configuration log and your build log as well ?
Thanks.
2021-02-26T14:07:47.7506511Z ##[debug]Evaluating condition for step: ‘Prepare analysis on SonarQube’
2021-02-26T14:07:47.7508311Z ##[debug]Evaluating: succeeded()
2021-02-26T14:07:47.7508819Z ##[debug]Evaluating succeeded:
2021-02-26T14:07:47.7510314Z ##[debug]=> True
2021-02-26T14:07:47.7511040Z ##[debug]Result: True
2021-02-26T14:07:47.7511625Z ##[section]Starting: Prepare analysis on SonarQube
2021-02-26T14:07:47.7819015Z ##[debug]Extracting task SonarQubePrepare from C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_taskzips\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157_4.17.0.zip to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0.
2021-02-26T14:08:12.1366792Z ==============================================================================
2021-02-26T14:08:12.1367201Z Task : Prepare Analysis Configuration
2021-02-26T14:08:12.1367512Z Description : Prepare SonarQube analysis configuration
2021-02-26T14:08:12.1367811Z Version : 4.17.0
2021-02-26T14:08:12.1368083Z Author : sonarsource
2021-02-26T14:08:12.1368463Z Help : Version: 4.17.0. More Information
2021-02-26T14:08:12.1368912Z ==============================================================================
2021-02-26T14:08:12.1441558Z ##[debug]Using node path: C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)\externals\node\bin\node.exe
2021-02-26T14:08:12.8996555Z ##[debug]agent.TempDirectory=C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_temp
2021-02-26T14:08:13.1706225Z ##[debug]loading inputs and endpoints
2021-02-26T14:08:13.4361629Z ##[debug]loading ENDPOINT_AUTH_943b74f8-6536-4381-9e11-fc940ed81a94
2021-02-26T14:08:13.6827853Z ##[debug]loading ENDPOINT_AUTH_PARAMETER_943b74f8-6536-4381-9e11-fc940ed81a94_USERNAME
2021-02-26T14:08:13.6862596Z ##[debug]loading ENDPOINT_AUTH_PARAMETER_SYSTEMVSSCONNECTION_ACCESSTOKEN
2021-02-26T14:08:13.6871546Z ##[debug]loading ENDPOINT_AUTH_SCHEME_943b74f8-6536-4381-9e11-fc940ed81a94
2021-02-26T14:08:13.6897176Z ##[debug]loading ENDPOINT_AUTH_SCHEME_SYSTEMVSSCONNECTION
2021-02-26T14:08:13.6927842Z ##[debug]loading ENDPOINT_AUTH_SYSTEMVSSCONNECTION
2021-02-26T14:08:13.7393598Z ##[debug]loading INPUT_CLIPROJECTVERSION
2021-02-26T14:08:13.7401490Z ##[debug]loading INPUT_CLISOURCES
2021-02-26T14:08:13.7409415Z ##[debug]loading INPUT_CONFIGFILE
2021-02-26T14:08:13.7410193Z ##[debug]loading INPUT_CONFIGMODE
2021-02-26T14:08:13.7411150Z ##[debug]loading INPUT_EXTRAPROPERTIES
2021-02-26T14:08:13.7411760Z ##[debug]loading INPUT_PROJECTKEY
2021-02-26T14:08:13.7412353Z ##[debug]loading INPUT_PROJECTVERSION
2021-02-26T14:08:13.7412948Z ##[debug]loading INPUT_SCANNERMODE
2021-02-26T14:08:13.7413572Z ##[debug]loading INPUT_SONARQUBE
2021-02-26T14:08:13.7414185Z ##[debug]loaded 15
2021-02-26T14:08:13.7419777Z ##[debug]Agent.ProxyUrl=undefined
2021-02-26T14:08:13.7420396Z ##[debug]Agent.CAInfo=undefined
2021-02-26T14:08:13.7420953Z ##[debug]Agent.ClientCert=undefined
2021-02-26T14:08:13.7421683Z ##[debug]Agent.SkipCertValidation=undefined
2021-02-26T14:08:13.7422480Z ##[debug]SonarQube=943b74f8-6536-4381-9e11-fc940ed81a94
2021-02-26T14:08:13.7423148Z ##[debug]943b74f8-6536-4381-9e11-fc940ed81a94=http://localhost:8000/
2021-02-26T14:08:13.7423856Z ##[debug]943b74f8-6536-4381-9e11-fc940ed81a94 auth param apitoken = null
2021-02-26T14:08:13.7425072Z ##[debug]943b74f8-6536-4381-9e11-fc940ed81a94 auth param username = ***
2021-02-26T14:08:13.7425902Z ##[debug]943b74f8-6536-4381-9e11-fc940ed81a94 auth param password = null
2021-02-26T14:08:13.7426429Z ##[debug]organization=null
2021-02-26T14:08:13.7426893Z ##[debug]scannerMode=MSBuild
2021-02-26T14:08:13.7427623Z ##[debug]projectKey=***
2021-02-26T14:08:13.7435203Z ##[debug]projectName=null
2021-02-26T14:08:13.7435734Z ##[debug]projectVersion=1.0
2021-02-26T14:08:13.7436194Z ##[debug]organization=null
2021-02-26T14:08:13.7436712Z ##[debug][SQ] API GET: ‘/api/server/version’ with query “undefined”
2021-02-26T14:08:13.7439959Z ##[debug]Response: 200 Body: “8.6.1.40680”
2021-02-26T14:08:13.7440811Z ##[debug]System.TeamFoundationCollectionUri=https://dev.azure.com/NTTDATA-DTA-ORG/
2021-02-26T14:08:13.7441437Z ##[debug]System.PullRequest.PullRequestId=undefined
2021-02-26T14:08:13.7442163Z ##[debug]Build.Repository.Provider=TfsGit
2021-02-26T14:08:13.7442837Z ##[debug]Build.SourceBranch=refs/heads/main
2021-02-26T14:08:13.7443264Z SYSTEMVSSCONNECTION exists true
2021-02-26T14:08:13.7443722Z ##[debug]SYSTEMVSSCONNECTION exists true
2021-02-26T14:08:13.9819493Z ##[debug]Build.Repository.Name=SonarHost
2021-02-26T14:08:13.9820863Z ##[debug]System.TeamProject=Azure DevOps Demo
2021-02-26T14:08:14.1488602Z ##[debug]Default branch of this repository is ‘refs/heads/main’
2021-02-26T14:08:14.1568535Z ##[debug]SonarCloud or SonarQube version >= 7.2.0 detected, setting report-task.txt file to its newest location.
2021-02-26T14:08:14.1689631Z ##[debug]Agent.TempDirectory=C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_temp
2021-02-26T14:08:14.1692229Z ##[debug]Build.BuildNumber=20210226.1
2021-02-26T14:08:14.1693527Z ##[debug][SQ] Branch and PR parameters: {“sonar.scanner.metadataFilePath”:“C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)\_work\_temp\sonar\20210226.1\fa27b54b-f4ad-cbf3-6d4e-990dd1fb4f7d\report-task.txt”}
2021-02-26T14:08:14.1698563Z ##[debug]extraProperties=# Additional properties that will be passed to the scanner,
2021-02-26T14:08:14.1725931Z ##[debug]set SONARQUBE_SCANNER_MODE=MSBuild
2021-02-26T14:08:14.1735768Z ##[debug]Processed: ##vso[task.setvariable variable=SONARQUBE_SCANNER_MODE;issecret=false;]MSBuild
2021-02-26T14:08:14.1736787Z ##[debug]set SONARQUBE_ENDPOINT=********
2021-02-26T14:08:14.1742912Z ##[debug]Processed: ##vso[task.setvariable variable=SONARQUBE_ENDPOINT;issecret=true;]***
2021-02-26T14:08:14.1807844Z ##[debug]set SONARQUBE_SCANNER_PARAMS={“sonar.host.url”:“http://localhost:8000/","sonar.login”:,“sonar.projectKey”:,“sonar.projectVersion”:“1.0”,“sonar.scanner.metadataFilePath”:“C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)\_work\_temp\sonar\20210226.1\fa27b54b-f4ad-cbf3-6d4e-990dd1fb4f7d\report-task.txt”}
2021-02-26T14:08:14.1832362Z ##[debug]Processed: ##vso[task.setvariable variable=SONARQUBE_SCANNER_PARAMS;issecret=false;]{“sonar.host.url”:“http://localhost:8000/","sonar.login”:,“sonar.projectKey”:,“sonar.projectVersion”:“1.0”,“sonar.scanner.metadataFilePath”:“C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)\_work\_temp\sonar\20210226.1\fa27b54b-f4ad-cbf3-6d4e-990dd1fb4f7d\report-task.txt”}
2021-02-26T14:08:14.2001804Z ##[debug]Absolute path for pathSegments: C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0,classic-sonar-scanner-msbuild,SonarScanner.MSBuild.exe = C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe
2021-02-26T14:08:14.2047599Z ##[debug]Using classic scanner at C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe
2021-02-26T14:08:14.2053019Z ##[debug]set SONARQUBE_SCANNER_MSBUILD_EXE=C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe
2021-02-26T14:08:14.2350751Z ##[debug]Processed: ##vso[task.setvariable variable=SONARQUBE_SCANNER_MSBUILD_EXE;issecret=false;]C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe
2021-02-26T14:08:14.3735170Z ##[debug]which ‘C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe’
2021-02-26T14:08:14.3919923Z ##[debug]found: ‘C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe’
2021-02-26T14:08:14.3927483Z ##[debug]which ‘C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe’
2021-02-26T14:08:14.3930967Z ##[debug]found: ‘C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe’
2021-02-26T14:08:14.3954168Z ##[debug]C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe arg: begin
2021-02-26T14:08:14.3975401Z ##[debug]C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe arg: /k:***
2021-02-26T14:08:14.3993877Z ##[debug]system.debug=true
2021-02-26T14:08:14.4338352Z ##[debug]C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe arg: /d:sonar.verbose=true
2021-02-26T14:08:14.4345068Z ##[debug]exec tool: C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe
2021-02-26T14:08:14.4351619Z ##[debug]arguments:
2021-02-26T14:08:14.4366232Z ##[debug] begin
2021-02-26T14:08:14.4420458Z ##[debug] /k:***
2021-02-26T14:08:14.4772834Z ##[debug] /d:sonar.verbose=true
2021-02-26T14:08:14.4776330Z [command]“C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe” begin /k:*** /d:sonar.verbose=true
2021-02-26T14:08:14.4783379Z SonarScanner for MSBuild 5.0.4
2021-02-26T14:08:14.4943178Z Using the .NET Framework version of the Scanner for MSBuild
2021-02-26T14:08:14.5358581Z Default properties file was found at C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarQube.Analysis.xml
2021-02-26T14:08:14.5432032Z Loading analysis properties from C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarQube.Analysis.xml
2021-02-26T14:08:14.5561834Z sonar.verbose=true was specified - setting the log verbosity to ‘Debug’
2021-02-26T14:08:14.5564180Z Pre-processing started.
2021-02-26T14:08:14.5565307Z Preparing working directories…
2021-02-26T14:08:14.5584784Z Using environment variables to determine the download directory…
2021-02-26T14:08:14.6388603Z Using environment variable ‘AGENT_BUILDDIRECTORY’, value ‘C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1’
2021-02-26T14:08:14.6489830Z 14:08:14.632 14:08:14.619 Loading analysis properties from C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarQube.Analysis.xml
2021-02-26T14:08:14.6507797Z 14:08:14.632 14:08:14.632 sonar.verbose=true was specified - setting the log verbosity to ‘Debug’
2021-02-26T14:08:14.6601893Z 14:08:14.637 Updating build integration targets…
2021-02-26T14:08:14.6630104Z 14:08:14.658 Installed SonarQube.Integration.ImportBefore.targets to C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\MSBuild\4.0\Microsoft.Common.targets\ImportBefore
2021-02-26T14:08:14.6648629Z 14:08:14.66 Installed SonarQube.Integration.ImportBefore.targets to C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\MSBuild\10.0\Microsoft.Common.targets\ImportBefore
2021-02-26T14:08:14.6673101Z 14:08:14.663 Installed SonarQube.Integration.ImportBefore.targets to C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\MSBuild\11.0\Microsoft.Common.targets\ImportBefore
2021-02-26T14:08:14.6792836Z 14:08:14.666 Installed SonarQube.Integration.ImportBefore.targets to C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\MSBuild\12.0\Microsoft.Common.targets\ImportBefore
2021-02-26T14:08:14.6911420Z 14:08:14.667 Installed SonarQube.Integration.ImportBefore.targets to C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\MSBuild\14.0\Microsoft.Common.targets\ImportBefore
2021-02-26T14:08:14.6974839Z 14:08:14.672 Installed SonarQube.Integration.ImportBefore.targets to C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\MSBuild\15.0\Microsoft.Common.targets\ImportBefore
2021-02-26T14:08:14.6990008Z 14:08:14.674 Installed SonarQube.Integration.ImportBefore.targets to C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Microsoft\MSBuild\Current\Microsoft.Common.targets\ImportBefore
2021-02-26T14:08:14.6992188Z 14:08:14.685 Installed SonarQube.Integration.targets to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\bin\targets
2021-02-26T14:08:14.7375184Z 14:08:14.687 Creating config and output folders…
2021-02-26T14:08:14.7420215Z 14:08:14.688 Creating directory: C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\conf
2021-02-26T14:08:14.7428505Z 14:08:14.689 Creating directory: C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\out
2021-02-26T14:08:14.7675757Z 14:08:14.766 Downloading from http://localhost:8000/api/server/version…
2021-02-26T14:08:14.8216530Z 14:08:14.815 Checking validity of server license
2021-02-26T14:08:14.8218140Z 14:08:14.818 Downloading from http://localhost:8000/api/editions/is_valid_license…
2021-02-26T14:08:14.8765149Z 14:08:14.837 SonarQube Community Edition detected, license is valid.
2021-02-26T14:08:15.0444911Z 14:08:14.845 Fetching analysis configuration settings…
2021-02-26T14:08:15.0458895Z 14:08:14.854 Fetching properties for project ‘’ from http://localhost:8000/api/settings/values?component=…
2021-02-26T14:08:15.0473947Z 14:08:14.858 Downloading from http://localhost:8000/api/settings/values?component=…
2021-02-26T14:08:15.0480936Z 14:08:14.872 No settings for project . Getting global settings: http://localhost:8000/api/settings/values
2021-02-26T14:08:15.0659125Z 14:08:14.873 Downloading from http://localhost:8000/api/settings/values…
2021-02-26T14:08:15.0681271Z 14:08:14.916 Downloading from http://localhost:8000/api/languages/list…
2021-02-26T14:08:15.0682504Z 14:08:15.021 Fetching quality profile for project '’ from http://localhost:8000/api/qualityprofiles/search?project=…
2021-02-26T14:08:15.0687183Z 14:08:15.031 Downloading from http://localhost:8000/api/qualityprofiles/search?project=…
2021-02-26T14:08:15.0690336Z 14:08:15.045 Fetching quality profile for project '’ from http://localhost:8000/api/qualityprofiles/search?defaults=true…
2021-02-26T14:08:15.0696431Z 14:08:15.048 Downloading from http://localhost:8000/api/qualityprofiles/search?defaults=true…
2021-02-26T14:08:15.5092076Z 14:08:15.102 Fetching active rules for quality profile ‘AXekT–_JAjXn7bRjgpd’ from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params,actives&ps=500&activation=true&qprofile=AXekT--_JAjXn7bRjgpd&p=1…
2021-02-26T14:08:15.6663046Z 14:08:15.104 Downloading from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params,actives&ps=500&activation=true&qprofile=AXekT--_JAjXn7bRjgpd&p=1…
2021-02-26T14:08:15.6720164Z 14:08:15.482 Fetching rules not active in quality profile ‘AXekT–_JAjXn7bRjgpd’ for language ‘cs’ from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params&ps=500&activation=false&qprofile=AXekT--_JAjXn7bRjgpd&p=1&languages=cs…
2021-02-26T14:08:15.6762115Z 14:08:15.484 Downloading from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params&ps=500&activation=false&qprofile=AXekT--_JAjXn7bRjgpd&p=1&languages=cs…
2021-02-26T14:08:15.6850079Z 14:08:15.624 Local analyzer cache: C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp.sonarqube\resources
2021-02-26T14:08:15.7076644Z 14:08:15.648 Writing Roslyn generated ruleset to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\conf\SonarQubeRoslyn-cs.ruleset…
2021-02-26T14:08:15.7978031Z 14:08:15.68 Writing Roslyn generated ruleset to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\conf\SonarQubeRoslyn-cs-test.ruleset…
2021-02-26T14:08:15.8496867Z 14:08:15.699 Provisioning analyzer assemblies for cs…
2021-02-26T14:08:15.8611588Z 14:08:15.701 Installing required Roslyn analyzers…
2021-02-26T14:08:15.8636957Z 14:08:15.702 Processing plugin: csharp version 8.15.0.24505
2021-02-26T14:08:15.9430278Z 14:08:15.94 Cache hit: using plugin files from C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp.sonarqube\resources\0
2021-02-26T14:08:15.9680917Z 14:08:15.941 Processing plugin: vbnet version 8.15.0.24505
2021-02-26T14:08:16.1026709Z 14:08:15.943 Cache hit: using plugin files from C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp.sonarqube\resources\1
2021-02-26T14:08:16.2857666Z 14:08:15.953 Writing Roslyn analyzer additional file to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\conf\cs\SonarLint.xml…
2021-02-26T14:08:16.4731941Z 14:08:15.962 Fetching quality profile for project ‘’ from http://localhost:8000/api/qualityprofiles/search?project=…
2021-02-26T14:08:16.4869021Z 14:08:15.963 Downloading from http://localhost:8000/api/qualityprofiles/search?project=…
2021-02-26T14:08:16.4886436Z 14:08:15.969 Fetching quality profile for project '’ from http://localhost:8000/api/qualityprofiles/search?defaults=true…
2021-02-26T14:08:16.4976144Z 14:08:15.97 Downloading from http://localhost:8000/api/qualityprofiles/search?defaults=true…
2021-02-26T14:08:16.5007604Z 14:08:16.104 Fetching active rules for quality profile ‘AXekUCSPJAjXn7bRjhRL’ from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params,actives&ps=500&activation=true&qprofile=AXekUCSPJAjXn7bRjhRL&p=1…
2021-02-26T14:08:16.5163825Z 14:08:16.105 Downloading from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params,actives&ps=500&activation=true&qprofile=AXekUCSPJAjXn7bRjhRL&p=1…
2021-02-26T14:08:16.5168311Z 14:08:16.289 Fetching rules not active in quality profile ‘AXekUCSPJAjXn7bRjhRL’ for language ‘vbnet’ from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params&ps=500&activation=false&qprofile=AXekUCSPJAjXn7bRjhRL&p=1&languages=vbnet…
2021-02-26T14:08:16.5468389Z 14:08:16.294 Downloading from http://localhost:8000/api/rules/search?f=repo,name,severity,lang,internalKey,templateKey,params&ps=500&activation=false&qprofile=AXekUCSPJAjXn7bRjhRL&p=1&languages=vbnet…
2021-02-26T14:08:16.5498988Z 14:08:16.475 Local analyzer cache: C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp.sonarqube\resources
2021-02-26T14:08:16.5629592Z 14:08:16.477 Writing Roslyn generated ruleset to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\conf\SonarQubeRoslyn-vbnet.ruleset…
2021-02-26T14:08:16.5640161Z 14:08:16.485 Writing Roslyn generated ruleset to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\conf\SonarQubeRoslyn-vbnet-test.ruleset…
2021-02-26T14:08:16.5720753Z 14:08:16.494 Provisioning analyzer assemblies for vbnet…
2021-02-26T14:08:16.5805802Z 14:08:16.495 Installing required Roslyn analyzers…
2021-02-26T14:08:16.5825930Z 14:08:16.495 Processing plugin: csharp version 8.15.0.24505
2021-02-26T14:08:16.5834943Z 14:08:16.496 Cache hit: using plugin files from C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp.sonarqube\resources\0
2021-02-26T14:08:16.5877877Z 14:08:16.496 Processing plugin: vbnet version 8.15.0.24505
2021-02-26T14:08:16.5881922Z 14:08:16.496 Cache hit: using plugin files from C:\Windows\ServiceProfiles\NetworkService\AppData\Local\Temp.sonarqube\resources\1
2021-02-26T14:08:16.5883377Z 14:08:16.499 Writing Roslyn analyzer additional file to C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work\1.sonarqube\conf\vbnet\SonarLint.xml…
2021-02-26T14:08:16.5891915Z 14:08:16.555 Pre-processing succeeded.
2021-02-26T14:08:16.5893234Z ##[debug]Exit code 0 received from tool ‘C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe’
2021-02-26T14:08:16.5894461Z ##[debug]STDIO streams have closed for tool ‘C:\SonarAgent\vsts-agent-win-x64-2.181.2 (1)_work_tasks\SonarQubePrepare_Preformatted text15b84ca1-b62f-4a2a-a403-89b77a063157\4.17.0\classic-sonar-scanner-msbuild\SonarScanner.MSBuild.exe’
2021-02-26T14:08:16.5897625Z ##[section]Finishing: Prepare analysis on SonarQube
Hi,
Have you tested dotnet build instead of msbuild.exe to build your csproj-only project ?
Hi Caro,
I didnt tried dotnet build as of now,only msbuild i have tried.
Okay so whether build a .sln file (with your msbuild command), or you may have to switch to full .NET Core experience to be able to have your csproj built and analyzed.
Hi Caro,
I have builded my sample code msbuild without any issue.
please refer the screenshot below.
When i execute end step i am facing this issue
Ok so that’s not the same error as before. Which one are you trying to resolve please ? I’m getting confused. Thanks !
Hi Caro,
Here are 2 major cases i have tried from my end.
Case 1:
I am trying to fix the sonarscanner end step command like below.
“SonarScanner.MSBuild.exe end”
When i try to execute the above command i am facing the below issue.
Case 2:
I have tried with the new dotnet source code from the github for my requirement,where i can compile and build the code from msbuild as well.
As i can run the begin and end commands from the msbuild command prompt without any issue.
Please refer the screenshot after end statement
But after this analysis from end command,when i try to execute the pipeline from azure devops i am facing this issue with same .sln file.
Any Help on the above request!