Save Action is delayed because of analyzing file

Please provide

  • Operating system: Mac
  • SonarLint plugin version: Sonoma latest version
  • Programming language you’re coding in: typescript/html
  • Is connected mode used: SonarCloud
    • Connected to SonarCloud or SonarQube (and which version):

And a thorough description of the problem / question:

Often I have the problem that the analyzis is running for a file which I have saved or want to save.
It looks like the SonarLint Plugin blocks the “saving” action of vs code see screenshot:

“Analyzing 1 file” after the entry is gone the file is saved.

image

This is really annoying is it some how possible to do the analyzis in parallel or at least after saving the file?

The issue only occurs with the SonarLint enabled.

1 Like

Hi there, @daniell; welcome to Sonar Community! :wave: :sonar:

Thanks for reporting this behavior. Strangely, I have never seen it before on my machine and was not able to reproduce it now either. :thinking: That does not mean the problem is not there though :slight_smile:

One question is, why does analysis for a single even take that long to be so noticeable? How big is the file (how many lines of code and issues in the file)?

Also, are you using editor.codeActionsOnSave settings? :thinking:

To help us investigate, could you please provide full SonarLint logs, as well as clarify the version of SonarLint plugin used? (latest version is v4.10)

All the best,
Sophio from :sonarlint_vscode: