Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'editors/code/src/client.ts')
-rw-r--r--editors/code/src/client.ts8
1 files changed, 8 insertions, 0 deletions
diff --git a/editors/code/src/client.ts b/editors/code/src/client.ts
index 3408a2ee84..fb667619c8 100644
--- a/editors/code/src/client.ts
+++ b/editors/code/src/client.ts
@@ -76,6 +76,14 @@ export async function createClient(
outputChannel,
middleware: {
workspace: {
+ // HACK: This is a workaround, when the client has been disposed, VSCode
+ // continues to emit events to the client and the default one for this event
+ // attempt to restart the client for no reason
+ async didChangeWatchedFile(event, next) {
+ if (client.isRunning()) {
+ await next(event);
+ }
+ },
async configuration(
params: lc.ConfigurationParams,
token: vscode.CancellationToken,