Theia: Settings.json Schema should not include "tasks"

Created on 30 Mar 2020  路  3Comments  路  Source: eclipse-theia/theia

If I edit the file <workspace_root>/.theia/settings.json in Theia, the editor suggests to add a "tasks" setting value. However, if I follow the content assist and create a task in settings.json, the task does not show up when doing "Run Task".
Looking at the code, all requests for "tasks" preferences are redirected to the <ws_root>/.theia/tasks.json if such a file exists. If such a file does not exist, the task from settings.json _does_ show up.
I believe this behavior is confusing and we should not support a "tasks" in the schema for settins.json.
Btw: when you open do "Open Preferences (JSON)" in VS Code, the editor does _not_ suggest a tasks section.

bug preferences tasks

Most helpful comment

I'm talking about the json schema we use for _editing_ settings.json. If you open settings.json in VS Code, content assist will _not_ suggest adding a "tasks" section in "settings.json".

All 3 comments

How is it related to launch? It works in VS Code, why we should break backward compatibility with them?

I've reviewed VS Code docs and could not find anything from tasks in settings.json so it should be fine to remove.

But VS Code docs are explicit about launch configuration:

VS Code keeps debugging configuration information in a launch.json file located in a .vscode folder in your workspace (project root folder) or in your user settings or workspace settings.

From https://code.visualstudio.com/docs/editor/debugging#_launch-configurations

I'm talking about the json schema we use for _editing_ settings.json. If you open settings.json in VS Code, content assist will _not_ suggest adding a "tasks" section in "settings.json".

Was this page helpful?
0 / 5 - 0 ratings