Having Issue while connecting SonarQube using Sonarlint for VS

  • Operating system: Windows
  • IDE name and flavor/env: Visual Studio
  • Plugin : SonarLint

Description of the problem / question:
We are having issue connection our SonarQube server with one of our projects even though it was working before but from last week it not.

What we have done after it stopped working: Install the SonarLint again in VS IDE still having Issue connecting the SonarQube.

Do let me know if anything needed from our end.

Hey there.

“Issue connection” is a bit broad. What are the specific symptoms, and what log messages do you see? What version of Visual Studio are you using?

Hi Colin,

We are using Visual Studio 2022.
attached the below error log:

Do let me know if anything else is required.

Any Update on this ???
It’s Urgent.

@Colin Any update???

@Sheetal apologies for the delay in responding.

Which version of SonarQube are you using?

Could you share more verbose log output us please?
To get very detailed logs in SonarLint for Visual Studio, do the following:

  • set the following environment variable: SONARLINT_INTERNAL_LOG_DEBUG=true
  • restart Visual Studio and attempt to connect to the server.

You’ll probably want to unset the variable after capturing the logout as it’s a bit overwhelming.

Thanks.

Hi @duncanp

We are using SonarQube Community Version 8.9.10 LTS

Please find the attached detailed log file I have removed the sensitive information such the Server name ,key

Regards,
Sheetal

[Log file deleted]

Hi @Sheetal,

Thanks for the log (it had a couple of URLs in it, so I removed it from the thread after downloading it).

Unfortunately, I still can’t pinpoint exactly where the failure is occurring. The json returned by the API call to get the plugins seems to be valid.

I’ve created a custom build with additional logging. Could you install it and share the logs please?

Thanks,
Duncan

Hi @duncanp

Here the Log file.

[UPDATE: log deleted]

Regards

Thanks @Sheetal - that’s very helpful. We now know where the problem is occurring - we just need to work out why…

I’ve created SLVS-3305 to track the bug. We’ll be starting a bug-fixing sprint in the next couple of weeks and we’ll take a look at it then.

Hello @Sheetal ,

Thank you very much for the logs, they’re very helpful.
Could you please provide further information about your Solution?

  • Which languages do you have in your solution?
  • Is there anything outstanding regarding the projects in the solution?

The problem seems to be with a specific project in the solution, would it be possible for you to unload them to find the one the binding is failing on?

You mentioned that the binding was working until recently - have you added any new projects to the Visual Studio solution recently, and if so what is the type of the project? (i.e. which Visual Studio project template type did you use?)

Thank you very much,
Rita

Hello @rita.g

  • Which languages do you have in your solution - C#

  • Is there anything outstanding regarding the projects in the solution - No?

  • have you added any new projects to the Visual Studio solution recently, and if so what is the type of the project - No new projects added

Thanks

Hello @Sheetal ,

Thank you for your response. I was not able to reproduce it locally and have created an additional custom build that suppresses the error and logs more information.

Would you mind please trying it out and sharing the logs with me?

  • Please set the following environment variable: SONARLINT_INTERNAL_LOG_DEBUG=true
  • Restart Visual Studio and attempt to connect to the server.

The binding should succeed with this build and the logs would be of great help in pinpointing where exactly is the problem.

Thank you very much for your help,
Rita

@rita.g here is the log file.
Log (2).txt (23.9 KB)

Regards,
Sheetal

Strange but it’s Working now don’t know the reason.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.