Sonarcloud failing with .NET in GitHub Actions

I have an interesting issue with one project that won’t complete, but I don’t get a useful error message. I have over 20 projects setup, this is using the same base script. I refreshed the SONAR_TOKEN, and it still fails. What can I add to get more log information?

Time Elapsed 00:00:45.18
SonarScanner for MSBuild 5.9.1
Using the .NET Core version of the Scanner for MSBuild
Post-processing started.
Calling the SonarScanner CLI...
INFO: Scanner configuration file: D:\a\AzurePipelinesToGitHubActionsConverterWeb\AzurePipelinesToGitHubActionsConverterWeb\.sonar\scanner\.store\dotnet-sonarscanner\5.9.1\dotnet-sonarscanner\5.9.1\tools\net5.0\any\sonar-scanner-4.7.0.2747\bin\..\conf\sonar-scanner.properties
INFO: Project root configuration file: D:\a\AzurePipelinesToGitHubActionsConverterWeb\AzurePipelinesToGitHubActionsConverterWeb\.sonarqube\out\sonar-project.properties
INFO: SonarScanner 4.7.0.2747
INFO: Java 11.0.17 Azul Systems, Inc. (64-bit)
INFO: Windows Server 2022 10.0 amd64
INFO: User cache: C:\Users\runneradmin\.sonar\cache
INFO: Scanner configuration file: D:\a\AzurePipelinesToGitHubActionsConverterWeb\AzurePipelinesToGitHubActionsConverterWeb\.sonar\scanner\.store\dotnet-sonarscanner\5.9.1\dotnet-sonarscanner\5.9.1\tools\net5.0\any\sonar-scanner-4.7.0.2747\bin\..\conf\sonar-scanner.properties
INFO: Project root configuration file: D:\a\AzurePipelinesToGitHubActionsConverterWeb\AzurePipelinesToGitHubActionsConverterWeb\.sonarqube\out\sonar-project.properties
INFO: Analyzing on SonarCloud
INFO: Default locale: "en_US", source code encoding: "windows-1252" (analysis is platform dependent)
INFO: Load global settings
INFO: Load global settings (done) | time=940ms
INFO: Server id: 1BD809FA-AWHW8ct9-T_TB3XqouNu
INFO: User cache: C:\Users\runneradmin\.sonar\cache
INFO: Load/download plugins
INFO: Load plugins index
INFO: Load plugins index (done) | time=925ms
INFO: Load/download plugins (done) | time=8148ms
INFO: Loaded core extensions: developer-scanner
INFO: Found an active CI vendor: 'Github Actions'
INFO: Load project settings for component key: 'samsmithnz_AzurePipelinesToGitHubActionsConverterWeb'
INFO: Load project settings for component key: 'samsmithnz_AzurePipelinesToGitHubActionsConverterWeb' (done) | time=875ms
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 18.468s
ERROR: Error during SonarScanner execution
INFO: Final Memory: 7M/27M
ERROR: You are running CI analysis while Automatic Analysis is enabled. Please consider disabling one or the other.
INFO: ------------------------------------------------------------------------
ERROR: 
The SonarScanner did not complete successfully
22:32:04.375  Post-processing failed. Exit code: 1
Error: Process completed with exit code 1.

Hey there.

It looks like Automatic Analysis is enabled, an therefore you can’t run CI-based analysis.

Can you check the project-level Administration > Analysis Method and turn off Automatic Analysis?