Warnings are detected in Log but never showed in IDE

Please provide

  • Operating system: Windows 11 x64
  • SonarLint plugin version: v4.2.2
  • Programming language you’re coding in: C#
  • Is connected mode used: No


And the last part:

[Info  - 19:21:35.339] 1/1 source file has been analyzed
[Debug - 19:21:35.339] 'Python Sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'IPython Notebooks Sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] Execute Sensor: HTML
[Debug - 19:21:35.339] 'XML Sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'Code Quality and Security for Go' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'PHP sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'Analyzer for "php.ini" files' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'IaC Terraform Sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'IaC CloudFormation Sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'IaC Kubernetes Sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] 'IaC AzureResourceManager Sensor' skipped because there is no related files in the current project
[Debug - 19:21:35.339] Execute Sensor: TextAndSecretsSensor
[Info  - 19:21:35.437] 1 source file to be analyzed
[Info  - 19:21:35.437] 1/1 source file has been analyzed
[Debug - 19:21:35.439] Execute Sensor: IaC Docker Sensor
[Info  - 19:21:35.485] 0 source files to be analyzed
[Info  - 19:21:35.485] 0/0 source files have been analyzed
[Debug - 19:21:35.485] 'CFamily' skipped because there is no related files in the current project
[Info  - 19:21:35.538] Found 0 issues

As the image above, I pretty sure that SonarLint is working, and 2 warnings are detected.
However, these warnings are not showed in IDE. No underline, no issues, just nothing.

Am I missing something? Additionally, I am using C# and C# Dev Kit plugin and I wonder if there are some conflict.

Hello @KumoSiunaus, welcome to Sonar Community :sonar: :wave: !

In order to investigate your issue, we would need full SonarLint logs. You can find the instructions on how to get them here.

There should be no conflict with the C# and C# Dev Kit plugins, and it’s hard to understand the issue with the log fragments you provided. :eyes:

Thanks in advance,
Sophio from :sonarlint_vscode:

Hi, @sophio.japharidze
I think I found out the cause of the problem. It is because the path to the .cs file include some Japanese characters.

1 Like

Wow, thank you for the interesting update! :open_mouth:

I am able to reproduce this issue. There are two options

  • In case the whole file name is in Japanese, for example こんにちは.cs The problem seems to be on the VSCode (IDE) side, because it is not notifying SonarLint that a file was open. SonarLint will only trigger analysis when it receives textDocument/didOpen event.
  • In case file name simply contains Japanese characters, for example こんにちはaa.cs, IDE sends SonarLint the didOpen event and analysis is running, but as you described, the issues are not being reported. And the logs say Found 0 issues. This only happens for C# files for some reason :thinking: I have created this ticket to investigate.

I hope that clarifies a bit,
All the best,
Sophio from :sonarlint_vscode:

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