{{ message }}
Start R language server only when needed and stop after 30s. - #1708
Open
Fred-Wu wants to merge 5 commits into
Open
Start R language server only when needed and stop after 30s.#1708Fred-Wu wants to merge 5 commits into
Fred-Wu wants to merge 5 commits into
Conversation
…vity - Start the language server only when an R file is opened. - Stop the server automatically 30 seconds after the last R file is closed. - Cancel the shutdown timer if a new R file is opened within those 30 seconds. - Fix "server disconnected" errors by double-checking that no R files are open exactly when the 30-second timer finishes, preventing the server from being accidentally killed while in use.
Member
- route temporary vdocs to their originating workspace server - track parent QMDs for correct idle shutdown - preserve completion and diagnostics for R chunks - serialize client stop and restart operations
- avoid retaining stopped clients - dispose clients when startup fails
Contributor
Author
Fred-Wu
added a commit
to Fred-Wu/vscode-R
that referenced
this pull request
Jul 6, 2026
Improvments based on official vscode-R's PR REditorSupport#1708 and REditorSupport#1717
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
This PR updates the R language server lifecycle so that the server starts only when an R-related document is opened, and shuts down after all R-related documents are closed.
This avoids keeping the language server running unnecessarily while still preserving the existing session if another R-related file is opened shortly after the last one is closed.
Main Changes