eclipse-theia / theia

Eclipse Theia is a cloud & desktop IDE framework implemented in TypeScript.
http://theia-ide.org
Eclipse Public License 2.0
19.82k stars 2.48k forks source link

Workspace-scoped launch configurations of multi-root workspace are associated with folders #8985

Open RomanNikitenko opened 3 years ago

RomanNikitenko commented 3 years ago

Bug Description:

At the moment Theia duplicates Workspace launch configs at displaying on Debug panel for every project of multi-root workspace. For example, user has workspace config file like:

{
    "folders": [
        {
            "path": "theia"
        },
        {
            "path": "vscode"
        }
    ],
    "settings": {
        "launch": {
            "configurations": [
                {
                    "name": "Launch Chrome",
                    "request": "launch",
                    "type": "pwa-chrome",
                    "url": "http://localhost:8080",
                    "webRoot": "${workspaceFolder}"
                }
            ]
        }
    }
}

So, there are 2 projects and only one launch configuration. The configuration is displayed twice on the Debug panel (once per each workspace folder - so for theia and for vscode in my example above):

theia-launch

VS Code doesn't associate workspace level configs with a particular folder :

vscode_launch

Steps to Reproduce:

  1. Start a multi-root workspace from config file with launch configurations (please see the example above)
  2. Go to the Debug panel and check the workspace level configs

Additional Information

RomanNikitenko commented 3 years ago

I created the issue as enhancement, because I thought the current behavior is the result of the first implementation of launch configs in Theia without alignment of the behavior with VS Code.

But after seeing the comment for me it looks like a bug and the investigation contains some details related to the cause of the problem.

RomanNikitenko commented 3 years ago

Theia has similar problem for Global launch configurations, please see https://github.com/eclipse-theia/theia/issues/8830#issuecomment-768874797