SonarLint "Open in IDE" gives CORS error

If your question is about SonarLint in the IntelliJ Platform, VS Code, Visual Studio, or Eclipse, please post it in that sub-category.

Otherwise, please provide:

  • Operating system: Windows 11
  • IDE name and flavor/env:
    VSCode latest
    And a thorough description of the problem / question:

Getting below error while clicking open in IDE, Network tab in the console shows

"Access to fetch at ‘http://localhost:64120/sonarlint/api/status’ from origin ‘http://’ has been blocked by CORS policy: The request client is not a secure context and the resource is in more-private address space local.

sonarlint.ts:31
GET http://localhost:64124/sonarlint/api/status net::ERR_CONNECTION_REFUSED"

Note: This is not localhost sonarqube server where VSCode is installed, but server hosted at different location.

1 Like

A post was merged into an existing topic: SonarLint “Open in IDE” error - VScode