DevSkim icon indicating copy to clipboard operation
DevSkim copied to clipboard

Dotnet process is spawned multiple times

Open dotai2012 opened this issue 2 years ago • 3 comments

To Reproduce Steps to reproduce the behavior:

  1. Open Vscode
  2. Close the program
  3. Open Task Manager and check for the Dotnet process
  4. Back to step 1, every time I open Vscode, it spawns a new one

Expected behavior When closing Vscode, dotnet should exit as well

Screenshots image image

Versions(please complete the following information):

  • OS: Ubuntu 22.04
  • Devskim Version: 1.0.11

dotai2012 avatar Jul 18 '23 22:07 dotai2012

Hello @dotai2012,

I've attempted to replicate this but am not seeing this behavior with DevSkim 1.0.11 on Windows, the .NET process appears to properly quit when VS Code is closed. I'll attempt to replicate today on Ubuntu.

gfs avatar Jul 24 '23 15:07 gfs

I'm able to replicate this on Ubuntu, but am not yet sure how to resolve it. The design of the extension delegates responsibility for the lifecycle of the Language Server process to the VS Code library for the Language Client which launches and then connects to the server. Its not clear why it would properly close the processes on Windows but not on Ubuntu but will investigate more.

gfs avatar Jul 24 '23 17:07 gfs

This issue doesn't appear to be present in Bicep which uses a very similar design including also using the omnisharp language server library, which may be useful as a reference to identify the issue.

gfs avatar Jul 24 '23 18:07 gfs