Troubleshooting
What to do when you have problems running an analysis in SonarQube for Visual Studio.
Knowing where to begin looking for information is the first step to reaching out for help. Many answers to commonly found problems can be found on the SonarQube for IDE channel of the Sonar Community Forum. See below for the basic steps to access the SonarQube for IDE logs when the analysis results are not what you expected.
Before posting to the Community, make sure that you have your logs ready by following the instructions below.
How to get the SonarQube for Visual Studio logs
Select Show Logs from the SonarQube help menu: Extensions > SonarQube > Help > Show Logs
To dig deeper, enable the Verbose output in the SonarQube Options, then repeat the action that caused the problem:
Navigate to Extensions > SonarQube > Options… > General and set your Logging level to Verbose.
Troubleshooting connected mode setup
No matching project found
No matching project is found because:
It’s best if you already have the project open in your IDE, otherwise SonarQube for Visual Studio might not be able to find a matching file.
The current bound project or solution does not match the SonarQube Server or SonarQube Cloud project or solution. Please check your binding configuration.
If these solutions don’t help, follow the instructions about Project binding to manually configure your project binding.
No matching issue found
SonarQube for Visual Studio can’t find your issue because:
You might not be on the same branch.
The issue was fixed, or the source code may be different from the analyzed version.
Updating your credentials
Unfortunately, you cannot update your SonarQube Server or SonarQube Cloud credentials in SonarQube for Visual Studio. Please see the Updating your credentials article on the Connection setup page.
SSL/TLS errors
If you’re having trouble connecting to the server due to SSL/TLS errors, it might be because SonarQube for Visual Studio can’t verify the server certificate chain due to the fact that it can’t check the Certificate Revocation List. To troubleshoot and find out why, begin with making sure you’re using the latest version of SonarQube for Visual Studio, then check your logs:
Enable verbose logs. See How to get the SonarQube for Visual Studio logs above for details.
Make sure that your analyzers have had a chance to load and run (run Ctrl+S to be certain) and search for [CertificateChainValidator] in the logs. Next, you’ll work to fix the issue that prevents the chain validation.
Manually add the certificate to the SonarLint trust store:
The documentation described in the Server SSL certificates article will explain how to do this.
SonarQube for Visual Studio expects the truststore.p12 to exist under ~/.sonarlint/ssl, where ~sonarlint refers to the C:\Users\username\~sonarlint folder; if the folder doesn’t exist, it can be added manually.
If all else fails, ask for help on The Sonar Community.
Troubleshooting unexpected analysis results
Sometimes, issues found on the server differ from those found locally by SonarQube for IDE. Usually, the server-side rule configuration (your quality profile) is to blame; however, it could be something more than that. Maybe your local build configuration and system dependencies don’t align with your DevOps pipeline, or it could simply be that the issue, due to its complexity, is only detectable by SonarQube Server or SonarQube Cloud.
The collapsible below lists some of the most commonly encountered reasons, along with some details that will help you troubleshoot discrepancies.
Language-specific examples
Last updated
Was this helpful?

