Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fire JSON schema changed event if an underlying in-memory resource is changed #6035

Merged
merged 1 commit into from
Sep 4, 2019

Conversation

akosyakov
Copy link
Member

@akosyakov akosyakov commented Aug 25, 2019

What it does

Otherwise JSON language server does not pick up content changes.

A bit off-topic:
I wonder why the host process has to be launched to recognize registered debuggers via metadata. Metadata from package.json should be recognized as soon as any VS Code extension is deployed. It could be that an extension code is not activated, but an extension still should contribute debug types and snippets for launch.json @tolusha Is it a bug?

How to test

  • install node and node2 vscode extensions instead of native node debug extension
  • open launch.json file
  • make sure that it has node launch configuration and it is recognized
  • refresh the page several times with opened launch.json file
  • each time check that node launch configuration is eventually (as soon as VS Code extensions are loaded) recognized properly

Review checklist

Reminder for reviewers

@akosyakov akosyakov requested review from tolusha and a team August 25, 2019 10:21
@akosyakov
Copy link
Member Author

@kpge Could you test whether it addresses #5804 as well?

@akosyakov akosyakov added debug issues that related to debug functionality vscode issues related to VSCode compatibility labels Aug 25, 2019
@kpge
Copy link
Contributor

kpge commented Aug 27, 2019

@kpge Could you test whether it addresses #5804 as well?

no, it's still can't get the right suggestion when click Add Configuration in the launch.json

@akosyakov
Copy link
Member Author

@kpge even if you wait a bit after opening? It could take time to fetch schemas, install them and reapply changes to json LS.

@kpge
Copy link
Contributor

kpge commented Aug 27, 2019

@kpge even if you wait a bit after opening? It could take time to fetch schemas, install them and reapply changes to json LS.

yes, I've opened the browser(didn't open a json file) or several minutes.
click 'Add Configuration' will open launch.json file and request triggerSuggest immediately; when sleep 200ms after opening the file , the suggestion will become correct
https://github.com/theia-ide/theia/blob/24bf9f28508f5b1244531605224e4b9ba424a9ba/packages/debug/src/browser/debug-configuration-manager.ts#L234

@a1994846931931
Copy link
Contributor

Hi, what node and node2 vscode extensions are you referring to? Is it https://marketplace.visualstudio.com/items?itemName=ms-vscode.node-debug2 ?

@akosyakov
Copy link
Member Author

akosyakov commented Sep 2, 2019

@a1994846931931
Copy link
Contributor

@akosyakov Sorry, I cannot reproduce #6034. I did the following:

  1. Compile theia 144a1fe without debug-nodejs package;
  2. Run backend and make sure that node launch configuration is invalid then;
  3. Relaunch backend with ms-vscode.node-debug-1.38.4.vsix and ms-vscode.node-debug2-1.33.0.vsix;
  4. With launch.json opened, refresh page several times and check the validity of node launch configuration;

But however I tried, the node launch configuration is always valid.

…resource is changed

Otherwise JSON language server does not pick up content changes.

Signed-off-by: Anton Kosyakov <anton.kosyakov@typefox.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
debug issues that related to debug functionality vscode issues related to VSCode compatibility
Projects
None yet
Development

Successfully merging this pull request may close these issues.

change to launch schema by plugin system are not always recognized
4 participants