Skip to content

[preferences] Reject invalid preference schemas.#6110

Merged
AlexTugarev merged 1 commit intomasterfrom
GH-6106
Sep 6, 2019
Merged

[preferences] Reject invalid preference schemas.#6110
AlexTugarev merged 1 commit intomasterfrom
GH-6106

Conversation

@AlexTugarev
Copy link
Contributor

@AlexTugarev AlexTugarev commented Sep 5, 2019

What it does

Fixes #6106

How to test

  1. install rust vscode extension (0.6.1) (includes an invalid pref schema) and e.g. the python vscode extension
  2. start the Theia application and see the rejection message for the invalid rust schema is logged, but more importantly it now should be possible to change python preferences (e.g. python.pythonPath) which was effectively a no-op before.

Review checklist

Reminder for reviewers

@akosyakov akosyakov added preferences issues related to preferences vscode issues related to VSCode compatibility labels Sep 5, 2019
@AlexTugarev
Copy link
Contributor Author

@akosyakov if you (or anyone else) is interested, I'm happy to change this to throw an error so it can be handled e.g. in the plugin system in order to make it easier to identity the causing part.

In this version the rejection message will contain only the pref key e.g. rust-client.channel, which should help to identify the contribution.

@akosyakov
Copy link
Member

@AlexTugarev throwing is a breaking change, so maybe better no

@AlexTugarev
Copy link
Contributor Author

Open in Gitpod

because of the download issues for debug adapters, one need to disable them. here is a prepared workspace as a snapshot.

@akosyakov
Copy link
Member

@AlexTugarev please file an issue about debug adapters, we need to find a solution for it

@svenefftinge
Copy link
Contributor

@AlexTugarev please file an issue about debug adapters, we need to find a solution for it

Maybe we should get rid of the debug-nodejs extension completely?

@akosyakov
Copy link
Member

There are more extensions doing it as well as docker images.

@AlexTugarev
Copy link
Contributor Author

here #6111

Fixes #6106

Signed-off-by: Alex Tugarev <alex.tugarev@typefox.io>
Copy link
Member

@akosyakov akosyakov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested that invalid schema does not break the combined preference schema and schema validation errors are still logged. Thanks @AlexTugarev!

@AlexTugarev AlexTugarev merged commit 1c3653a into master Sep 6, 2019
@svenefftinge svenefftinge deleted the GH-6106 branch October 8, 2019 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

preferences issues related to preferences vscode issues related to VSCode compatibility

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Preference schema validation issue (rust vscode extension)

3 participants